Bug 225699 - ports-mgmt/portmaster introduced a ask-licence dependency
Summary: ports-mgmt/portmaster introduced a ask-licence dependency
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Only Me
Assignee: Stefan Eßer
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2018-02-05 23:48 UTC by dewayne
Modified: 2018-02-06 23:35 UTC (History)
0 users

See Also:
bugzilla: maintainer-feedback? (se)


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description dewayne 2018-02-05 23:48:44 UTC
Build failure of security/openssl, due to 
make: don't know how to make ask-license. Stop

The cause of the failure is line 3661 of 
# grep -n ask-license /usr/local/sbin/portmaster
3661:           pm_make extract ask-license || fail "make extract ask-license failed for $portdir"

Portmaster invoked with 
/usr/local/sbin/portmaster --no-term-title --no-confirm -H -D -g -G -B -v  security/openssl

but 
# grep DISABLE_LICE /etc/make.conf
/etc/make.conf:DISABLE_LICENSES=yes

Aside: This occurs on FreeBSD 11.1Stable amd64, recent portmaster update )r:460294). 

You may wish to refer to r458881 and PR 206738
Comment 1 Stefan Eßer freebsd_committer freebsd_triage 2018-02-06 12:56:32 UTC
I'm not sure whether this is a problem in bsd.licenses.mk, actually.

IMHO, the make target "ask-license" should not return an error, but silently accept any license requested, if DISABLE_LICENSES has been set.

I'll make portmaster check for DISABLE_LICENSES and prevent the "make ask-license" phase, if set.
Comment 2 commit-hook freebsd_committer freebsd_triage 2018-02-06 13:13:03 UTC
A commit references this bug:

Author: se
Date: Tue Feb  6 13:12:04 UTC 2018
New revision: 461041
URL: https://svnweb.freebsd.org/changeset/ports/461041

Log:
  Fix build for ports that have a LICENSE if DISABLE_LICENSES is defined.

  The behavior of the ask-license target should be to silently succeed instead
  of returning an error, IMHO, but I can test for this condition and skip the
  ask-license phase in portmaster, too.

  While here, I'm slightly simplifying the fix implemented in r460294.

  PR:		225699
  Submitted by:	dewayne@heuristicsystems.com.au
  Approved by:	antoine (implicit)

Changes:
  head/ports-mgmt/portmaster/Makefile
  head/ports-mgmt/portmaster/files/patch-portmaster
Comment 3 Stefan Eßer freebsd_committer freebsd_triage 2018-02-06 13:21:03 UTC
Thank you for reporting the problem. I had never tested with DISABLE_LICENSES set, so I did not notice there was an issue ...
Comment 4 dewayne 2018-02-06 23:35:45 UTC
(In reply to Stefan Esser from comment #3)
Thank-you Stefan for attending to this promptly.  Unfortunately DISABLE_LICENCES prevents the loading of the Mk/licenses.mk; therefore the destination "ask-license" isn't available.  Alas, modifying portmaster is the only recourse.

Testing for obscurities should be left to the folks that use them ;) and fortunately you're quick to address :)