[arch-commits] Commit in miniupnpd/trunk (3 files)

Timothy Redaelli tredaelli at nymeria.archlinux.org
Wed Apr 23 15:59:32 UTC 2014


    Date: Wednesday, April 23, 2014 @ 17:59:32
  Author: tredaelli
Revision: 110045

upgpkg: miniupnpd 1.8.20140401-2

FS#39868

Added:
  miniupnpd/trunk/miniupnpd-1.8.20140401-foreground.patch
Modified:
  miniupnpd/trunk/PKGBUILD
  miniupnpd/trunk/miniupnpd.systemd

-----------------------------------------+
 PKGBUILD                                |   38 +++++++++++++++++-----------
 miniupnpd-1.8.20140401-foreground.patch |   40 ++++++++++++++++++++++++++++++
 miniupnpd.systemd                       |    3 --
 3 files changed, 64 insertions(+), 17 deletions(-)

Modified: PKGBUILD
===================================================================
--- PKGBUILD	2014-04-23 15:56:40 UTC (rev 110044)
+++ PKGBUILD	2014-04-23 15:59:32 UTC (rev 110045)
@@ -3,7 +3,7 @@
 # Contributor: fauno <fauno at parabola.nu>
 pkgname=miniupnpd
 pkgver=1.8.20140401
-pkgrel=1
+pkgrel=2
 pkgdesc="Lightweight UPnP IGD daemon"
 arch=('i686' 'x86_64')
 url="http://miniupnp.free.fr"
@@ -12,30 +12,38 @@
 depends=('libnfnetlink' 'iptables' 'net-tools' 'util-linux')
 makedepends=('lsb-release')
 source=("http://miniupnp.free.fr/files/$pkgname-$pkgver.tar.gz"
+        miniupnpd-1.8.20140401-foreground.patch
         miniupnpd.systemd)
 sha256sums=('086dfffa59e8e86e792b73a71d275fec55ef17fe3e94a8c140301aceb05bcdbd'
-            '2707d028f28fbb28c3a9d13605c9c738e9628f828e22288a8a1492ac93f9ad7c')
+            '79350f2dbb695b58744aa9036d34a7dfdcfc97cf0f5f3419b86bd9ca58482f8e'
+            'baac6223eb35729ea301bd658dc2df6aad5396c7c0b1ec15c8aac1803ef37f6a')
 
+prepare() {
+  cd "$pkgname-$pkgver"
+
+  patch -p0 -i "$srcdir"/miniupnpd-1.8.20140401-foreground.patch
+}
+
 build() {
-	cd "$pkgname-$pkgver"
+  cd "$pkgname-$pkgver"
 
-	CONFIG_OPTIONS="--strict --ipv6 --leasefile" make -f Makefile.linux config.h
-	make -f Makefile.linux
+  CONFIG_OPTIONS="--strict --ipv6 --leasefile" make -f Makefile.linux config.h
+  make -f Makefile.linux
 }
 
 package() {
-	cd "$pkgname-$pkgver"
-	mkdir -p "$pkgdir/usr/share/man/man8"
+  cd "$pkgname-$pkgver"
+  mkdir -p "$pkgdir/usr/share/man/man8"
 
-	make PREFIX="$pkgdir/" SBININSTALLDIR="$pkgdir/usr/bin" -f Makefile.linux install
+  make PREFIX="$pkgdir/" SBININSTALLDIR="$pkgdir/usr/bin" -f Makefile.linux install
 
-	rm -r "${pkgdir}/etc/init.d"
+  rm -r "${pkgdir}/etc/init.d"
 
-	install -Dm644 LICENSE "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE"
-	install -Dm644 "${srcdir}/miniupnpd.systemd" "${pkgdir}/usr/lib/systemd/system/miniupnpd.service"
+  install -Dm644 LICENSE "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE"
+  install -Dm644 "${srcdir}/miniupnpd.systemd" "${pkgdir}/usr/lib/systemd/system/miniupnpd.service"
 
-	sed -i 's:/s\?bin/iptables:/usr/bin/iptables:
-	        s:eth0:"`cat /etc/miniupnpd/miniupnpd.conf | '"awk -F= '/^ext_ifname/ { print \$2 }'"'`":' "${pkgdir}"/etc/miniupnpd/*.sh
-	sed -i -e "s/^uuid=[-0-9a-f]*/uuid=00000000-0000-0000-0000-000000000000/
-	           s/make genuuid/uuidgen/" "${pkgdir}/etc/miniupnpd/miniupnpd.conf"
+  sed -i 's:/s\?bin/iptables:/usr/bin/iptables:
+          s:eth0:"`cat /etc/miniupnpd/miniupnpd.conf | '"awk -F= '/^ext_ifname/ { print \$2 }'"'`":' "${pkgdir}"/etc/miniupnpd/*.sh
+  sed -i -e "s/^uuid=[-0-9a-f]*/uuid=00000000-0000-0000-0000-000000000000/
+             s/make genuuid/uuidgen/" "${pkgdir}/etc/miniupnpd/miniupnpd.conf"
 }

Added: miniupnpd-1.8.20140401-foreground.patch
===================================================================
--- miniupnpd-1.8.20140401-foreground.patch	                        (rev 0)
+++ miniupnpd-1.8.20140401-foreground.patch	2014-04-23 15:59:32 UTC (rev 110045)
@@ -0,0 +1,40 @@
+--- ./miniupnpd.c.orig	2014-04-23 15:41:11.783562093 +0000
++++ ./miniupnpd.c	2014-04-23 15:43:19.672842038 +0000
+@@ -797,7 +797,7 @@
+ {
+ 	int i;
+ 	int pid;
+-	int debug_flag = 0;
++	int debug_flag = 0, foreground_flag = 0;
+ 	int openlog_option;
+ 	struct sigaction sa;
+ 	/*const char * logfilename = 0;*/
+@@ -1159,6 +1159,9 @@
+ 		case 'd':
+ 			debug_flag = 1;
+ 			break;
++		case 'D':
++			foreground_flag = 1;
++			break;
+ 		case 'w':
+ 			if(i+1 < argc)
+ 				presurl = argv[++i];
+@@ -1273,7 +1276,7 @@
+ 		goto print_usage;
+ 	}
+ 
+-	if(debug_flag)
++	if(debug_flag || foreground_flag)
+ 	{
+ 		pid = getpid();
+ 	}
+@@ -1413,7 +1416,8 @@
+ 	        "\tNotify interval is in seconds. Default is 30 seconds.\n"
+ 			"\tDefault pid file is '%s'.\n"
+ 			"\tDefault config file is '%s'.\n"
+-			"\tWith -d miniupnpd will run as a standard program.\n"
++			"\tWith -D miniupnpd will run as a standard program.\n"
++			"\tWith -d miniupnpd will run as a standard program in debug mode.\n"
+ #if defined(USE_PF) || defined(USE_IPF)
+ 			"\t-L sets packet log in pf and ipf on.\n"
+ #endif

Modified: miniupnpd.systemd
===================================================================
--- miniupnpd.systemd	2014-04-23 15:56:40 UTC (rev 110044)
+++ miniupnpd.systemd	2014-04-23 15:59:32 UTC (rev 110045)
@@ -3,10 +3,9 @@
 
 [Service]
 ExecStartPre=/etc/miniupnpd/iptables_init.sh
-ExecStart=/usr/bin/miniupnpd -f /etc/miniupnpd/miniupnpd.conf -d
+ExecStart=/usr/bin/miniupnpd -f /etc/miniupnpd/miniupnpd.conf -D
 ExecStopPost=/etc/miniupnpd/iptables_removeall.sh
 PIDFile=/run/miniupnpd.pid
-StandardOutput=null
 
 [Install]
 WantedBy=network.target




More information about the arch-commits mailing list