Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 25 Nov 2009 13:33:59 +0100 (CET)
From:      Tor Halvard Furulund <squat@squat.no>
To:        FreeBSD-gnats-submit@FreeBSD.org
Subject:   ports/140861: [MAINTAINER] net/miniupnpd: make it build in tinderbox
Message-ID:  <200911251233.nAPCXxLA058323@hipper.squat.no>
Resent-Message-ID: <200911251240.nAPCe1Og058947@freefall.freebsd.org>

next in thread | raw e-mail | index | archive | help

>Number:         140861
>Category:       ports
>Synopsis:       [MAINTAINER] net/miniupnpd: make it build in tinderbox
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-ports-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          maintainer-update
>Submitter-Id:   current-users
>Arrival-Date:   Wed Nov 25 12:40:00 UTC 2009
>Closed-Date:
>Last-Modified:
>Originator:     Tor Halvard Furulund
>Release:        FreeBSD 8.0-RELEASE amd64
>Organization:
>Environment:
System: FreeBSD hipper.squat.no 8.0-RELEASE FreeBSD 8.0-RELEASE #5: Mon Nov 16 14:46:55 CET 2009 Squat@hipper.squat.no:/usr/obj/usr/src/sys/hipper amd64

>Description:
In ports/140319 my genconfig.sh-patch was just removed, so the port cannot build in setups without /etc/rc.conf (like tinderbox). Made a new genconfig.sh-patch to make the port build without rc.conf and rc.subr.
I didn't bump the portrevision-number, I can submit a new patch with PORTREVISION=1 if requested.
>How-To-Repeat:
http://pointyhat.FreeBSD.org/errorlogs/amd64-errorlogs/a.8.20091122192541/miniupnpd-1.4.log
>Fix:
diff -ruN /usr/ports/net/miniupnpd/files/patch-genconfig.sh miniupnpd/files/patch-genconfig.sh
--- /usr/ports/net/miniupnpd/files/patch-genconfig.sh	1970-01-01 01:00:00.000000000 +0100
+++ miniupnpd/files/patch-genconfig.sh	2009-11-25 12:58:20.461270015 +0100
@@ -0,0 +1,40 @@
+--- genconfig.sh.orig	2009-09-04 18:21:24.000000000 +0200
++++ genconfig.sh	2009-11-25 12:31:04.344410750 +0100
+@@ -66,18 +66,25 @@
+ 		fi
+ 		# new way to see which one to use PF or IPF.
+ 		# see http://miniupnp.tuxfamily.org/forum/viewtopic.php?p=957
+-		# source file with handy subroutines like checkyesno
+-		. /etc/rc.subr
+-		# source config file so we can probe vars
+-		. /etc/rc.conf
+-		if checkyesno ipfilter_enable; then
+-			echo "Using ipf"
+-			FW=ipf
+-			echo "#define USE_IPF 1" >> ${CONFIGFILE}
+-		elif checkyesno pf_enable; then
+-			echo "Using pf"
+-			FW=pf
+-			echo "#define USE_PF 1" >> ${CONFIGFILE}
++		# source file wource config file so we can probe vars
++		if [ -f /etc/rc.subr ] && [ -f /etc/rc.conf ]; then
++			# source file with handy subroutines like checkyesno
++			. /etc/rc.subr
++			# source config file so we can probe vars
++			. /etc/rc.conf
++			if checkyesno ipfilter_enable; then
++				echo "Using ipf"
++				FW=ipf
++				echo "#define USE_IPF 1" >> ${CONFIGFILE}
++			elif checkyesno pf_enable; then
++				echo "Using pf"
++				FW=pf
++				echo "#define USE_PF 1" >> ${CONFIGFILE}
++			else
++				echo "Could not detect usage of ipf or pf. Compiling for pf by default"
++				FW=pf
++				echo "#define USE_PF 1" >> ${CONFIGFILE}
++			fi
+ 		# TODO : Add support for IPFW
+ 		# echo "#define USE_IPFW 1" >> ${CONFIGFILE}
+ 		# FW=ipfw
>Release-Note:
>Audit-Trail:
>Unformatted:



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200911251233.nAPCXxLA058323>