aboutsummaryrefslogtreecommitdiffstats
path: root/main/strace/APKBUILD
blob: a552dec1f0a248f9262c87c445af78f237488e8e (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
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=strace
pkgver=5.10
pkgrel=0
pkgdesc="Diagnostic, debugging and instructional userspace tracer"
url="https://strace.io"
arch="all"
# disable checks for now, due to testsuite failure
options="!check"
license="BSD-3-Clause"
makedepends="linux-headers autoconf automake gawk"
subpackages="$pkgname-doc"
source="https://github.com/strace/strace/releases/download/v$pkgver/strace-$pkgver.tar.xz
	disable-fortify.patch
	nlattr-fix.patch
	"

prepare() {
	default_prepare

	# IPPROTO_MAX has been increased in musl, update the relvant headers
	# (Relies on fix-ipproto_max.patch)
	cd "$builddir/xlat"
	./gen.sh inet_protocols.in inet_protocols.h
}

build() {
	case "$CLIBC" in
	musl) export CFLAGS="$CFLAGS -Dsigcontext_struct=sigcontext" ;;
	esac

	./configure \
		--build=$CBUILD \
		--host=$CHOST \
		--prefix=/usr \
		--sysconfdir=/etc \
		--mandir=/usr/share/man \
		--localstatedir=/var \
		--enable-mpers=no
	make
}

check() {
	make check
}

package() {
	make -j1 DESTDIR="$pkgdir" install
}

sha512sums="1baa41b6d52f2e40e42a22850beee1ae278fafe712796694631898f06a7540d8f2c3fa70807e0062734f0976ebbd0824457c733ccda248f017c218387366ed48  strace-5.10.tar.xz
273b92ebf0069f19bef7ec26c7860e2af7ef01e782255c70ded1ae5e967f8f6bf031ecba96612c6083bf58f46278ba4ab3ec0fb35b08c8c8d668191f97adee52  disable-fortify.patch
44b1872cf996caa4970fa6c2875a3a2cffe4a38455e328d968bd7855ef9a05cf41190794dc137bc8667576635f5271057cf0e6cde9a6c7aee66afd1dba9bdba0  nlattr-fix.patch"