From f8d4948b53e684633f01945abbd3c75b3950cd24 Mon Sep 17 00:00:00 2001 From: Antoine Brodin Date: Tue, 11 Nov 2014 22:11:55 +0000 Subject: - Use option helpers - Use @sample keyword - Use COPYTREE_SHARE instead of handrolling - Cleanup plist --- net/openslp/Makefile | 20 +++++--------------- net/openslp/pkg-plist | 19 +++---------------- 2 files changed, 8 insertions(+), 31 deletions(-) diff --git a/net/openslp/Makefile b/net/openslp/Makefile index 7083692cda76..4e86d296a64d 100644 --- a/net/openslp/Makefile +++ b/net/openslp/Makefile @@ -3,7 +3,7 @@ PORTNAME= openslp PORTVERSION= 1.2.1 -PORTREVISION= 4 +PORTREVISION= 5 CATEGORIES= net MASTER_SITES= SF/${PORTNAME}/OpenSLP/${PORTVERSION} @@ -24,15 +24,8 @@ OPTIONS_DEFINE= SLP_SECURITY ASYNC_API DOCS SLP_SECURITY_DESC= Turn on SLPv2 security support ASYNC_API_DESC= Enable asynchronous communication API -.include - -.if ${PORT_OPTIONS:MSLP_SECURITY} -CONFIGURE_ARGS+= --enable-slpv2-security -.endif - -.if ${PORT_OPTIONS:MASYNC_API} -CONFIGURE_ARGS+= --enable-async-api -.endif +SLP_SECURITY_CONFIGURE_ENABLE= slpv2-security +ASYNC_API_CONFIGURE_ENABLE= async-api post-extract: @(cd ${WRKSRC}; \ @@ -41,12 +34,9 @@ post-extract: post-install: .for FILE in slp.conf slp.reg slp.spi - ${INSTALL_DATA} ${WRKSRC}/etc/${FILE} ${STAGEDIR}${PREFIX}/etc/openslp/${FILE}.default + ${INSTALL_DATA} ${WRKSRC}/etc/${FILE} ${STAGEDIR}${PREFIX}/etc/openslp/${FILE}.sample .endfor - @${MKDIR} ${STAGEDIR}${DOCSDIR} - (cd ${INSTALL_WRKSRC}/doc; \ - ${FIND} . -type d -exec ${MKDIR} ${STAGEDIR}${DOCSDIR}/\{} \; ;\ - ${FIND} . -type f -exec ${INSTALL_DATA} \{} ${STAGEDIR}${DOCSDIR}/\{} \;) + (cd ${INSTALL_WRKSRC}/doc && ${COPYTREE_SHARE} . ${STAGEDIR}${DOCSDIR}) .include diff --git a/net/openslp/pkg-plist b/net/openslp/pkg-plist index d08b88bf0164..562a2782e365 100644 --- a/net/openslp/pkg-plist +++ b/net/openslp/pkg-plist @@ -1,14 +1,7 @@ bin/slptool -@unexec if cmp -s %D/etc/openslp/slp.reg %D/etc/openslp/slp.reg.default; then rm -f %D/etc/openslp/slp.reg; fi -etc/openslp/slp.reg.default -@exec [ -f %B/slp.reg ] || cp %B/%f %B/slp.reg -@unexec if cmp -s %D/etc/openslp/slp.conf %D/etc/openslp/slp.conf.default; then rm -f %D/etc/openslp/slp.conf; fi -etc/openslp/slp.conf.default -@exec [ -f %B/slp.conf ] || cp %B/%f %B/slp.conf -@unexec if cmp -s %D/etc/openslp/slp.spi %D/etc/openslp/slp.spi.default; then rm -f %D/etc/openslp/slp.spi; fi -etc/openslp/slp.spi.default -@exec [ -f %B/slp.spi ] || cp %B/%f %B/slp.spi -@dirrm etc/openslp +@sample etc/openslp/slp.conf.sample +@sample etc/openslp/slp.reg.sample +@sample etc/openslp/slp.spi.sample include/slp.h lib/libslp.a lib/libslp.so @@ -72,9 +65,3 @@ sbin/slpd %%PORTDOCS%%%%DOCSDIR%%/html/UsersGuide/index.html %%PORTDOCS%%%%DOCSDIR%%/html/UsersGuide/smalllogo.jpg %%PORTDOCS%%%%DOCSDIR%%/html/faq.html -%%PORTDOCS%%@dirrm %%DOCSDIR%%/html/UsersGuide -%%PORTDOCS%%@dirrm %%DOCSDIR%%/html/IntroductionToSLP -%%PORTDOCS%%@dirrm %%DOCSDIR%%/html/ProgrammersGuide -%%PORTDOCS%%@dirrm %%DOCSDIR%%/html -%%PORTDOCS%%@dirrm %%DOCSDIR%%/rfc -%%PORTDOCS%%@dirrm %%DOCSDIR%% -- cgit v1.2.3