ports/119048: per-port make.port.conf support [fix included]
Phil Pennock
fbsd122007 at phil.spodhuis.org
Wed Dec 26 20:30:05 UTC 2007
>Number: 119048
>Category: ports
>Synopsis: per-port make.port.conf support [fix included]
>Confidential: no
>Severity: non-critical
>Priority: low
>Responsible: freebsd-ports-bugs
>State: open
>Quarter:
>Keywords:
>Date-Required:
>Class: change-request
>Submitter-Id: current-users
>Arrival-Date: Wed Dec 26 20:30:05 UTC 2007
>Closed-Date:
>Last-Modified:
>Originator: Phil Pennock
>Release: 6.2
>Organization:
n/a
>Environment:
>Description:
At present, the closest that vanilla FreeBSD comes to allowing per-port config is either options named with the port in them (WITH_MUTT_*) or use of the options settings. There is no support for, eg, setting WITH_RUBY=t by default and then overriding it to undef for a particular port.
For a year now, I've been using a setup to allow use of /etc/make.port.conf which is able to tune make variables per-port; it's stable and solid and would be a useful addition to standard FreeBSD.
Example entries:
.if defined(PORTNAME) && ${PORTNAME} == "avahi"
# Python interface requires py-gtk
.undef WITH_PYTHON
.endif
.if defined(PORTNAME) && ${PORTNAME} == "curl"
CONFIGURE_ARGS+=--with-gssapi=/usr/local
.endif
.if defined(PORTNAME) && ${PORTNAME} == "mysql"
WITH_CHARSET=utf8
WITH_XCHARSET=all
.endif
>How-To-Repeat:
n/a (feature request)
>Fix:
Edit ${PORTSDIR}/Mk/bsd.local.mk and insert at bsd.port.pre.mk inclusion time:
.if exists(/etc/make.port.conf)
.include "/etc/make.port.conf"
.endif
That's all it takes to have an /etc/ config file which can tune variables per-port.
>Release-Note:
>Audit-Trail:
>Unformatted:
More information about the freebsd-ports-bugs
mailing list