APKBUILD 1.77 KB
Newer Older
1 2 3 4 5 6
# Contributor: Timo Teras <timo.teras@iki.fi>
# Maintainer: Timo Teras <timo.teras@iki.fi>

_flavor=grsec

# source the kernel version
7 8
if [ -f ../linux-${_flavor}/APKBUILD ]; then
	. ../linux-${_flavor}/APKBUILD
9 10
fi

11 12
_kernelver="$pkgver-r$pkgrel"
_abi_release=${pkgver}-${_flavor}
13 14 15 16
_realname=dahdi-linux

pkgname=${_realname}-${_flavor}
pkgver=2.2.0
17
pkgrel=4
18 19 20
pkgdesc="Digium Asterisk Hardware Device Interface drivers"
url="http://www.asterisk.org"
license="GPL"
21 22
#depends="dahdi-linux linux-${_flavor}=${_kernelver}"
depends="dahdi-linux linux-${_flavor}"
23 24
# we need wget and tar because make install downloads firmware and uses fancy
# options for tar and wget.
25
#makedepends="linux-${_flavor}-dev=${_kernelver} wget tar perl"
26 27
makedepends="linux-${_flavor}-dev wget tar perl"
install=
28
subpackages=
29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60
source="http://downloads.digium.com/pub/telephony/dahdi-linux/releases/${_realname}-$pkgver.tar.gz
	dahdi-depmod.patch
	dahdi-bri_dchan.patch
	dahdi-zaphfc.patch
	zaphfc-dahdi-flortz.diff
	dahdi-linux-2.2.0-hfc-4s.patch
	"

build() {
	cd "$srcdir/$_realname-$pkgver"
	for i in ../*.patch ../*.diff; do
		msg "Applying $i"
		patch -p1 < $i || return 1;
	done

	make KVERS="${_abi_release}" DYNFS="yes" MODULES_EXTRA="zaphfc" \
		|| return 1
	make KVERS="${_abi_release}" DYNFS="yes" MODULES_EXTRA="zaphfc" \
		DESTDIR="$pkgdir" install
}

# since we sourced the APKBUILD above we got the dev() function there to
# so we override it again.
dev() {
	default_dev
}
md5sums="a6b1a24a436e1c1fd08b99d27cfe3f38  dahdi-linux-2.2.0.tar.gz
c78fb8d80f9efdffd950297c88ff9273  dahdi-depmod.patch
4b41a82ff390ac64c08092c5a3eab6a8  dahdi-bri_dchan.patch
a822c092f0548cd13f5e8d8cba053af6  dahdi-zaphfc.patch
291c5c44c86ab02443a742415461ddca  zaphfc-dahdi-flortz.diff
68dfe17a49cca15ae439fd83f4ccfbc5  dahdi-linux-2.2.0-hfc-4s.patch"