summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJeroen Roovers <jer@gentoo.org>2013-01-31 15:59:27 +0000
committerJeroen Roovers <jer@gentoo.org>2013-01-31 15:59:27 +0000
commit2af8d4cc0571aabf4a7c18e3fac810fdd6ec5bf2 (patch)
treeecc1c383a571c820fdf794e63573476edd9b1939 /net-analyzer
parentRemove old versions (diff)
downloadhistorical-2af8d4cc0571aabf4a7c18e3fac810fdd6ec5bf2.tar.gz
historical-2af8d4cc0571aabf4a7c18e3fac810fdd6ec5bf2.tar.bz2
historical-2af8d4cc0571aabf4a7c18e3fac810fdd6ec5bf2.zip
Use fcaps.eclass.
Package-Manager: portage-2.2.0_alpha161/cvs/Linux x86_64 Manifest-Sign-Key: 0xA792A613
Diffstat (limited to 'net-analyzer')
-rw-r--r--net-analyzer/wireshark/ChangeLog9
-rw-r--r--net-analyzer/wireshark/Manifest12
-rw-r--r--net-analyzer/wireshark/wireshark-1.6.13-r1.ebuild192
-rw-r--r--net-analyzer/wireshark/wireshark-1.6.13.ebuild4
-rw-r--r--net-analyzer/wireshark/wireshark-1.8.5-r1.ebuild204
5 files changed, 413 insertions, 8 deletions
diff --git a/net-analyzer/wireshark/ChangeLog b/net-analyzer/wireshark/ChangeLog
index 4feb41eeece1..5ec2d2fe6f42 100644
--- a/net-analyzer/wireshark/ChangeLog
+++ b/net-analyzer/wireshark/ChangeLog
@@ -1,6 +1,13 @@
# ChangeLog for net-analyzer/wireshark
# Copyright 1999-2013 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/net-analyzer/wireshark/ChangeLog,v 1.438 2013/01/31 15:21:50 jer Exp $
+# $Header: /var/cvsroot/gentoo-x86/net-analyzer/wireshark/ChangeLog,v 1.439 2013/01/31 15:59:24 jer Exp $
+
+*wireshark-1.8.5-r1 (31 Jan 2013)
+*wireshark-1.6.13-r1 (31 Jan 2013)
+
+ 31 Jan 2013; Jeroen Roovers <jer@gentoo.org> wireshark-1.6.13.ebuild,
+ +wireshark-1.6.13-r1.ebuild, +wireshark-1.8.5-r1.ebuild:
+ Use fcaps.eclass.
31 Jan 2013; Jeroen Roovers <jer@gentoo.org> wireshark-1.6.13.ebuild,
wireshark-1.8.5.ebuild:
diff --git a/net-analyzer/wireshark/Manifest b/net-analyzer/wireshark/Manifest
index 6461f88daa11..b89cbfad055b 100644
--- a/net-analyzer/wireshark/Manifest
+++ b/net-analyzer/wireshark/Manifest
@@ -9,15 +9,17 @@ DIST wireshark-1.6.13.tar.bz2 22077778 SHA256 32f4811bb7a259612aac04be5722da51f1
DIST wireshark-1.8.4.tar.bz2 24164286 SHA256 cae9ec0cb9fa0b732a76c0f72f8c15d763f8cdc2e389cda2da6c48c24559faac SHA512 4f0b7fd181eb74c5eb03e4b5e74546f9f02aa3d481faed2b08a84d98f4a61d808a86e5348046d66f8333ba8f8921db344c2187a1590117ae4bdc2ff85a96d305 WHIRLPOOL e2d1b7de34cc57342e645fbfa0175edcfc690d52f4ca579a931c4614ce97735ea190fa5e72ad6c9fb766f92ee701d6cf7cbd3c1f63ff8bba1f8b5d9265f2c31e
DIST wireshark-1.8.5.tar.bz2 24196532 SHA256 d4e4798216974a3c45e74b03644ee33b64481d2fe5c788c002266e5f141ee372 SHA512 3378310870e2e11cd4caf91e0571e2a52bd81bc76f1715997338d867a4d98ad7bb34e0f4443220386b498aeebce15c02d9825e50cf587587f573a5a0c578b039 WHIRLPOOL a9ca0f7cf14efcc4c56f7a2ab16ed0962998bc1467602d3f201e569513b0dde1363a7507e7a3f53535b8878ed2fd4a469699c88dcc1a3c4ce90461ac2c7a3c00
EBUILD wireshark-1.6.12.ebuild 6408 SHA256 67327344502561f78fa7e6fdedcb91bcf0b7c8ea5230c079e4a17f45ebc61809 SHA512 64c31a18e1266b4014becc209c7cc8d6e82dff3709e458ce669307cc04c156a8dc6a1bbf0aebf1825690ecf05b86f65faf304248cbcb7246d856164d1e0c6aaf WHIRLPOOL 258017e3678dac2b68efb81129e114e0a0bfba0d5ed97941d69c97588649821f884dd4caa0b724247fa387eafffc953f917a6d89daa8ff1b67ef58f2385d8983
-EBUILD wireshark-1.6.13.ebuild 6406 SHA256 bd0c039457de1fa54eea7c713adaef5d7bbc2ff89e143a9684ee104ec676b724 SHA512 b943de5d2082d72d47334220ba998d986d792d1af4e428163789d645735e6834895791a018f988a6521fe38d26104d79ed167d5193d2127e509af7cdbf2a3f95 WHIRLPOOL 78237e2fd555f8fa16e754f334619c145ed862eb441be9053c70e8f2ecf0ab05cffb2bb8e986f6a24a02938b301691d250361555a65357855006ba5ff7a6cabd
+EBUILD wireshark-1.6.13-r1.ebuild 5295 SHA256 063ea6ae0a34d71f3c64b2d4e7edeabd99ac9eb1d5f94223ab738781e062e035 SHA512 25c173b855d01d506b0ec032caa293c5bc0e5362f56d12bc80d79d46bb3928cc5dd2fde7cf5a5a6cf9de6ea6830f84e530e8aeaf8c7098754abc457fe04f7b7c WHIRLPOOL 4a5e13c4bd6497e651aae48dbce72b3ec49e808b43c83d76910fe047c6031995d4de143e8af915d131e6dcbe4ed575cac90479fad59f2c3c127901aba83078e2
+EBUILD wireshark-1.6.13.ebuild 6414 SHA256 c8597c8a6f6130870590674bcba96ca5eaea12595f9710a35e960738787544e6 SHA512 f6963137ee54cf6cd1591dfbb12d2112f54dae7595a54e299fbddefcfb5a9b02f32fbfb1d69825042d9fbad1b374739cae5a139d84d4cbb273d1316a8d88b6b8 WHIRLPOOL 803406f84af0c57bffbde8d89de8f9bf6f6135b56efef731a95b02cd8b8ab8b57ad784921bcf19081538fbb841195c4f2036d7c7cfcb65892ed3a145281cf3d7
EBUILD wireshark-1.8.4.ebuild 6799 SHA256 9763da6b4a100d0c1721ac6b8316c1a18dcdcf573dda9781bdff9d0d09099f83 SHA512 bb5fbe1e43088eee4670a5155d4e74a321b859c339360e9abd4c30ec7e3e31c02549fc33ca97f1b729fd08064f2ddaeecb4bc09ff8674e74f962c9b828dd761a WHIRLPOOL 7d3e5889cee8b26ce3f514e8c3d4a9c62d72dbb113deef3f05200709e2e1fea98d4a6e258c49c944cca26ad6e6d13790d4c75c71c7d9338ab0ccb173ce8ddaa0
+EBUILD wireshark-1.8.5-r1.ebuild 5682 SHA256 0152c2ad5950d5baf2f5ad0beebb4bb93b7202b787a8b1170d386803b05c9a13 SHA512 b6a447760f4a67f187fbf95b80904eb57937dfca49037c72c945971cd1f7c491cd9aa46e8040dd75018f6375638b02265ba22d8f1661bb896ba95b2ed85f6166 WHIRLPOOL 4342e097f6c2f559be7edbd7ae284b7d494c974b8b97c7af701bd62e9d6cc4d4acc270e047e1a0a93f6e5a953211cf4fff932e84d72f55c9ef133857d43671a8
EBUILD wireshark-1.8.5.ebuild 6800 SHA256 09960b819f7c68168e0a9fb53fad9aca019d5a8f3c2ae538f6b26e740ca1221e SHA512 b7dadaf40ebd5c6df26ebbdea9392892cbbcf07d7feb9465b16e228f5de388ce84585f81805d1d6bfba94018a660d9a6b169b594088e8d699c22a3c06ec571f3 WHIRLPOOL 3453cc8d84d5186b658c1070c502a7166a7d49e8b2e4b186eee8cd06bb3bc050325d7f0a2a8c76ba6976a38a47da34349b6bf9edf66e42421e25899f884a4aa4
-MISC ChangeLog 63748 SHA256 423f542dbc0d3de5a0893958f3bfa26f98972ac1051e23bce8d310b1b3e9502e SHA512 138d2e0ff53cb77e5e0560ace1ba03d02a8b2f4c16e045b2b830d179a59dee8c10af6a0f5fe0c129011d6331041fabff374996a1b7ec2ab4ba7b1e4904edaeaa WHIRLPOOL fed74e0e6d95b51cfe932b1c75b8da845acf5e002d1b40fe219cd3f777a9b831106f7194aeabb1b49abf44f27d89b37ec029eff89abb9f0d48407208de45ba9f
+MISC ChangeLog 63970 SHA256 6e1969817b0ea19286c61e5ea99569d84002ff3e7b7ec6b76b0123e2d39ffeaa SHA512 737fbe84a1d6ca17d8d5cb9d8d9a4e6c320d52b7b5b2a6e567350809075173a6ba803c1af8425b91ee7ddde16a2d30ceb48a7b70d8e5f9a543989f2856b97fb8 WHIRLPOOL ff77c93669948a7f14d5781f32e20f836eb99a0fdcf31b0debc9d75ef2fd18d59d309255887ce3afc604eff2b59ed743c3ca51d682c8e256ceecda55c12b5d39
MISC metadata.xml 2589 SHA256 5a4eeb9572df6946a2b3ffbb5f5f4955cfd709ccb79cd23ec6aed41f49b60dab SHA512 bc027bd22193d1a613f26fe30265f5fac0f22cac0c1ed8cfa148fa6bf7c4a4777c76cbaeea5f5f19591d8c78695d13eb29cc00f225c2b44ad1d8a63a8881bafe WHIRLPOOL 5596bd3eb91bdbb1fd9ac2386d72e6a038c3966ad53a81889fc6d4bf32b2ffe75b8f55fdf84a7a84ff2b7b2dcddcaf0dc889ea6595537796ca30e7e5e11494bd
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.19 (GNU/Linux)
-iEYEAREIAAYFAlEKjBAACgkQVWmRsqeSphOd4wCfeeQv/8YNdmn/x6E5+NRHxPqd
-VhYAn3VPNZGEL/04nq9r5J0Bfk1mfHMA
-=jcQF
+iEYEAREIAAYFAlEKlN8ACgkQVWmRsqeSphPUrgCfaaQ7l+PtS2/JfjelkKOe1HBN
+jUkAnioOLWpiUEgfgaOAF/D+kyATfmIV
+=+Sv3
-----END PGP SIGNATURE-----
diff --git a/net-analyzer/wireshark/wireshark-1.6.13-r1.ebuild b/net-analyzer/wireshark/wireshark-1.6.13-r1.ebuild
new file mode 100644
index 000000000000..d0923ff96bba
--- /dev/null
+++ b/net-analyzer/wireshark/wireshark-1.6.13-r1.ebuild
@@ -0,0 +1,192 @@
+# Copyright 1999-2013 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/net-analyzer/wireshark/wireshark-1.6.13-r1.ebuild,v 1.1 2013/01/31 15:59:24 jer Exp $
+
+EAPI=5
+PYTHON_DEPEND="python? 2"
+inherit autotools eutils fcaps flag-o-matic python toolchain-funcs user
+
+[[ -n ${PV#*_rc} && ${PV#*_rc} != ${PV} ]] && MY_P=${PN}-${PV/_} || MY_P=${P}
+DESCRIPTION="A network protocol analyzer formerly known as ethereal"
+HOMEPAGE="http://www.wireshark.org/"
+SRC_URI="http://www.wireshark.org/download/src/all-versions/${MY_P}.tar.bz2"
+
+LICENSE="GPL-2"
+SLOT="0/${PV}"
+KEYWORDS="~alpha ~amd64 ~hppa ~ia64 ~ppc ~ppc64 ~sparc ~x86 ~x86-fbsd"
+IUSE="
+ adns doc doc-pdf gtk ipv6 libadns lua crypt geoip kerberos profile
+ +pcap portaudio python selinux smi ssl threads zlib
+"
+RDEPEND=">=dev-libs/glib-2.14:2
+ zlib? ( sys-libs/zlib
+ !=sys-libs/zlib-1.2.4 )
+ smi? ( net-libs/libsmi )
+ gtk? ( >=x11-libs/gtk+-2.4.0:2
+ x11-libs/pango
+ dev-libs/atk
+ x11-misc/xdg-utils )
+ ssl? ( <net-libs/gnutls-3 )
+ crypt? ( dev-libs/libgcrypt )
+ pcap? ( net-libs/libpcap )
+ kerberos? ( virtual/krb5 )
+ portaudio? ( media-libs/portaudio )
+ adns? (
+ !libadns? ( >=net-dns/c-ares-1.5 )
+ )
+ libadns? ( net-libs/adns )
+ geoip? ( dev-libs/geoip )
+ lua? ( >=dev-lang/lua-5.1 )
+ selinux? ( sec-policy/selinux-wireshark )"
+
+DEPEND="${RDEPEND}
+ doc? ( dev-libs/libxslt
+ dev-libs/libxml2
+ app-doc/doxygen
+ doc-pdf? ( dev-java/fop ) )
+ virtual/pkgconfig
+ dev-lang/perl
+ sys-devel/bison
+ sys-apps/sed
+ sys-devel/flex
+"
+
+S=${WORKDIR}/${MY_P}
+
+pkg_setup() {
+ if ! use gtk; then
+ ewarn "USE=-gtk disables gtk-based gui called wireshark."
+ ewarn "Only command line utils will be built available"
+ fi
+ if use python; then
+ python_set_active_version 2
+ python_pkg_setup
+ fi
+}
+
+src_prepare() {
+ epatch \
+ "${FILESDIR}"/${PN}-1.6.6-gtk-pcap.patch \
+ "${FILESDIR}"/${PN}-1.6.13-ldflags.patch
+ sed -i -e 's|.png||g' ${PN}.desktop || die
+ eautoreconf
+}
+
+src_configure() {
+ local myconf
+
+ if [[ $(gcc-major-version) -lt 3 ||
+ ( $(gcc-major-version) -eq 3 &&
+ $(gcc-minor-version) -le 4 ) ]] ; then
+ die "Unsupported compiler version, please upgrade."
+ fi
+
+ # profile and pie are incompatible #215806, #292991
+ if use profile; then
+ ewarn "You've enabled the 'profile' USE flag, building PIE binaries is disabled."
+ ewarn "Also ignore \"unrecognized option '-nopie'\" gcc warning #358101."
+ append-flags $(test-flags-CC -nopie)
+ fi
+
+ if use adns; then
+ if use libadns; then
+ myconf+=" --with-adns --without-c-ares"
+ else
+ myconf+=" --without-adns --with-c-ares"
+ fi
+ else
+ if use libadns; then
+ myconf+=" --with-adns --without-c-ares"
+ fi
+ fi
+
+ # Workaround bug #213705. If krb5-config --libs has -lcrypto then pass
+ # --with-ssl to ./configure. (Mimics code from acinclude.m4).
+ if use kerberos; then
+ case `krb5-config --libs` in
+ *-lcrypto*)
+ ewarn "Kerberos was built with ssl support: linkage with openssl is enabled."
+ ewarn "Note there are annoying license incompatibilities between the OpenSSL"
+ ewarn "license and the GPL, so do your check before distributing such package."
+ myconf+=" --with-ssl"
+ ;;
+ esac
+ fi
+
+ # Hack around inability to disable doxygen/fop doc generation
+ use doc || export ac_cv_prog_HAVE_DOXYGEN=false
+ use doc-pdf || export ac_cv_prog_HAVE_FOP=false
+
+ # dumpcap requires libcap, setuid-install requires dumpcap
+ econf \
+ $(use pcap && use_enable !filecaps setuid-install) \
+ $(use pcap && use_enable filecaps setcap-install) \
+ $(use_enable gtk wireshark) \
+ $(use_enable ipv6) \
+ $(use_enable profile profile-build) \
+ $(use_enable threads) \
+ $(use_with filecaps libcap) \
+ $(use_with crypt gcrypt) \
+ $(use_with geoip) \
+ $(use_with kerberos krb5) \
+ $(use_with lua) \
+ $(use_with pcap dumpcap-group wireshark) \
+ $(use_with pcap) \
+ $(use_with portaudio) \
+ $(use_with python) \
+ $(use_with smi libsmi) \
+ $(use_with ssl gnutls) \
+ $(use_with zlib) \
+ --sysconfdir="${EPREFIX}"/etc/wireshark \
+ --disable-extra-gcc-checks \
+ ${myconf}
+}
+
+src_compile() {
+ default
+ use doc && cd docbook && { emake; }
+}
+
+src_install() {
+ default
+ if use doc; then
+ dohtml -r docbook/{release-notes.html,ws{d,u}g_html{,_chunked}}
+ if use doc-pdf; then
+ insinto /usr/share/doc/${PF}/pdf/
+ doins docbook/{{developer,user}-guide,release-notes}-{a4,us}.pdf
+ fi
+ fi
+
+ # FAQ is not required as is installed from help/faq.txt
+ dodoc AUTHORS ChangeLog NEWS README{,.bsd,.linux,.macos,.vmware} \
+ doc/{randpkt.txt,README*}
+
+ insinto /usr/include/wiretap
+ doins wiretap/wtap.h
+
+ if use gtk; then
+ for c in hi lo; do
+ for d in 16 32 48; do
+ insinto /usr/share/icons/${c}color/${d}x${d}/apps
+ newins image/${c}${d}-app-wireshark.png wireshark.png
+ done
+ done
+ domenu wireshark.desktop
+ fi
+ use pcap && chmod o-x "${ED}"/usr/bin/dumpcap #357237
+}
+
+pkg_postinst() {
+ # Add group for users allowed to sniff.
+ enewgroup wireshark
+
+ if use filecaps && use pcap; then
+ fcaps -o 0 -g wireshark -m 550 \
+ cap_dac_read_search,cap_net_raw,cap_net_admin \
+ "${EROOT}"/usr/bin/dumpcap
+ fi
+
+ ewarn "NOTE: To run wireshark as normal user you have to add yourself to"
+ ewarn "the wireshark group. This security measure ensures that only trusted"
+ ewarn "users are allowed to sniff your traffic."
+}
diff --git a/net-analyzer/wireshark/wireshark-1.6.13.ebuild b/net-analyzer/wireshark/wireshark-1.6.13.ebuild
index 6bba367f852a..816fbf3ace2f 100644
--- a/net-analyzer/wireshark/wireshark-1.6.13.ebuild
+++ b/net-analyzer/wireshark/wireshark-1.6.13.ebuild
@@ -1,6 +1,6 @@
# Copyright 1999-2013 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/net-analyzer/wireshark/wireshark-1.6.13.ebuild,v 1.9 2013/01/31 15:21:50 jer Exp $
+# $Header: /var/cvsroot/gentoo-x86/net-analyzer/wireshark/wireshark-1.6.13.ebuild,v 1.10 2013/01/31 15:59:24 jer Exp $
EAPI=5
PYTHON_DEPEND="python? 2"
@@ -165,7 +165,7 @@ src_configure() {
$(use_enable profile profile-build) \
$(use_enable threads) \
$(use_with caps libcap) \
- $(use_with crypt) \
+ $(use_with crypt gcrypt) \
$(use_with geoip) \
$(use_with kerberos krb5) \
$(use_with lua) \
diff --git a/net-analyzer/wireshark/wireshark-1.8.5-r1.ebuild b/net-analyzer/wireshark/wireshark-1.8.5-r1.ebuild
new file mode 100644
index 000000000000..6a62d64ca5e4
--- /dev/null
+++ b/net-analyzer/wireshark/wireshark-1.8.5-r1.ebuild
@@ -0,0 +1,204 @@
+# Copyright 1999-2013 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/net-analyzer/wireshark/wireshark-1.8.5-r1.ebuild,v 1.1 2013/01/31 15:59:24 jer Exp $
+
+EAPI="5"
+PYTHON_DEPEND="python? 2"
+inherit autotools eutils fcaps flag-o-matic python toolchain-funcs user
+
+[[ -n ${PV#*_rc} && ${PV#*_rc} != ${PV} ]] && MY_P=${PN}-${PV/_} || MY_P=${P}
+DESCRIPTION="A network protocol analyzer formerly known as ethereal"
+HOMEPAGE="http://www.wireshark.org/"
+SRC_URI="http://www.wireshark.org/download/src/all-versions/${MY_P}.tar.bz2"
+
+LICENSE="GPL-2"
+SLOT="0/${PV}"
+KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~ppc ~ppc64 ~sparc ~x86 ~x86-fbsd"
+IUSE="
+ adns doc doc-pdf geoip gtk crypt ipv6 kerberos libadns lua +pcap
+ portaudio profile python selinux smi ssl zlib
+"
+RDEPEND="
+ >=dev-libs/glib-2.14:2
+ zlib? ( sys-libs/zlib
+ !=sys-libs/zlib-1.2.4 )
+ smi? ( net-libs/libsmi )
+ gtk? ( >=x11-libs/gtk+-2.4.0:2
+ x11-libs/pango
+ dev-libs/atk
+ x11-misc/xdg-utils )
+ ssl? ( net-libs/gnutls dev-libs/libgcrypt )
+ crypt? ( dev-libs/libgcrypt )
+ pcap? ( net-libs/libpcap )
+ kerberos? ( virtual/krb5 )
+ portaudio? ( media-libs/portaudio )
+ adns? (
+ !libadns? ( >=net-dns/c-ares-1.5 )
+ )
+ libadns? ( net-libs/adns )
+ geoip? ( dev-libs/geoip )
+ lua? ( >=dev-lang/lua-5.1 )
+ selinux? ( sec-policy/selinux-wireshark )
+"
+
+DEPEND="
+ ${RDEPEND}
+ doc? ( dev-libs/libxslt
+ dev-libs/libxml2
+ app-doc/doxygen
+ doc-pdf? ( dev-java/fop ) )
+ virtual/pkgconfig
+ dev-lang/perl
+ sys-devel/bison
+ sys-apps/sed
+ sys-devel/flex
+"
+
+S=${WORKDIR}/${MY_P}
+
+pkg_setup() {
+ if ! use gtk; then
+ ewarn "USE=-gtk disables gtk-based gui called wireshark."
+ ewarn "Only command line utils will be built available"
+ fi
+ if use python; then
+ python_set_active_version 2
+ python_pkg_setup
+ fi
+}
+
+src_prepare() {
+ epatch \
+ "${FILESDIR}"/${PN}-1.6.13-ldflags.patch \
+ "${FILESDIR}"/${PN}-1.8.3-gnutls3.patch
+ sed -i -e 's|.png||g' ${PN}.desktop || die
+ eautoreconf
+}
+
+src_configure() {
+ local myconf
+
+ if [[ $(gcc-major-version) -lt 3 ||
+ ( $(gcc-major-version) -eq 3 &&
+ $(gcc-minor-version) -le 4 ) ]] ; then
+ die "Unsupported compiler version, please upgrade."
+ fi
+
+ # profile and pie are incompatible #215806, #292991
+ if use profile; then
+ ewarn "You've enabled the 'profile' USE flag, building PIE binaries is disabled."
+ ewarn "Also ignore \"unrecognized option '-nopie'\" gcc warning #358101."
+ append-flags $(test-flags-CC -nopie)
+ fi
+
+ if use adns; then
+ if use libadns; then
+ myconf+=( "--with-adns --without-c-ares" )
+ else
+ myconf+=( "--without-adns --with-c-ares" )
+ fi
+ else
+ if use libadns; then
+ myconf+=( "--with-adns --without-c-ares" )
+ else
+ myconf+=( "--without-adns --without-c-ares" )
+ fi
+ fi
+ # Workaround bug #213705. If krb5-config --libs has -lcrypto then pass
+ # --with-ssl to ./configure. (Mimics code from acinclude.m4).
+ if use kerberos; then
+ case `krb5-config --libs` in
+ *-lcrypto*)
+ ewarn "Kerberos was built with ssl support: linkage with openssl is enabled."
+ ewarn "Note there are annoying license incompatibilities between the OpenSSL"
+ ewarn "license and the GPL, so do your check before distributing such package."
+ myconf+=( "--with-ssl" )
+ ;;
+ esac
+ fi
+
+ # Hack around inability to disable doxygen/fop doc generation
+ use doc || export ac_cv_prog_HAVE_DOXYGEN=false
+ use doc-pdf || export ac_cv_prog_HAVE_FOP=false
+
+ # dumpcap requires libcap, setuid-install requires dumpcap
+ econf \
+ $(use pcap && use_enable !filecaps setuid-install) \
+ $(use pcap && use_enable filecaps setcap-install) \
+ $(use_enable gtk wireshark) \
+ $(use_enable ipv6) \
+ $(use_enable profile profile-build) \
+ $(use_with filecaps libcap) \
+ $(use_with crypt gcrypt) \
+ $(use_with geoip) \
+ $(use_with kerberos krb5) \
+ $(use_with lua) \
+ $(use_with pcap dumpcap-group wireshark) \
+ $(use_with pcap) \
+ $(use_with portaudio) \
+ $(use_with python) \
+ $(use_with smi libsmi) \
+ $(use_with ssl gnutls) \
+ $(use_with zlib) \
+ --disable-extra-gcc-checks \
+ --disable-usr-local \
+ --sysconfdir="${EPREFIX}"/etc/wireshark \
+ ${myconf[@]}
+}
+
+src_compile() {
+ default
+ use doc && emake -C docbook
+}
+
+src_install() {
+ default
+ if use doc; then
+ dohtml -r docbook/{release-notes.html,ws{d,u}g_html{,_chunked}}
+ if use doc-pdf; then
+ insinto /usr/share/doc/${PF}/pdf/
+ doins docbook/{{developer,user}-guide,release-notes}-{a4,us}.pdf
+ fi
+ fi
+
+ # FAQ is not required as is installed from help/faq.txt
+ dodoc AUTHORS ChangeLog NEWS README{,.bsd,.linux,.macos,.vmware} \
+ doc/{randpkt.txt,README*}
+
+ # install headers
+ local wsheader
+ for wsheader in $( echo $(< debian/wireshark-dev.header-files ) ); do
+ insinto /usr/include/wireshark/$( dirname ${wsheader} )
+ doins ${wsheader}
+ done
+
+ #with the above this really shouldn't be needed, but things may be looking in wiretap/ instead of wireshark/wiretap/
+ insinto /usr/include/wiretap
+ doins wiretap/wtap.h
+
+ if use gtk; then
+ for c in hi lo; do
+ for d in 16 32 48; do
+ insinto /usr/share/icons/${c}color/${d}x${d}/apps
+ newins image/${c}${d}-app-wireshark.png wireshark.png
+ done
+ done
+ domenu wireshark.desktop
+ fi
+ use pcap && chmod o-x "${ED}"/usr/bin/dumpcap #357237
+}
+
+pkg_postinst() {
+ # Add group for users allowed to sniff.
+ enewgroup wireshark
+
+ if use filecaps && use pcap; then
+ fcaps -o 0 -g wireshark -m 550 \
+ cap_dac_read_search,cap_net_raw,cap_net_admin \
+ "${EROOT}"/usr/bin/dumpcap
+ fi
+
+ ewarn "NOTE: To run wireshark as normal user you have to add yourself to"
+ ewarn "the wireshark group. This security measure ensures that only trusted"
+ ewarn "users are allowed to sniff your traffic."
+}