NetBSD Problem Report #42991

From www@NetBSD.org  Wed Mar 17 18:13:32 2010
Return-Path: <www@NetBSD.org>
Received: from mail.netbsd.org (mail.netbsd.org [204.152.190.11])
	by www.NetBSD.org (Postfix) with ESMTP id 0BF1963B86C
	for <gnats-bugs@gnats.NetBSD.org>; Wed, 17 Mar 2010 18:13:32 +0000 (UTC)
Message-Id: <20100317181331.C9E1463B11D@www.NetBSD.org>
Date: Wed, 17 Mar 2010 18:13:31 +0000 (UTC)
From: rodo@zlug.org
Reply-To: rodo@zlug.org
To: gnats-bugs@NetBSD.org
Subject: p7zip - Makefile (licenses) broken
X-Send-Pr-Version: www-1.0

>Number:         42991
>Category:       pkg
>Synopsis:       p7zip - Makefile (licenses) broken
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    pkg-manager
>State:          closed
>Class:          change-request
>Submitter-Id:   net
>Arrival-Date:   Wed Mar 17 18:15:00 +0000 2010
>Closed-Date:    Sun Dec 29 22:49:43 +0000 2013
>Last-Modified:  Sun Dec 29 22:49:43 +0000 2013
>Originator:     Robert Doerfler
>Release:        pkgsrc-2009Q4
>Organization:
>Environment:
NetBSD tofu.local.home 5.0.2 NetBSD 5.0.2 (TOFU) #1: Mon Feb 15 20:26:26 CET 2010  nikon@tofu.local.home:/usr/src/sys/arch/i386/compile/TOFU i386

>Description:
Licenses erroneous, wouldn't build even if licenses are accepted.

bash-4.0# make      
ERROR: This package has set PKG_FAIL_REASON:
ERROR: p7zip-9.04 has an unacceptable license condition: 
ERROR:     gnu-lgpl-v2.1 AND unrar-license
ERROR: You can mark the license ``license'' as acceptable by adding
ERROR:     ACCEPTABLE_LICENSES+= license
ERROR: to /etc/mk.conf or by adding
ERROR:     ACCEPTABLE_LICENSES= license
ERROR: to /etc/pkg_install.conf.
*** Error code 1

Stop.
make: stopped in /usr/pkgsrc/archivers/p7zip

>How-To-Repeat:
make 
>Fix:
--- Makefile    2010-03-17 18:54:56.000000000 +0100
+++ Makefile.new        2010-03-17 18:53:50.000000000 +0100
@@ -9,8 +9,8 @@
 MAINTAINER=    wiz@NetBSD.org
 HOMEPAGE=      http://p7zip.sourceforge.net/
 COMMENT=       File archiver with high compression
-LICENSE=       gnu-lgpl-v2.1 AND unrar-license
-
+LICENSE=       gnu-lgpl-v2.1-license 
+LICENSE=       unrar-license
 PKG_INSTALLATION_TYPES=        overwrite pkgviews
 PKG_DESTDIR_SUPPORT=   user-destdir

>Release-Note:

>Audit-Trail:
From: Joerg Sonnenberger <joerg@britannica.bec.de>
To: gnats-bugs@NetBSD.org
Cc: 
Subject: Re: pkg/42991: p7zip - Makefile (licenses) broken
Date: Wed, 17 Mar 2010 19:29:45 +0100

 On Wed, Mar 17, 2010 at 06:15:00PM +0000, rodo@zlug.org wrote:
 > >Description:
 > Licenses erroneous, wouldn't build even if licenses are accepted.

 ACCEPTABLE_LICENSES+= unrar-license
 ?

 Joerg

From: Robert Doerfler <rodo@zlug.org>
To: gnats-bugs@NetBSD.org
Cc: 
Subject: Re: pkg/42991: p7zip - Makefile (licenses) broken
Date: Wed, 17 Mar 2010 21:46:52 +0100

 On Wed, Mar 17, 2010 at 06:30:05PM +0000, Joerg Sonnenberger wrote:
 > The following reply was made to PR pkg/42991; it has been noted by GNATS.
 > 
 > From: Joerg Sonnenberger <joerg@britannica.bec.de>
 > To: gnats-bugs@NetBSD.org
 > Cc: 
 > Subject: Re: pkg/42991: p7zip - Makefile (licenses) broken
 > Date: Wed, 17 Mar 2010 19:29:45 +0100
 > 
 >  On Wed, Mar 17, 2010 at 06:15:00PM +0000, rodo@zlug.org wrote:
 >  > >Description:
 >  > Licenses erroneous, wouldn't build even if licenses are accepted.
 >  
 >  ACCEPTABLE_LICENSES+= unrar-license
 >  ?

 Hmm, well, there's a mistake inside. But besides that, it's quite bad
 that all the needed licenses aren't listed for packages with more than
 one missing acceptable_license.

State-Changed-From-To: open->feedback
State-Changed-By: wiz@NetBSD.org
State-Changed-When: Sat, 20 Mar 2010 19:58:15 +0000
State-Changed-Why:
The license code is fine.
Can you provide a diff for the documentation that would
make clearer what confused you?
Thanks.


State-Changed-From-To: feedback->open
State-Changed-By: dholland@NetBSD.org
State-Changed-When: Tue, 23 Mar 2010 18:27:05 +0000
State-Changed-Why:
I think I understand:
it should not be saying
ERROR: You can mark the license ``license'' as acceptable by adding
ERROR:     ACCEPTABLE_LICENSES+= license

because that's nonsense.
Relatedly, make show-license doesn't work for expressions on licenses,
either - it says e.g.
  Generic gnu-gpl-v3 OR modified-bsd information not available
for "LICENSE=gnu-gpl-v3 OR modified-bsd
".


From: Joerg Sonnenberger <joerg@britannica.bec.de>
To: gnats-bugs@NetBSD.org
Cc: 
Subject: Re: pkg/42991 (p7zip - Makefile (licenses) broken)
Date: Tue, 23 Mar 2010 19:36:52 +0100

 On Tue, Mar 23, 2010 at 06:27:06PM +0000, dholland@NetBSD.org wrote:
 > I think I understand:
 > it should not be saying
 > ERROR: You can mark the license ``license'' as acceptable by adding
 > ERROR:     ACCEPTABLE_LICENSES+= license
 >
 > because that's nonsense.

 What else? Should it second guess what the best for the user is?
 Do you want to implement a SAT resolver? 

 > Relatedly, make show-license doesn't work for expressions on licenses,
 > either - it says e.g.
 >   Generic gnu-gpl-v3 OR modified-bsd information not available
 > for "LICENSE=gnu-gpl-v3 OR modified-bsd
 > ".

 If you want to fix it, drop () AND OR, sort, unify and loop over the
 result...

 Joerg

From: David Holland <dholland-pbugs@netbsd.org>
To: gnats-bugs@NetBSD.org
Cc: pkg-manager@netbsd.org, gnats-admin@netbsd.org, pkgsrc-bugs@netbsd.org,
	rodo@zlug.org
Subject: Re: pkg/42991 (p7zip - Makefile (licenses) broken)
Date: Tue, 23 Mar 2010 18:52:55 +0000

 On Tue, Mar 23, 2010 at 06:40:09PM +0000, Joerg Sonnenberger wrote:
  >> I think I understand:
  >> it should not be saying
  >> ERROR: You can mark the license ``license'' as acceptable by adding
  >> ERROR:     ACCEPTABLE_LICENSES+= license
  >>
  >> because that's nonsense.
  >  
  >  What else? Should it second guess what the best for the user is?
  >  Do you want to implement a SAT resolver?

 There are various things it could say that are not nonsense, such as

 ERROR: This package has set PKG_FAIL_REASON:
 ERROR: foo-1.0 has an unacceptable license condition: 
 ERROR:     foo-license AND bar-license AND modified-bsd
 ERROR: The following license(s) are not accepted:
 ERROR:     foo-license bar-license
 ERROR: To build this package you must accept some suitable combination
 ERROR: of these. To accept a license called ``license'', add
 ERROR:     ACCEPTABLE_LICENSES+= license
 ERROR: to /etc/mk.conf or add
 ERROR:     ACCEPTABLE_LICENSES= license
 ERROR: to /usr/pkg/etc/pkg_install.conf.

  >  > Relatedly, make show-license doesn't work for expressions on licenses,
  >  > either - it says e.g.
  >  >   Generic gnu-gpl-v3 OR modified-bsd information not available
  >  > for "LICENSE=gnu-gpl-v3 OR modified-bsd
  >  > ".
  >  
  >  If you want to fix it, drop () AND OR, sort, unify and loop over the
  >  result...

 That or suggest "make show-license LICENSE=foo" for each one, which is
 probably better since many licenses are large.

 -- 
 David A. Holland
 dholland@netbsd.org

From: Robert Doerfler <rodo@zlug.org>
To: gnats-bugs@NetBSD.org
Cc: 
Subject: Re: pkg/42991 (p7zip - Makefile (licenses) broken)
Date: Wed, 24 Mar 2010 08:29:31 +0100

 On Tue, Mar 23, 2010 at 06:55:01PM +0000, David Holland wrote:
 > 
 >  On Tue, Mar 23, 2010 at 06:40:09PM +0000, Joerg Sonnenberger wrote:
 >   >>
 >   >> because that's nonsense.
 >   >  
 >   >  What else? Should it second guess what the best for the user is?
 >   >  Do you want to implement a SAT resolver?
 >  
 >  There are various things it could say that are not nonsense, such as
 >  
 >  ERROR: This package has set PKG_FAIL_REASON:
 >  ERROR: foo-1.0 has an unacceptable license condition: 
 >  ERROR:     foo-license AND bar-license AND modified-bsd
 >  ERROR: The following license(s) are not accepted:
 >  ERROR:     foo-license bar-license
 >  ERROR: To build this package you must accept some suitable combination
 >  ERROR: of these. To accept a license called ``license'', add
 >  ERROR:     ACCEPTABLE_LICENSES+= license
 >  ERROR: to /etc/mk.conf or add
 >  ERROR:     ACCEPTABLE_LICENSES= license
 >  ERROR: to /usr/pkg/etc/pkg_install.conf.

 That's it. If more than one license is needed to be accepted it should
 list all the licenses which are missing and not just some " license"
 or ``license''.
 If there's just one missing license the output is ok, why shouldn't it
 work for more than one?



From: David Holland <dholland-pbugs@netbsd.org>
To: gnats-bugs@NetBSD.org
Cc: 
Subject: Re: pkg/42991 (p7zip - Makefile (licenses) broken)
Date: Thu, 25 Mar 2010 02:17:13 +0000

 On Wed, Mar 24, 2010 at 07:30:06AM +0000, Robert Doerfler wrote:
  >  That's it. If more than one license is needed to be accepted it should
  >  list all the licenses which are missing and not just some " license"
  >  or ``license''.

 It's trying to use "license" as an example, but it's horribly unclear.

  >  If there's just one missing license the output is ok, why shouldn't it
  >  work for more than one?

 The real reason is that the boolean logic on licenses feature was only
 added recently.

 The good reasonn is that as Joerg pointed out to name exact sets of
 licenses to enable you need a boolean satisfiability solver, which
 though possible in principle is not really a winning idea for
 implementing in make for pkgsrc.

 Something like what I suggested should be feasible; it will need to
 wait until 2010Q1 is branched though.

 -- 
 David A. Holland
 dholland@netbsd.org

State-Changed-From-To: open->closed
State-Changed-By: dholland@NetBSD.org
State-Changed-When: Sun, 29 Dec 2013 22:49:43 +0000
State-Changed-Why:
wiz fixed it in 2011
(and I have been behind on my pkgsrc bugs mail nearly that long)


>Unformatted:

NetBSD Home
NetBSD PR Database Search

(Contact us) $NetBSD: query-full-pr,v 1.39 2013/11/01 18:47:49 spz Exp $
$NetBSD: gnats_config.sh,v 1.8 2006/05/07 09:23:38 tsutsui Exp $
Copyright © 1994-2007 The NetBSD Foundation, Inc. ALL RIGHTS RESERVED.