aboutsummaryrefslogtreecommitdiffstats
path: root/main/linux-headers/APKBUILD
blob: 51ef4d6bb415ca9b89ca02d3f4f530250168e322 (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
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=linux-headers
pkgver=3.10.17
_kernver=${pkgver#.*}
pkgrel=0
pkgdesc="Linux system headers"
url="http://kernel.org"
arch="all"
license='GPL-2'
makedepends="perl"
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="d4cdc01af11b9a49f34c406dde7ee430  linux-3.10.17.tar.bz2
55c43e99217870feb52662ce7bcc94e9  patch-3.10.17.bz2"
sha256sums="fcff3fd2132a1a6d6b797a8440eb1b98f558e57360630af4ecfbb85284f257d1  linux-3.10.17.tar.bz2
3fe1117caa15e4febde7c74d8e9e58e33131bf2602d19b735684be301093cc09  patch-3.10.17.bz2"
sha512sums="0fb14f6aa6442f6f0fcbf105d578b946eb26d1f387e4077a536eb185d42092e6d4173c8a02af8bc26327defb2712d7087614d1628270a3142d41692d25ec41d8  linux-3.10.17.tar.bz2
241311860d9f79ae335395acf5479c89a1d1933eb4c980cf6e623a65f6d9176d2d0aed395eb5ed77c9fba0fba3aeef8d836b3c5bdfa98d1943cdc5deeab15a49  patch-3.10.17.bz2"