# Contributor: William Pitcock <nenolod@dereferenced.org>
# Maintainer: William Pitcock <nenolod@dereferenced.org>
pkgname=ifupdown
pkgver=0.7.53.1
pkgrel=1
pkgdesc="high level tools to configure network interfaces"
url="http://packages.debian.org/ifupdown"
arch="all"
license="GPL"
depends=
depends_dev=
makedepends="perl"
install=""
subpackages=
source="http://ftp.de.debian.org/debian/pool/main/i/$pkgname/${pkgname}_$pkgver.tar.xz
	ifupdown-busybox-compat.patch
	ifupdown-alpine-ifstate.patch
	ifupdown-cflags-version.patch
	ifupdown-no-dpkg.patch"

_builddir="$srcdir/$pkgname"

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
}

build() {
	cd "$_builddir"
	make || return 1
}

package() {
	cd "$_builddir"
	make BASEDIR="$pkgdir" install || return 1
}

md5sums="b36eab51a079e927b444a033bc608c65  ifupdown_0.7.53.1.tar.xz
c16541064bfb1d5e520acf41b6e990c9  ifupdown-busybox-compat.patch
dc9f46ad2bfffebffa41b74520ddb103  ifupdown-alpine-ifstate.patch
4332f9a584fbb762ab48edc6f3a953c5  ifupdown-cflags-version.patch
74a96adf311db2acfc52110f85a510cd  ifupdown-no-dpkg.patch"
sha256sums="a97981b52d5758da42a8a2a3885a11d6e5f97eaf1a1b3c5fe36195e638ae6c03  ifupdown_0.7.53.1.tar.xz
b7423069317d87de8aa743d3203bbd537aab2a1b5a33c9c71c7d9de259bedfdf  ifupdown-busybox-compat.patch
0b8e64b1a9dcf7bdbd6434289a51f142b1ab702fe5d97ffd4a9d4d793293d7b0  ifupdown-alpine-ifstate.patch
defdfa65fd774af133d344a80ce5224e2412f513b10b54946ae2fdba2f1d8ea3  ifupdown-cflags-version.patch
912d37c13ee1e06e24b7208819dd419451fd42b0091c4c4d9236eec6ccd248c8  ifupdown-no-dpkg.patch"
sha512sums="e54061474616bca5f2cb1aaeddb82bc4ee0ff72391098dc465554b213c88f2c18de1872e0d8cfe574b7ab15728d6f233a6cf5ee1952d1830dfa9a655ebe35086  ifupdown_0.7.53.1.tar.xz
2dc92ba007cac0bc5bc0c82d6283a772b4b20330e1569a6e889fa02a17debd08e3063cafbd7e6c447b38f8d93597d953dbf2d236c67415cfac24d0accaa3b881  ifupdown-busybox-compat.patch
422998dae8d0ac6049064c93c22baea143eefa7cab9a330b41ec6e317294da4976c193a7a252a8b4a3a47b93ebb01ef308f5a3803838d6452fc283a159ad1e89  ifupdown-alpine-ifstate.patch
ffe843f52b894b80dde4401bc71434f9d78d3498c501e3bc46c9737628283cb518834ed972d4381521535ce6de45dd606d3940420d21308c87602ec828e9c3ba  ifupdown-cflags-version.patch
dfda752c68fd71d016f770753fa7142179dcb2c6f92cc78a9efa8135897e8186c549062bb1631c50c6087725e796c62e900d3f3a91e52d8c436be64a18efbfba  ifupdown-no-dpkg.patch"
