summaryrefslogtreecommitdiff
path: root/emulators/p11
diff options
context:
space:
mode:
authorjlam <jlam@pkgsrc.org>2006-06-16 16:15:42 +0000
committerjlam <jlam@pkgsrc.org>2006-06-16 16:15:42 +0000
commit024cad2c8e2d00971307363f8c7a7f76d99ac64f (patch)
tree37099ea4cfe238032858559ebcd8ead7abbdf826 /emulators/p11
parent4272b287d9903bd58036188775a2aa7437fdd56b (diff)
downloadpkgsrc-024cad2c8e2d00971307363f8c7a7f76d99ac64f.tar.gz
Fix the PLIST to handle platforms that have any of BPF, TUN, or TAP
devices.
Diffstat (limited to 'emulators/p11')
-rw-r--r--emulators/p11/Makefile27
-rw-r--r--emulators/p11/PLIST8
2 files changed, 26 insertions, 9 deletions
diff --git a/emulators/p11/Makefile b/emulators/p11/Makefile
index 6c4b2a11d8d..f255983d92c 100644
--- a/emulators/p11/Makefile
+++ b/emulators/p11/Makefile
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.13 2006/04/12 19:49:26 joerg Exp $
+# $NetBSD: Makefile,v 1.14 2006/06/16 16:15:42 jlam Exp $
#
DISTNAME= p11-2.10a
@@ -16,11 +16,28 @@ USE_TOOLS+= gmake
.include "../../mk/bsd.prefs.mk"
-.if ${OPSYS} == "DragonFly"
-PLIST_SUBST+= HAS_TAP=
-CONFIGURE_ENV+= ac_cv_epp_bpf=yes ac_cv_epp_tun=yes ac_cv_epp_tap=yes
+# bfp, tap, and tun tests taken from p11 configure script
+.if exists(/dev/bpf0)
+PLIST_SUBST+= BPF=
+.else
+PLIST_SUBST+= BPF="@comment "
+.endif
+.if exists(/dev/tap0) || exists(/dev/net/tun)
+PLIST_SUBST+= TAP=
+.elif ${OPSYS} == "DragonFly"
+PLIST_SUBST+= TAP= # DragonFly has TAP
+.else
+PLIST_SUBST+= TAP="@comment "
+.endif
+.if exists(/dev/tun) || exists(/dev/tun0) || exists(/dev/net/tun)
+PLIST_SUBST+= TUN=
.else
-PLIST_SUBST+= HAS_TAP="@comment "
+PLIST_SUBST+= TUN="@comment "
+.endif
+
+# Force the bpf, tun, and tap epp backends to be built on DragonFly.
+.if ${OPSYS} == "DragonFly"
+CONFIGURE_ENV+= ac_cv_epp_bpf=yes ac_cv_epp_tun=yes ac_cv_epp_tap=yes
.endif
# override MAKEFLAGS in the build and install stages
diff --git a/emulators/p11/PLIST b/emulators/p11/PLIST
index 4dd1995d4bd..626502a0085 100644
--- a/emulators/p11/PLIST
+++ b/emulators/p11/PLIST
@@ -1,9 +1,9 @@
-@comment $NetBSD: PLIST,v 1.2 2006/04/12 19:49:27 joerg Exp $
+@comment $NetBSD: PLIST,v 1.3 2006/06/16 16:15:42 jlam Exp $
bin/p11
-libexec/p11/epp_bpf
+${BPF}libexec/p11/epp_bpf
libexec/p11/epp_fifo
-${HAS_TAP}libexec/p11/epp_tap
-libexec/p11/epp_tun
+${TAP}libexec/p11/epp_tap
+${TUN}libexec/p11/epp_tun
libexec/p11/fmt
libexec/p11/lp_file
libexec/p11/tty_fifo