void-packages/srcpkgs/mtr/template

53 lines
1.2 KiB
Bash

# Template file for 'mtr'
pkgname=mtr
version=0.95
revision=1
build_style="gnu-configure"
hostmakedepends="automake pkg-config gtk+3-devel"
makedepends="ncurses-devel gtk+3-devel libcap-devel"
depends="libcap-progs"
short_desc="Combines the functionality of traceroute and ping into one tool"
maintainer="Steven R <dev@styez.com>"
license="GPL-2.0-only"
homepage="http://www.bitwizard.nl/mtr/"
distfiles="https://github.com/traviscross/mtr/archive/v${version}.tar.gz"
checksum=12490fb660ba5fb34df8c06a0f62b4f9cbd11a584fc3f6eceda0a99124e8596f
pre_configure() {
echo $version >.tarball-version
./bootstrap.sh
}
do_configure() {
mkdir $wrksrc/build_nox $wrksrc/build_x11
cd $wrksrc/build_nox
$wrksrc/configure ${configure_args} --without-gtk
cd $wrksrc/build_x11
$wrksrc/configure ${configure_args}
}
do_build() {
for p in $wrksrc/build_nox $wrksrc/build_x11; do
cd $p
make ${makejobs}
done
}
do_install() {
cd $wrksrc/build_nox
make DESTDIR=$DESTDIR install
chmod 0755 $DESTDIR/usr/bin/*
}
mtr-x11_package() {
provides="mtr-${version}_${revision}"
replaces="mtr>0"
short_desc+=" - X11 version"
pkg_install() {
cd $wrksrc/build_x11
make DESTDIR=$PKGDESTDIR install
chmod 0755 $PKGDESTDIR/usr/bin/*
}
}