diff options
Diffstat (limited to 'testing/net-tools/APKBUILD')
-rw-r--r-- | testing/net-tools/APKBUILD | 91 |
1 files changed, 91 insertions, 0 deletions
diff --git a/testing/net-tools/APKBUILD b/testing/net-tools/APKBUILD new file mode 100644 index 000000000..8779357dd --- /dev/null +++ b/testing/net-tools/APKBUILD @@ -0,0 +1,91 @@ +# Maintainer: Natanael Copa <ncopa@alpinelinux.org> +pkgname=net-tools +pkgver=1.60_git20130615 +_ver=${pkgver%_git*} +pkgrel=0 +pkgdesc="Linux networking base tools" +url="https://sourceforge.net/projects/net-tools/" +arch="all" +license="GPLv2" +depends="mii-tool" +depends_dev="" +makedepends="$depends_dev bash" +install="" +subpackages="$pkgname-doc mii-tool:mii_tool" +source="https://downloads.sourceforge.net/project/net-tools/net-tools-$_ver.tar.bz2 + git.patch" + +_builddir="$srcdir"/net-tools-$_ver +prepare() { + local i + cd "$_builddir" + for i in $source; do + case $i in + *.patch) msg $i; patch -p1 -i "$srcdir"/$i || return 1;; + esac + done + cat > config.make <<EOF +# I18N=0 +HAVE_AFUNIX=1 +HAVE_AFINET=1 +HAVE_AFINET6=1 +# HAVE_AFIPX=0 +# HAVE_AFATALK=0 +# HAVE_AFAX25=0 +HAVE_AFNETROM=1 +# HAVE_AFROSE=0 +# HAVE_AFX25=0 +# HAVE_AFECONET=0 +# HAVE_AFDECnet=0 +# HAVE_AFASH=0 +# HAVE_AFBLUETOOTH=0 +HAVE_HWETHER=1 +# HAVE_HWARC=0 +HAVE_HWSLIP=1 +HAVE_HWPPP=1 +HAVE_HWTUNNEL=1 +# HAVE_HWSTRIP=0 +# HAVE_HWTR=0 +# HAVE_HWAX25=0 +# HAVE_HWROSE=0 +HAVE_HWNETROM=1 +# HAVE_HWX25=0 +# HAVE_HWFR=0 +# HAVE_HWSIT=0 +# HAVE_HWFDDI=0 +# HAVE_HWHIPPI=0 +# HAVE_HWASH=0 +# HAVE_HWHDLCLAPB=0 +# HAVE_HWIRDA=0 +# HAVE_HWEC=0 +# HAVE_HWEUI64=0 +# HAVE_HWIB=0 +HAVE_FW_MASQUERADE=1 +HAVE_IP_TOOLS=1 +HAVE_MII=1 +EOF + sed -n -e 's/^\(HAVE.*\)=\(.*\)/#define \1 \2/p' config.make > config.h +} + +build() { + cd "$_builddir" + make || return 1 +} + +package() { + cd "$_builddir" + make DESTDIR="$pkgdir" install || return 1 +} + +mii_tool() { + pkgdesc="media-independent interface (MII) tool" + mkdir -p "$subpkgdir"/sbin + mv "$pkgdir"/sbin/mii-tool "$subpkgdir"/sbin/ +} + +md5sums="888774accab40217dde927e21979c165 net-tools-1.60.tar.bz2 +6c2b55f5258d23477fa0d9261bd363a5 git.patch" +sha256sums="7ae4dd6d44d6715f18e10559ffd270511b6e55a8900ca54fbebafe0ae6cf7d7b net-tools-1.60.tar.bz2 +3d27ff819c909c97c515837971f4cdb76744e0a20adefd563b1840cbeafcf789 git.patch" +sha512sums="8e1ae9bca726ad7d795a06c58388f9e11c1d617d94eebb9ed18bd11e5f34c6541e1ffe631706c407996db86e78df6e5cf1968a2d90b242b473596fda3b6d1eae net-tools-1.60.tar.bz2 +95865c5be07585cc9994a1142a6585f482fdcc8f56a59fb87e71e8e947471af5ac42e99c6bccfa34dbc378449c9fcaad315815636879800950c97a6889e69d4a git.patch" |