pkgsrc-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[pkgsrc/trunk]: pkgsrc/net/wireshark Add an option "x11" to enable or disable...



details:   https://anonhg.NetBSD.org/pkgsrc/rev/ca2b49641679
branches:  trunk
changeset: 538612:ca2b49641679
user:      tron <tron%pkgsrc.org@localhost>
date:      Wed Feb 13 20:10:20 2008 +0000

description:
Add an option "x11" to enable or disable X11 (GTK+) support. The default
is to enable X11 support. If the option is off only the "tshark" program
is built.

Based on a patch submitted by Jean-Edouard Babin in private e-mail.

diffstat:

 net/wireshark/Makefile   |   6 ++----
 net/wireshark/PLIST      |   6 +++---
 net/wireshark/options.mk |  19 +++++++++++++++++++
 3 files changed, 24 insertions(+), 7 deletions(-)

diffs (86 lines):

diff -r 296b294a474c -r ca2b49641679 net/wireshark/Makefile
--- a/net/wireshark/Makefile    Wed Feb 13 20:04:04 2008 +0000
+++ b/net/wireshark/Makefile    Wed Feb 13 20:10:20 2008 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.15 2008/01/18 05:08:52 tnn Exp $
+# $NetBSD: Makefile,v 1.16 2008/02/13 20:10:20 tron Exp $
 
 DISTNAME=              wireshark-0.99.7
 PKGREVISION=           1
@@ -20,10 +20,8 @@
 SHLIBTOOL_OVERRIDE=    # empty
 
 GNU_CONFIGURE=         YES
-CONFIGURE_ARGS+=       --enable-gtk2
 CONFIGURE_ARGS+=       --enable-static=no
 CONFIGURE_ARGS+=       --enable-threads
-CONFIGURE_ARGS+=       --with-gtk-prefix=${BUILDLINK_PREFIX.gtk2}
 CONFIGURE_ARGS+=       --with-ssl=${SSLBASE:Q}
 CONFIGURE_ARGS+=       --with-net-snmp
 CONFIGURE_ARGS+=       --with-pcap=${BUILDLINK_PREFIX.libpcap}
@@ -33,6 +31,7 @@
 PTHREAD_OPTS+=         require
 
 .include "../../mk/bsd.prefs.mk"
+.include "options.mk"
 
 .if !empty(MACHINE_PLATFORM:MDarwin-[567].*-*)
 USE_BUILTIN.libpcap=   no
@@ -54,7 +53,6 @@
 .include "../../net/net-snmp/buildlink3.mk"
 .include "../../security/gnutls/buildlink3.mk"
 .include "../../security/openssl/buildlink3.mk"
-.include "../../x11/gtk2/buildlink3.mk"
 
 .include "../../mk/pthread.buildlink3.mk"
 .include "../../mk/bsd.pkg.mk"
diff -r 296b294a474c -r ca2b49641679 net/wireshark/PLIST
--- a/net/wireshark/PLIST       Wed Feb 13 20:04:04 2008 +0000
+++ b/net/wireshark/PLIST       Wed Feb 13 20:10:20 2008 +0000
@@ -1,4 +1,4 @@
-@comment $NetBSD: PLIST,v 1.7 2007/12/15 13:53:27 tron Exp $
+@comment $NetBSD: PLIST,v 1.8 2008/02/13 20:10:20 tron Exp $
 bin/capinfos
 bin/dftest
 bin/dumpcap
@@ -8,7 +8,7 @@
 bin/randpkt
 bin/text2pcap
 bin/tshark
-bin/wireshark
+${WIRESHARK}bin/wireshark
 lib/libwireshark.la
 lib/libwiretap.la
 lib/wireshark/plugins/${PKGVERSION}/agentx.la
@@ -47,7 +47,7 @@
 man/man1/mergecap.1
 man/man1/text2pcap.1
 man/man1/tshark.1
-man/man1/wireshark.1
+${WIRESHARK}man/man1/wireshark.1
 man/man4/wireshark-filter.4
 share/wireshark/AUTHORS-SHORT
 share/wireshark/COPYING
diff -r 296b294a474c -r ca2b49641679 net/wireshark/options.mk
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/net/wireshark/options.mk  Wed Feb 13 20:10:20 2008 +0000
@@ -0,0 +1,19 @@
+# $NetBSD: options.mk,v 1.1 2008/02/13 20:10:20 tron Exp $
+
+PKG_OPTIONS_VAR=       PKG_OPTIONS.wireshark
+PKG_SUPPORTED_OPTIONS= x11
+PKG_SUGGESTED_OPTIONS= x11
+
+.include "../../mk/bsd.options.mk"
+
+.if !empty(PKG_OPTIONS:Mx11)
+CONFIGURE_ARGS+=       --enable-gtk2
+CONFIGURE_ARGS+=       --with-gtk-prefix=${BUILDLINK_PREFIX.gtk2}
+
+PLIST_SUBST+=          WIRESHARK=
+.include "../../x11/gtk2/buildlink3.mk"
+.else
+CONFIGURE_ARGS+=       --disable-wireshark
+
+PLIST_SUBST+=          WIRESHARK="@comment "
+.endif



Home | Main Index | Thread Index | Old Index