From 66c3e2140dbaac5d6e10f546985763dc72b088c9 Mon Sep 17 00:00:00 2001 From: Erwin Lansing Date: Tue, 3 Jul 2007 18:49:35 +0000 Subject: Add an option to build a dynamically linked binary, defaulting to off PR: 114235 Submitted by: Henrik Brix Andersen Approved by: maintainer --- sysutils/env4801/Makefile | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) (limited to 'sysutils') diff --git a/sysutils/env4801/Makefile b/sysutils/env4801/Makefile index a0658ca06662..27f836d24f3e 100644 --- a/sysutils/env4801/Makefile +++ b/sysutils/env4801/Makefile @@ -7,6 +7,7 @@ PORTNAME= env4801 PORTVERSION= 0.3 +PORTREVISION= 1 CATEGORIES= sysutils MASTER_SITES= http://phk.freebsd.dk/soekris/env4801/ DISTFILES= Makefile env4801.c @@ -25,6 +26,15 @@ MAKE_ARGS= -DNOMAN PLIST_FILES= sbin/env4801 etc/rc.d/env4801.sh +OPTIONS= STATIC "Build a statically linked executable" On + +.include + +post-patch: +.ifdef(WITHOUT_STATIC) + @${REINPLACE_CMD} -e '/-static/d' ${WRKSRC}/Makefile +.endif + post-extract: @${SED} ${RC_SCRIPTS_SUB:S/$/!g/:S/^/ -e s!%%/:S/=/%%!/} \ ${FILESDIR}/env4801.sh > ${WRKSRC}/env4801.sh @@ -36,4 +46,4 @@ do-install: post-install: @${SED} ${RC_SCRIPTS_SUB:S/$/!g/:S/^/ -e s!%%/:S/=/%%!/} ${PKGMESSAGE} -.include +.include -- cgit v1.2.3