aboutsummaryrefslogtreecommitdiffstats
path: root/devel/libdasm
diff options
context:
space:
mode:
Diffstat (limited to 'devel/libdasm')
-rw-r--r--devel/libdasm/Makefile18
-rw-r--r--devel/libdasm/pkg-plist4
2 files changed, 4 insertions, 18 deletions
diff --git a/devel/libdasm/Makefile b/devel/libdasm/Makefile
index 3bae9304090d..e015fe42a979 100644
--- a/devel/libdasm/Makefile
+++ b/devel/libdasm/Makefile
@@ -13,15 +13,10 @@ COMMENT= Simple x86 disassembly library
USE_LDCONFIG= yes
PORTDOCS= HISTORY.txt README.txt
+PORTEXAMPLES= README.txt das.c simple.c
.include <bsd.port.options.mk>
-.if ${PORT_OPTIONS:MEXAMPLES}
-PLIST_SUB+= EXAMPLES=""
-.else
-PLIST_SUB+= EXAMPLES="@comment "
-.endif
-
.if ${ARCH} == "amd64" || ${ARCH} == "ia64"
CFLAGS+= -fPIC -DPIC
.endif
@@ -30,21 +25,16 @@ post-patch:
@${REINPLACE_CMD} -E 's,^(CC|CFLAGS|PREFIX).*=,\1 ?=,; \
s,libdasm.so.1.0,libdasm.so.1,g; \
s,cp ,${INSTALL_DATA} ,g' \
- ${WRKSRC}/Makefile \
- ${WRKSRC}/examples/Makefile
+ ${WRKSRC}/Makefile
post-install:
.if ${PORT_OPTIONS:MEXAMPLES}
@${MKDIR} ${EXAMPLESDIR}
- ${INSTALL_DATA} ${WRKSRC}/examples/README.txt ${EXAMPLESDIR}
- ${INSTALL_DATA} ${WRKSRC}/examples/das.c ${EXAMPLESDIR}
- ${INSTALL_DATA} ${WRKSRC}/examples/simple.c ${EXAMPLESDIR}
+ ${INSTALL_DATA} ${PORTEXAMPLES:S,^,${WRKSRC}/examples/,} ${EXAMPLESDIR}
.endif
.if ${PORT_OPTIONS:MDOCS}
@${MKDIR} ${DOCSDIR}
- @for f in ${PORTDOCS}; do \
- ${INSTALL_DATA} ${WRKSRC}/$${f} ${DOCSDIR}; \
- done
+ ${INSTALL_DATA} ${PORTDOCS:S,^,${WRKSRC}/,} ${DOCSDIR}
.endif
.include <bsd.port.mk>
diff --git a/devel/libdasm/pkg-plist b/devel/libdasm/pkg-plist
index 7c347fd47a5a..fd7bd82e9f3d 100644
--- a/devel/libdasm/pkg-plist
+++ b/devel/libdasm/pkg-plist
@@ -2,7 +2,3 @@ include/libdasm.h
lib/libdasm.a
lib/libdasm.so
lib/libdasm.so.1
-%%EXAMPLES%%%%EXAMPLESDIR%%/README.txt
-%%EXAMPLES%%%%EXAMPLESDIR%%/das.c
-%%EXAMPLES%%%%EXAMPLESDIR%%/simple.c
-%%EXAMPLES%%@dirrm %%EXAMPLESDIR%%