
Untitled
By: a guest on
Jul 3rd, 2011 | syntax:
Bash | size: 1.73 KB | views:
199 | expires: Never
#Maintainer Michael P <ptchinster@archlinux.us>
pkgname=wireshark-svn
pkgver=37878
pkgrel=1
pkgdesc="A free network protocol analyzer for Unix/Linux. SVN version"
arch=('i686' 'x86_64')
license=('GPL2')
depends=('gtk2' 'heimdal' 'libpcap' 'gnutls' 'c-ares' 'e2fsprogs' 'lua' 'portaudio' 'geoip' 'libsmi' 'perl-parse-yapp' 'python2')
makedepends=('subversion')
url="http://www.wireshark.org/"
md5sums=('504ede44c02b2a52f6cbd3bffdf93b8d'
'e771800a8c977fe223583a453bc27397')
replaces=('ethereal')
provides=('wireshark')
source=("wireshark.desktop"
"wireshark.png")
conflicts=('wireshark-gtk')
_svnmod="wireshark"
_svntrunk="http://anonsvn.wireshark.org/wireshark/trunk/"
build() {
cd ${srcdir}
if [ -d $_svnmod/.svn ]; then
(cd $_svnmod && svn up -r $pkgver)
else
svn co $_svntrunk --config-dir ./ -r $pkgver $_svnmod
fi
msg "SVN checkout done or server timeout"
msg "Starting make..."
if [[ -d $_svnmod-build ]] ; then
rm -rf $_svnmod-build
fi
mkdir $_svnmod-build
cd ./$_svnmod-build
export CFLAGS="-Wno-error=old-style-definition -Wno-error=clobbered -Wno-error=unused-but-set-variable -fno-unit-at-a-time ${CFLAGS}"
#find . -type f -exec sed -i 's|#!/usr/bin/env python|#!/usr/bin/env python2|' {} \;
#sed -i 's/python /python2 /' autogen.sh
#./autogen.sh
#./configure --prefix=/usr --with-ssl --enable-airpcap PYTHON=/usr/bin/python2 || return 1
cmake -DCMAKE_INSTALL_PREFIX=/usr ../$_svnmod
make -j2 PYTHON=/usr/bin/python2 || return 1
make -j2 DESTDIR=${pkgdir} install || return 1
install -Dm644 ${srcdir}/wireshark.png ${pkgdir}/usr/share/icons/wireshark.png
install -Dm644 ${srcdir}/wireshark.desktop ${pkgdir}/usr/share/applications/wireshark.desktop
}