diff options
Diffstat (limited to 'net')
-rw-r--r-- | net/miniupnpd/Makefile | 10 | ||||
-rw-r--r-- | net/miniupnpd/distinfo | 13 | ||||
-rw-r--r-- | net/miniupnpd/options.mk | 13 | ||||
-rw-r--r-- | net/miniupnpd/patches/patch-Makefile | 44 | ||||
-rw-r--r-- | net/miniupnpd/patches/patch-bsd_getroute.c | 23 | ||||
-rw-r--r-- | net/miniupnpd/patches/patch-bsd_ifacewatcher.c | 19 | ||||
-rw-r--r-- | net/miniupnpd/patches/patch-genconfig.sh | 15 | ||||
-rw-r--r-- | net/miniupnpd/patches/patch-upnputils.h | 34 |
8 files changed, 34 insertions, 137 deletions
diff --git a/net/miniupnpd/Makefile b/net/miniupnpd/Makefile index a63ca841184..506b9869458 100644 --- a/net/miniupnpd/Makefile +++ b/net/miniupnpd/Makefile @@ -1,6 +1,6 @@ -# $NetBSD: Makefile,v 1.11 2014/02/10 11:45:52 adam Exp $ +# $NetBSD: Makefile,v 1.12 2014/07/10 13:44:22 adam Exp $ -DISTNAME= miniupnpd-1.8.20140203 +DISTNAME= miniupnpd-1.8.20140523 CATEGORIES= net MASTER_SITES= http://miniupnp.free.fr/files/download.php?file= @@ -22,4 +22,10 @@ INSTALL_MAKE_FLAGS+= INSTALLMANDIR=${PREFIX}/${PKGMANDIR}/man1 RCD_SCRIPTS= miniupnpd +SUBST_CLASSES+= fwname +SUBST_STAGE.fwname= pre-configure +SUBST_MESSAGE.fwname= Setting desired firewall type. +SUBST_FILES.fwname= genconfig.sh +SUBST_VARS.fwname= FWNAME + .include "../../mk/bsd.pkg.mk" diff --git a/net/miniupnpd/distinfo b/net/miniupnpd/distinfo index 2f862e94d0b..57e60ca005e 100644 --- a/net/miniupnpd/distinfo +++ b/net/miniupnpd/distinfo @@ -1,9 +1,6 @@ -$NetBSD: distinfo,v 1.11 2014/03/31 11:25:22 wiz Exp $ +$NetBSD: distinfo,v 1.12 2014/07/10 13:44:22 adam Exp $ -SHA1 (miniupnpd-1.8.20140203.tar.gz) = f2ffb05db5831f0105662dcb2787ec5d6ea25630 -RMD160 (miniupnpd-1.8.20140203.tar.gz) = 6f781c1fad39f0ff6901f1309aef32af41febbc8 -Size (miniupnpd-1.8.20140203.tar.gz) = 170112 bytes -SHA1 (patch-Makefile) = c7ec423a3f405aa19959c93df2432cb538e2563e -SHA1 (patch-bsd_getroute.c) = 0649c6e3febc2bac008f4325f71c64c99200c216 -SHA1 (patch-bsd_ifacewatcher.c) = 3a9fdf12e721c1452bc34bf2a4938ae5d492a0f0 -SHA1 (patch-upnputils.h) = a948bc7e77a9ef105f72b28f97498b329849e31f +SHA1 (miniupnpd-1.8.20140523.tar.gz) = 1f29d76df57fcf4046c7cb9c7312d7fbc3f28e26 +RMD160 (miniupnpd-1.8.20140523.tar.gz) = 215e7b930aa78a9ebe5880b8350adb4e3ff7eab7 +Size (miniupnpd-1.8.20140523.tar.gz) = 190936 bytes +SHA1 (patch-genconfig.sh) = 2bd34c785bf4812e191144fd6cb5af89dccce1ee diff --git a/net/miniupnpd/options.mk b/net/miniupnpd/options.mk index 5b13270d913..20f362ed5b5 100644 --- a/net/miniupnpd/options.mk +++ b/net/miniupnpd/options.mk @@ -1,4 +1,4 @@ -# $NetBSD: options.mk,v 1.5 2014/01/30 15:07:57 adam Exp $ +# $NetBSD: options.mk,v 1.6 2014/07/10 13:44:22 adam Exp $ PKG_OPTIONS_VAR= PKG_OPTIONS.miniupnpd PKG_OPTIONS_REQUIRED_GROUPS= miniupnpd-fw @@ -17,16 +17,15 @@ PKG_SUGGESTED_OPTIONS+= ipfilter .include "../../mk/bsd.options.mk" .if !empty(PKG_OPTIONS:Mipfilter) -MAKE_ENV+= FWNAME=ipf -FILES_SUBST+= FWNAME=ipfilter +FWNAME= ipf .endif .if !empty(PKG_OPTIONS:Mipfw) -MAKE_ENV+= FWNAME=ipfw -FILES_SUBST+= FWNAME=ipfw +FWNAME= ipfw .endif .if !empty(PKG_OPTIONS:Mpf) -MAKE_ENV+= FWNAME=pf -FILES_SUBST+= FWNAME=pf +FWNAME= pf .endif + +MAKE_ENV+= FWNAME=${FWNAME} diff --git a/net/miniupnpd/patches/patch-Makefile b/net/miniupnpd/patches/patch-Makefile deleted file mode 100644 index 7a53aef0293..00000000000 --- a/net/miniupnpd/patches/patch-Makefile +++ /dev/null @@ -1,44 +0,0 @@ -$NetBSD: patch-Makefile,v 1.5 2014/03/31 11:25:22 wiz Exp $ - -don't force -ansi -add missing linker flags - ---- Makefile.orig 2013-02-06 13:14:42.000000000 +0000 -+++ Makefile -@@ -17,7 +17,7 @@ - - CFLAGS ?= -pipe -Os - #CFLAGS = -pipe -O -g -DDEBUG --CFLAGS += -ansi -+#CFLAGS += -ansi - CFLAGS += -Wall - CFLAGS += -W - CFLAGS += -Wstrict-prototypes -@@ -182,22 +182,22 @@ miniupnpd: config.h $(ALLOBJS) - # $(CC) $(CFLAGS) -o $@ $> $(LIBS) - - miniupnpdctl: config.h $(MINIUPNPDCTLOBJS) -- $(CC) $(CFLAGS) -o $@ $(MINIUPNPDCTLOBJS) -+ $(CC) $(CFLAGS) -o $@ $(MINIUPNPDCTLOBJS) $(LIBS) - - testupnpdescgen: config.h $(TESTUPNPDESCGENOBJS) -- $(CC) $(CFLAGS) -o $@ $(TESTUPNPDESCGENOBJS) -+ $(CC) $(CFLAGS) -o $@ $(TESTUPNPDESCGENOBJS) $(LIBS) - - testgetifstats: config.h $(TESTGETIFSTATSOBJS) - $(CC) $(CFLAGS) -o $@ $(TESTGETIFSTATSOBJS) $(LIBS) - - testgetifaddr: config.h $(TESTGETIFADDROBJS) -- $(CC) $(CFLAGS) -o $@ $(TESTGETIFADDROBJS) -+ $(CC) $(CFLAGS) -o $@ $(TESTGETIFADDROBJS) $(LIBS) - - testupnppermissions: config.h $(TESTUPNPPERMISSIONSOBJS) -- $(CC) $(CFLAGS) -o $@ $(TESTUPNPPERMISSIONSOBJS) -+ $(CC) $(CFLAGS) -o $@ $(TESTUPNPPERMISSIONSOBJS) $(LIBS) - - testgetroute: config.h $(TESTGETROUTEOBJS) -- $(CC) $(CFLAGS) -o $@ $(TESTGETROUTEOBJS) -+ $(CC) $(CFLAGS) -o $@ $(TESTGETROUTEOBJS) $(LIBS) - - # gmake : - # $(CC) $(CFLAGS) -o $@ $^ diff --git a/net/miniupnpd/patches/patch-bsd_getroute.c b/net/miniupnpd/patches/patch-bsd_getroute.c deleted file mode 100644 index 556260c9ef0..00000000000 --- a/net/miniupnpd/patches/patch-bsd_getroute.c +++ /dev/null @@ -1,23 +0,0 @@ -$NetBSD: patch-bsd_getroute.c,v 1.1 2013/10/21 10:06:57 fhajny Exp $ - -use the SA_LEN wrapper ---- bsd/getroute.c.orig 2013-02-06 13:14:42.000000000 +0000 -+++ bsd/getroute.c -@@ -83,7 +83,7 @@ get_src_for_route_to(const struct sockad - sa = (struct sockaddr *)p; - sockaddr_to_string(sa, tmp, sizeof(tmp)); - syslog(LOG_DEBUG, "type=%d sa_len=%d sa_family=%d %s", -- i, sa->sa_len, sa->sa_family, tmp); -+ i, SA_LEN(sa), sa->sa_family, tmp); - if((i == RTA_DST || i == RTA_GATEWAY) && - (src_len && src)) { - size_t len = 0; -@@ -113,7 +113,7 @@ get_src_for_route_to(const struct sockad - *index = sdl->sdl_index; - } - #endif -- p += sa->sa_len; -+ p += SA_LEN(sa); - } - } - } diff --git a/net/miniupnpd/patches/patch-bsd_ifacewatcher.c b/net/miniupnpd/patches/patch-bsd_ifacewatcher.c deleted file mode 100644 index f8e2e7a308e..00000000000 --- a/net/miniupnpd/patches/patch-bsd_ifacewatcher.c +++ /dev/null @@ -1,19 +0,0 @@ -$NetBSD: patch-bsd_ifacewatcher.c,v 1.1 2013/10/21 10:06:57 fhajny Exp $ - -use SA_LEN wrapper ---- bsd/ifacewatcher.c.orig 2012-05-21 08:55:10.000000000 +0000 -+++ bsd/ifacewatcher.c -@@ -15,12 +15,8 @@ - #include <syslog.h> - #include <signal.h> - --#if !defined(SA_LEN) --#define SA_LEN(sa) (sa)->sa_len --#endif -- - #define SALIGN (sizeof(long) - 1) --#define SA_RLEN(sa) ((sa)->sa_len ? (((sa)->sa_len + SALIGN) & ~SALIGN) : (SALIGN + 1)) -+#define SA_RLEN(sa) (SA_LEN(sa) ? ((SA_LEN(sa) + SALIGN) & ~SALIGN) : (SALIGN + 1)) - - #include "../upnputils.h" - #include "../upnpglobalvars.h" diff --git a/net/miniupnpd/patches/patch-genconfig.sh b/net/miniupnpd/patches/patch-genconfig.sh new file mode 100644 index 00000000000..0a229c451cc --- /dev/null +++ b/net/miniupnpd/patches/patch-genconfig.sh @@ -0,0 +1,15 @@ +$NetBSD: patch-genconfig.sh,v 1.1 2014/07/10 13:44:22 adam Exp $ + +Avoid firewall type auto-detection. + +--- genconfig.sh.orig 2014-07-10 10:43:05.000000000 +0000 ++++ genconfig.sh +@@ -293,7 +293,7 @@ case $OS_NAME in + ;; + esac + +-case $FW in ++case @FWNAME@ in + pf) + echo "#define USE_PF 1" >> ${CONFIGFILE} + ;; diff --git a/net/miniupnpd/patches/patch-upnputils.h b/net/miniupnpd/patches/patch-upnputils.h deleted file mode 100644 index cd442ff6b4e..00000000000 --- a/net/miniupnpd/patches/patch-upnputils.h +++ /dev/null @@ -1,34 +0,0 @@ -$NetBSD: patch-upnputils.h,v 1.1 2013/10/21 10:06:57 fhajny Exp $ - -define SA_LEN wrapper and MAX macro if missing ---- upnputils.h.orig 2013-02-06 10:51:05.000000000 +0000 -+++ upnputils.h -@@ -29,5 +29,28 @@ set_non_blocking(int fd); - struct lan_addr_s * - get_lan_for_peer(const struct sockaddr * peer); - -+ -+/** -+ * define portability macros -+ */ -+#if defined(__sun) -+static size_t _sa_len(const struct sockaddr *addr) -+{ -+ if (addr->sa_family == AF_INET) -+ return (sizeof(struct sockaddr_in)); -+ else if (addr->sa_family == AF_INET6) -+ return (sizeof(struct sockaddr_in6)); -+ else -+ return (sizeof(struct sockaddr)); -+} -+# define SA_LEN(sa) (_sa_len(sa)) -+#else -+# define SA_LEN(sa) ((sa)->sa_len) -+#endif -+ -+#ifndef MAX -+# define MAX(a,b) (((a)>(b))?(a):(b)) -+#endif -+ - #endif - |