# SliTaz package receipt.

PACKAGE="libcap-ng"
VERSION="0.8.2"
CATEGORY="security"
SHORT_DESC="New generation libcap library."
MAINTAINER="erjo@slitaz.org"
LICENSE="GPL2 LGPL2.1"
WEB_SITE="https://people.redhat.com/sgrubb/libcap-ng/"

TARBALL="$PACKAGE-$VERSION.tar.gz"
WGET_URL="${WEB_SITE}$TARBALL"

PROVIDE="libcap"
DEPENDS=""
BUILD_DEPENDS="autoconf automake coreutils libtool python"

# What is the latest version available today?
current_version()
{
	wget -O - ${WGET_URL%/*} 2>/dev/null | \
	sed "/latest/d;/$PACKAGE-/!d;/tar/!d;s|.*$PACKAGE-\\(.*\\).tar.*\".*|\\1|" | sort -Vr | sed q
}

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

# Rules to gen a SliTaz package suitable for Tazpkg.
genpkg_rules()
{
	cook_copy_folders	bin
	cook_copy_files		*.so*
}