# SliTaz package receipt.

PACKAGE="arping"
VERSION="2.20"
CATEGORY="network"
SHORT_DESC="ARP ping utility."
MAINTAINER="slaxemulator@gmail.com"
LICENSE="GPL2"
WEB_SITE="https://github.com/ThomasHabets/arping"

TARBALL="$PACKAGE-$VERSION.tar.gz"
WGET_URL="$WEB_SITE/archive/$TARBALL"

DEPENDS="libcap libnet libpcap"
BUILD_DEPENDS="autoconf automake libcap-dev libnet-dev libpcap-dev"

current_version()
{
	wget -O - ${WGET_URL%/arch*}/tags 2>/dev/null | \
	sed '/archive.*tar/!d;s|.*/arping-\(.*\).tar.*|\1|;q'
}

# Rules to configure and make the package.
compile_rules()
{
	./bootstrap.sh &&
	./configure $CONFIGURE_ARGS &&
	make &&
	make DESTDIR=$DESTDIR install
}

# Rules to gen a SliTaz package suitable for Tazpkg.
genpkg_rules()
{
	mkdir -p $fs/usr
	cp -a $install/usr/sbin	$fs/usr
}