summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJeroen Roovers <jer@gentoo.org>2013-02-11 15:31:39 +0000
committerJeroen Roovers <jer@gentoo.org>2013-02-11 15:31:39 +0000
commit54390b02f672826ea63d7edba0965918cefc5dc2 (patch)
treee8300db430394440819bbd31d8eeebe942322e7f /net-analyzer
parentStable for arm, wrt bug #456080 (diff)
downloadhistorical-54390b02f672826ea63d7edba0965918cefc5dc2.tar.gz
historical-54390b02f672826ea63d7edba0965918cefc5dc2.tar.bz2
historical-54390b02f672826ea63d7edba0965918cefc5dc2.zip
Old.
Package-Manager: portage-2.2.0_alpha161/cvs/Linux i686 Manifest-Sign-Key: 0xA792A613
Diffstat (limited to 'net-analyzer')
-rw-r--r--net-analyzer/wireshark/ChangeLog6
-rw-r--r--net-analyzer/wireshark/Manifest18
-rw-r--r--net-analyzer/wireshark/metadata.xml1
-rw-r--r--net-analyzer/wireshark/wireshark-1.6.12.ebuild229
-rw-r--r--net-analyzer/wireshark/wireshark-1.8.4.ebuild241
5 files changed, 17 insertions, 478 deletions
diff --git a/net-analyzer/wireshark/ChangeLog b/net-analyzer/wireshark/ChangeLog
index 5a450cc53983..9a8fe38dd99e 100644
--- a/net-analyzer/wireshark/ChangeLog
+++ b/net-analyzer/wireshark/ChangeLog
@@ -1,6 +1,10 @@
# 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.445 2013/02/09 20:12:30 ago Exp $
+# $Header: /var/cvsroot/gentoo-x86/net-analyzer/wireshark/ChangeLog,v 1.446 2013/02/11 15:31:38 jer Exp $
+
+ 11 Feb 2013; Jeroen Roovers <jer@gentoo.org> -wireshark-1.6.12.ebuild,
+ -wireshark-1.8.4.ebuild, metadata.xml:
+ Old.
09 Feb 2013; Agostino Sarubbo <ago@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 2336894cd415..a0d6942326f5 100644
--- a/net-analyzer/wireshark/Manifest
+++ b/net-analyzer/wireshark/Manifest
@@ -1,15 +1,21 @@
+-----BEGIN PGP SIGNED MESSAGE-----
+Hash: SHA256
+
AUX wireshark-1.6.13-ldflags.patch 230 SHA256 bb56440fb9de9ed480b992d202feac93a53003e9fa47869f54c6f2f30d315720 SHA512 c4a2c66e6ea9b523ca9f5a3e37411221f5aa630de07d7bf84633855ac44da60b3b493671e578dbfd67de94e87ab1c79203f9b80b57f9460f2a81ee39f58171b3 WHIRLPOOL ca20e190c7a8d7ca69c6d90cfb28f8f1c8896b6793b9a026567ec4df4f7080ca6424ab249d01754db1059891d32362444178272489b4425e895f3031a0e1e0f7
AUX wireshark-1.6.6-gtk-pcap.patch 841 SHA256 862c301f450fcb775e3bd907e5a6ca667b5a11b819768b66a7c848c2c3c90d8a SHA512 0ed1bce8b57942de72ee0a8d78ef7cc345ffea512248fa65acd4e8386a5aa61dde14663090578c78f3eee88c7966e8d40aa6d3dce13146c2adf5ed8ded019253 WHIRLPOOL a45a3d04c9823eb149174fbbaaeb5437e525d77da962aa627509941da3119e87d4eef26cb06b1d3534356c4fd1d4bf31bc102dbf8b3f69994a19dba8d730d05f
AUX wireshark-1.8.3-gnutls3.patch 460 SHA256 75db77b9dd286272583c6def9ce9ebe2feea59c8c709eb7065e0c4d9bf741967 SHA512 8c37c020e1addcff70f631b710a15de040eb7af5fa43c0faad6729a090be180fb9d52ebd10a3aac6ad6e49344f795d27e093b9e7e3f591c835a0883ad9066ee6 WHIRLPOOL 59646ef16e7042cbcfa827525cae0f0de7e8cd7f9ccc01324e73b91c1dfd454ca7f7156bc477bdd601bd908969d217c251a33d91d9f6b334b0737035b5d55b66
-DIST wireshark-1.6.12.tar.bz2 22052437 SHA256 03b84a1a6d46e53f2ae900237e0391281557297fa5c2b2093049c0fb418352fb SHA512 fa9ccc44840f372117da23770cc8438bceafa2e653ed884ed4c5f8a0624506d8778e3be54abb3c88e85564ff443be54b56db3621a6f8058fe8458b6efc5710f9 WHIRLPOOL cd7a3e7d03ee3c94fbc7784e4619ad3bf48700f86e4531cdf24fabf40d406613f6637957b0d66c182b07d3b340263c47cc73a093fd63f3d8f61a0c3250b09555
DIST wireshark-1.6.13.tar.bz2 22077778 SHA256 32f4811bb7a259612aac04be5722da51f145fcf66fcf69f358e98d4cb78dd091 SHA512 addb42d7630c4c382099cad696581c73a43ebc31727d1838926cb306ff13641b6b586063fa9186a7c0f24522690fa8955844b228ea9b79b7a71ae893730dba45 WHIRLPOOL 72a91fb14529db5e737980b816bd70175b2b0245e387e0fb3d0e937bdddc46085f01bfab75c34663f768b119270bd676367ecc3b0ffa8872e43679bfeb05152f
-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-r1.ebuild 5295 SHA256 063ea6ae0a34d71f3c64b2d4e7edeabd99ac9eb1d5f94223ab738781e062e035 SHA512 25c173b855d01d506b0ec032caa293c5bc0e5362f56d12bc80d79d46bb3928cc5dd2fde7cf5a5a6cf9de6ea6830f84e530e8aeaf8c7098754abc457fe04f7b7c WHIRLPOOL 4a5e13c4bd6497e651aae48dbce72b3ec49e808b43c83d76910fe047c6031995d4de143e8af915d131e6dcbe4ed575cac90479fad59f2c3c127901aba83078e2
EBUILD wireshark-1.6.13.ebuild 6409 SHA256 2084d4b6fbe051f2954e0e70f43e8b69bc4415f7843511d0778a982ab08185c5 SHA512 06e5ed612d116caa105a9c0713cf8cc9af2f7c81bdc07d2cddf5dfcab4d0f0bd15ba86c8902d251369448e8998091d413e24a22a9fe813aeb1fe571a85bcf29f WHIRLPOOL aa1752218035641aacc74fa0ef553908ed13a219c29268d7eb37833b3dd0bb2e26d845056b45901826427d8b8a4a31c9b00b4b68d2be43bfaafeee89e1833eaa
-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 6796 SHA256 f6b50852f4c03692aa88a9d98f3f7edc8131d7cb8f490e483b50358180472630 SHA512 b389b70836ad0e3539e9f1e7eca73362e9ebc87a078422def834559818b0145defca90539284c98657ef704d73b94da14253c90c95f4e6f96c408826a8e2537a WHIRLPOOL 61054a9accda9ac0661bdee3d35c2e7281fcf5c867f1d0f3c789acb86188153507e13a91b3e442f58da69cf5ea9eb548f7c314803ffb3d21eb4c4bd6945c1f77
-MISC ChangeLog 64666 SHA256 e4d987981977ce0e2c1959c4ad460e7bb3e51b6aa9124fac578cc07259c29806 SHA512 cbbc4e002fa075ab2a6526fd67ab781432759ca5f34c786abece19921da3f53ba9b2370b9d05e1b31199333990dd5173e9b72dbad9436aea1dc0d9b99efe8eca WHIRLPOOL 67a3dc201d097571b4c8569a3920e297bb8812e96bbfbdf6f725aedd122ebdda7462032059a3e691261f038b837d65db948056046b4349052fb704e4243a4fd7
-MISC metadata.xml 2589 SHA256 5a4eeb9572df6946a2b3ffbb5f5f4955cfd709ccb79cd23ec6aed41f49b60dab SHA512 bc027bd22193d1a613f26fe30265f5fac0f22cac0c1ed8cfa148fa6bf7c4a4777c76cbaeea5f5f19591d8c78695d13eb29cc00f225c2b44ad1d8a63a8881bafe WHIRLPOOL 5596bd3eb91bdbb1fd9ac2386d72e6a038c3966ad53a81889fc6d4bf32b2ffe75b8f55fdf84a7a84ff2b7b2dcddcaf0dc889ea6595537796ca30e7e5e11494bd
+MISC ChangeLog 64788 SHA256 8ecd1eec91495804fb3c8c83f57f2933947327b9536bb0247e7fdc51ecf47ee7 SHA512 5fd109ced06bfe7ad63699b4f2cd8f1ec82a01186eb5efd1a1977e08bb5a516cc65801040659d98161b4cf766a30492aa0fde6a7f39e94cac9c0bae48934c78c WHIRLPOOL 23cffbc5c497ffac58c1e024bd657f42ad541ce905e3540a64b21a027f04904bb844ce6bc3a87d26d0bc0de61bad5d3d4a8cf1c487a4c8b8c6868f33d9bb625e
+MISC metadata.xml 2503 SHA256 e06bf2d547135e925f88a0cd75d8da59e58fadf842ef528de548832b54109aca SHA512 c56724344486f4e3ca63cd28ee19f5267a0aa66ce41b1b179e64499ebe86132523dfc2d35ed6caf606487fd01ebc812745faa47f62c0c3ea752d35d7cc86cf76 WHIRLPOOL 18d0a4a303d89272d89280dc5cf0f399e5d413f0d7f000f66ed85742c5ed8705a5655aa60a69e487ae3fcbb363d02696ab491f5bafe2e7bb069af732541419eb
+-----BEGIN PGP SIGNATURE-----
+Version: GnuPG v2.0.19 (GNU/Linux)
+
+iEYEAREIAAYFAlEZDtsACgkQVWmRsqeSphMMJQCfVl/Ts3tvwMhLu5x4IeOipRPQ
+BWAAn2dqmL/xR9HURhSA6L6rIGgOgpWx
+=mYS5
+-----END PGP SIGNATURE-----
diff --git a/net-analyzer/wireshark/metadata.xml b/net-analyzer/wireshark/metadata.xml
index 8ae8c80b8816..054c43372ca0 100644
--- a/net-analyzer/wireshark/metadata.xml
+++ b/net-analyzer/wireshark/metadata.xml
@@ -37,7 +37,6 @@
<flag name='adns'>Use the GNU <pkg>net-dns/c-ares</pkg> library to resolve DNS names</flag>
<flag name='crypt'>Use <pkg>dev-libs/libgcrypt</pkg> to decrypt traffic</flag>
<flag name='doc-pdf'>Build documentation in pdf format (US and a4 paper sizes)</flag>
-<flag name='gcrypt'>Use <pkg>dev-libs/libgcrypt</pkg> to decrypt IPsec traffic</flag>
<flag name='libadns'>Use <pkg>net-lib/adns</pkg> (DEPRECATED) instead of <pkg>net-dns/c-ares</pkg> to resolve DNS names</flag>
<flag name='pcap'>Use <pkg>net-libs/libpcap</pkg> for network packet capturing (build dumpcap, rawshark)</flag>
<flag name='smi'>Use <pkg>net-libs/libsmi</pkg> to resolve numeric OIDs into human readable format</flag>
diff --git a/net-analyzer/wireshark/wireshark-1.6.12.ebuild b/net-analyzer/wireshark/wireshark-1.6.12.ebuild
deleted file mode 100644
index b2b33489f89c..000000000000
--- a/net-analyzer/wireshark/wireshark-1.6.12.ebuild
+++ /dev/null
@@ -1,229 +0,0 @@
-# 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.12.ebuild,v 1.8 2013/01/30 03:40:50 jer Exp $
-
-EAPI=4
-PYTHON_DEPEND="python? 2"
-inherit autotools eutils 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"
-KEYWORDS="alpha amd64 hppa ia64 ppc ppc64 sparc x86 ~x86-fbsd"
-IUSE="
- adns doc doc-pdf gtk ipv6 libadns lua gcrypt geoip kerberos profile
- +pcap portaudio python +caps 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 )
- gcrypt? ( dev-libs/libgcrypt )
- pcap? ( net-libs/libpcap )
- caps? ( sys-libs/libcap )
- 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}
-
-# borrowed from GSoC2010_Gentoo_Capabilities by constanze and flameyeys
-# @FUNCTION: fcaps
-# @USAGE: fcaps {uid:gid} {file-mode} {cap1[,cap2,...]} {file}
-# @RETURN: 0 if all okay; non-zero if failure and fallback
-# @DESCRIPTION:
-# fcaps sets the specified capabilities in the effective and permitted set of
-# the given file. In case of failure fcaps sets the given file-mode.
-fcaps() {
- local uid_gid=$1
- local perms=$2
- local capset=$3
- local path=$4
- local res
-
- chmod $perms $path && \
- chown $uid_gid $path
- res=$?
-
- use caps || return $res
-
- #set the capability
- setcap "$capset=ep" "$path" &> /dev/null
- #check if the capabilitiy got set correctly
- setcap -v "$capset=ep" "$path" &> /dev/null
- res=$?
-
- if [ $res -ne 0 ]; then
- ewarn "Failed to set capabilities. Probable reason is missed kernel support."
- ewarn "Kernel must have <FS>_FS_SECURITY enabled where <FS> is the filesystem"
- ewarn "to store ${path} (e.g. EXT3_FS_SECURITY). For kernels version before"
- ewarn "2.6.33_rc1 SECURITY_FILE_CAPABILITIES must be enabled as well."
- ewarn
- ewarn "Falling back to suid now..."
- chmod u+s ${path}
- fi
- return $res
-}
-
-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
- # Add group for users allowed to sniff.
- enewgroup wireshark
-}
-
-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 !caps setuid-install) \
- $(use pcap && use_enable caps setcap-install) \
- $(use_enable gtk wireshark) \
- $(use_enable ipv6) \
- $(use_enable profile profile-build) \
- $(use_enable threads) \
- $(use_with caps libcap) \
- $(use_with 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() {
- if use caps && use pcap; then
- fcaps 0:wireshark 550 cap_dac_read_search,cap_net_raw,cap_net_admin "${EROOT}"/usr/bin/dumpcap
- fi
- echo
- 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."
- echo
-}
diff --git a/net-analyzer/wireshark/wireshark-1.8.4.ebuild b/net-analyzer/wireshark/wireshark-1.8.4.ebuild
deleted file mode 100644
index f489fd0d332e..000000000000
--- a/net-analyzer/wireshark/wireshark-1.8.4.ebuild
+++ /dev/null
@@ -1,241 +0,0 @@
-# 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.4.ebuild,v 1.8 2013/01/30 18:59:05 jer Exp $
-
-EAPI="4"
-PYTHON_DEPEND="python? 2"
-inherit autotools eutils 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"
-KEYWORDS="alpha amd64 ~arm hppa ia64 ppc ppc64 sparc x86 ~x86-fbsd"
-IUSE="
- adns +caps 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 )
- caps? ( sys-libs/libcap )
- 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}
-
-# borrowed from GSoC2010_Gentoo_Capabilities by constanze and flameyeys
-# @FUNCTION: fcaps
-# @USAGE: fcaps {uid:gid} {file-mode} {cap1[,cap2,...]} {file}
-# @RETURN: 0 if all okay; non-zero if failure and fallback
-# @DESCRIPTION:
-# fcaps sets the specified capabilities in the effective and permitted set of
-# the given file. In case of failure fcaps sets the given file-mode.
-fcaps() {
- local uid_gid=$1
- local perms=$2
- local capset=$3
- local path=$4
- local res
-
- chmod $perms $path && \
- chown $uid_gid $path
- res=$?
-
- use caps || return $res
-
- #set the capability
- setcap "$capset=ep" "$path" &> /dev/null
- #check if the capabilitiy got set correctly
- setcap -v "$capset=ep" "$path" &> /dev/null
- res=$?
-
- if [ $res -ne 0 ]; then
- ewarn "Failed to set capabilities. Probable reason is missed kernel support."
- ewarn "Kernel must have <FS>_FS_SECURITY enabled where <FS> is the filesystem"
- ewarn "to store ${path} (e.g. EXT3_FS_SECURITY). For kernels version before"
- ewarn "2.6.33_rc1 SECURITY_FILE_CAPABILITIES must be enabled as well."
- ewarn
- ewarn "Falling back to suid now..."
- chmod u+s ${path}
- fi
- return $res
-}
-
-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
- # Add group for users allowed to sniff.
- enewgroup wireshark
-}
-
-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 !caps setuid-install) \
- $(use pcap && use_enable caps setcap-install) \
- $(use_enable gtk wireshark) \
- $(use_enable ipv6) \
- $(use_enable profile profile-build) \
- $(use_with caps 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() {
- if use caps && use pcap; then
- fcaps 0:wireshark 550 cap_dac_read_search,cap_net_raw,cap_net_admin "${EROOT}"/usr/bin/dumpcap
- fi
- echo
- 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."
- echo
-}