freebsd-ports/ports-mgmt/portconf/pkg-install
Sunpoet Po-Chuan Hsieh 38e2e32e06 - Allow use with bmake (default make on 10 and above)
- Bump PORTREVISION for package change

PR:		ports/183104
Submitted by:	sunpoet (myself)
Approved by:	maintainer (timeout, 18 days)
2013-11-06 20:03:31 +00:00

22 lines
524 B
Bash

#!/bin/sh
MAKE_CONF=/etc/make.conf
PORTS_DIR=`/bin/realpath /usr/ports`
if [ "$2" = "POST-INSTALL" ]; then
echo -n "Spamming ${MAKE_CONF}..."
cat >> ${MAKE_CONF} << EOF
# Begin portconf settings
# Do not touch these lines
.if !empty(.CURDIR:M${PORTS_DIR}*) && exists(${PKG_PREFIX}/libexec/portconf)
_PORTCONF!=${PKG_PREFIX}/libexec/portconf
.if \${_PORTCONF} != "|"
.for i in \${_PORTCONF:S/^|//:S/|/ /g}
\${i:C/^([^=]*)=.*/\1/}=\${i:C/^[^=]*=//:S/%/ /g}
.endfor
.endif
.endif
# End portconf settings
EOF
echo " Done."
fi