aboutsummaryrefslogtreecommitdiffstats
path: root/main/pax-utils/APKBUILD
blob: 8a45e5f6a8415a7bfa86cafcd0c837e01851bcc8 (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
# Contributor: Sören Tempel <soeren+alpine@soeren-tempel.net>
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=pax-utils
pkgver=1.1.5
pkgrel=0
pkgdesc="ELF related utils for ELF 32/64 binaries"
url="https://wiki.gentoo.org/wiki/Hardened/PaX_Utilities"
arch="all"
license="GPL2"
depends="scanelf"
makedepends="linux-headers"
source="http://distfiles.gentoo.org/distfiles/${pkgname}-${pkgver}.tar.xz"
subpackages="$pkgname-doc scanelf:_scanelf"

_builddir="$srcdir"/$pkgname-$pkgver
prepare() {
	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 DESTDIR="$pkgdir/" install || return 1

	# Don't conflict with main/lddtree
	rm -f "$pkgdir"/usr/bin/lddtree
}

_scanelf() {
	pkgdesc="Scan ELF binaries for stuff"
	depends=
	replaces="pax-utils"
	mkdir -p "$subpkgdir"/usr/bin
	mv "$pkgdir"/usr/bin/scanelf "$subpkgdir"/usr/bin/
}

md5sums="bc3614322eaf88f167a608ae85d6b207  pax-utils-1.1.5.tar.xz"
sha256sums="2945b3e4df2e0dc95800bfbd3d88ab2243b2ee4ff064bbfc75734f6d9d986a89  pax-utils-1.1.5.tar.xz"
sha512sums="c03c2b867988592ad7ee3fc19cbbe203622a736889aa27a669824f4de670e8d591e1c8477529bd0481e7cdce11e94f8b55d4ef158fe21a6e2baf43b09f33b5b7  pax-utils-1.1.5.tar.xz"