aboutsummaryrefslogtreecommitdiffstats
path: root/main/linux-headers/APKBUILD
blob: b3e42e8fab60943375a2cff8e8f575f57664e841 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
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
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=linux-headers
pkgver=3.8.7
_kernver=3.8
pkgrel=1
pkgdesc="Linux system headers"
url="http://kernel.org"
arch="all"
license='GPL-2'
makedepends="perl"
if [ "$ALPINE_LIBC" = "eglibc" ]; then
        replaces="eglibc-dev"
else
        replaces="uclibc-dev"
fi
options="!strip !tracedeps"
source="ftp://ftp.kernel.org/pub/linux/kernel/v3.x/linux-$_kernver.tar.bz2
	ftp://ftp.kernel.org/pub/linux/kernel/v3.x/patch-$pkgver.bz2
	"

prepare() {
	cd "$srcdir"/linux-$_kernver
	if [ "$_kernver" != "$pkgver" ]; then
		bunzip2 -c < "$srcdir"/patch-$pkgver.bz2 | patch -p1 || return 1
	fi
}

build() {
	return 0
}

package() {
	local _carch=$CARCH

	case "$_carch" in
	arm*) _carch="arm" ;;
	esac

	cd "$srcdir"/linux-$_kernver
	mkdir -p "$pkgdir/usr"
	make headers_install ARCH="${_carch}" INSTALL_HDR_PATH="$pkgdir/usr" || return 1

	find "$pkgdir/usr" \( -name .install -o -name ..install.cmd \) -exec \
		rm -f {} \;

	# provided by libdrm
	rm -rf "$pkgdir"/usr/include/drm
}

md5sums="fcd1d2e60e1033c935a13ef81c89ea2d  linux-3.8.tar.bz2
411bfdadfb9b5ae82580d574416d3235  patch-3.8.7.bz2"
sha256sums="fce774b5313e73949cb35f128e91e7b2ccd7fa2438abc5cff69267e504395a45  linux-3.8.tar.bz2
bff6ec3f5726d34614cc6ff7bfb28c88195d047cf6a87cb2fdfe1da205007e45  patch-3.8.7.bz2"
sha512sums="966a3b08aecc4b135a48ea73ba3326e1710c455e6da29693479e9d1a56663fc10f569e2342fa861486d39d4ea5c2af406d1bd40613c15555acffdba160ef7ba9  linux-3.8.tar.bz2
431873c446089220d17bc98685066f7ea95c8dd1125b6d19063c293e7e7816cbfc320cfcc802b50e76d99a93ebbe03157660d5ed27a95c18ecb46d324bbf9e4d  patch-3.8.7.bz2"