aboutsummaryrefslogtreecommitdiffstats
path: root/net/miniupnpc
diff options
context:
space:
mode:
authordinoex <dinoex@FreeBSD.org>2009-08-13 22:52:01 +0800
committerdinoex <dinoex@FreeBSD.org>2009-08-13 22:52:01 +0800
commitc1cae6e35cd1c3b6c1ff6c84e3c08660e4c3c33e (patch)
treea54eb48849b51e89e436c8e17745af396338a313 /net/miniupnpc
parent6bd58e682cc6ff9df1345a841f580b9b78a0e7b5 (diff)
downloadfreebsd-ports-gnome-c1cae6e35cd1c3b6c1ff6c84e3c08660e4c3c33e.tar.gz
freebsd-ports-gnome-c1cae6e35cd1c3b6c1ff6c84e3c08660e4c3c33e.tar.zst
freebsd-ports-gnome-c1cae6e35cd1c3b6c1ff6c84e3c08660e4c3c33e.zip
- compile in FreeBSD version string
- add support for slave ports PR: 137612 Submitted by: Anonymous
Diffstat (limited to 'net/miniupnpc')
-rw-r--r--net/miniupnpc/Makefile21
-rw-r--r--net/miniupnpc/files/patch-updateminiupnpcstrings.sh11
2 files changed, 29 insertions, 3 deletions
diff --git a/net/miniupnpc/Makefile b/net/miniupnpc/Makefile
index e7e45183e736..94fc04f7824f 100644
--- a/net/miniupnpc/Makefile
+++ b/net/miniupnpc/Makefile
@@ -7,19 +7,34 @@
PORTNAME= miniupnpc
PORTVERSION= 1.3
+PORTREVISION= 1
CATEGORIES= net
MASTER_SITES= http://miniupnp.free.fr/files/
MAINTAINER= dinoex@FreeBSD.org
-COMMENT= UPnP IGD client lightweight library
+COMMENT?= UPnP IGD client lightweight library
+HAS_CONFIGURE= yes
USE_GMAKE= yes
+USE_LDCONFIG= yes
+
+CONFIGURE_SCRIPT= updateminiupnpcstrings.sh
MAKE_ENV+= INSTALLPREFIX=${PREFIX}
CFLAGS+= -fPIC
-USE_LDCONFIG= yes
+
+.include <bsd.port.pre.mk>
+
+.if !defined(SLAVE_PORT)
MAN3= miniupnpc.3
+.endif
+
+.if defined(WITH_DEBUG)
+CFLAGS+= -DDEBUG
+.endif
+.if !defined(SLAVE_PORT)
post-install:
${INSTALL_MAN} ${WRKSRC}/man3/miniupnpc.3 ${PREFIX}/man/man3/
+.endif
-.include <bsd.port.mk>
+.include <bsd.port.post.mk>
diff --git a/net/miniupnpc/files/patch-updateminiupnpcstrings.sh b/net/miniupnpc/files/patch-updateminiupnpcstrings.sh
new file mode 100644
index 000000000000..1a6e4f7b7fff
--- /dev/null
+++ b/net/miniupnpc/files/patch-updateminiupnpcstrings.sh
@@ -0,0 +1,11 @@
+--- updateminiupnpcstrings.sh~
++++ updateminiupnpcstrings.sh
+@@ -27,7 +27,7 @@ fi
+
+ echo "Detected OS [$OS_NAME] version [$OS_VERSION]"
+
+-EXPR="s/OS_STRING\s\".*\"/OS_STRING \"${OS_NAME}\/${OS_VERSION}\"/"
++EXPR="/OS_STRING/s|\".*\"|\"${OS_NAME}/${OS_VERSION}\"|"
+ #echo $EXPR
+ echo "Backuping $FILE to $FILE.bak."
+ cp $FILE $FILE.bak