aboutsummaryrefslogtreecommitdiffstats
path: root/main/strace/APKBUILD
blob: 1000b12be219f98cbc6f8e244f6708d6fc47259d (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=strace
pkgver=4.8
pkgrel=4
pkgdesc="A useful diagnositic, instructional, and debugging tool"
url="http://sourceforge.net/projects/strace/"
arch="all"
license="BSD"
depends=
makedepends=
subpackages="$pkgname-doc"
source="http://downloads.sourceforge.net/sourceforge/$pkgname/$pkgname-$pkgver.tar.xz
	strace-musl.patch
	uclibc-fix.patch
	"

_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
	sed -i -e 's/include <linux\/socket.h>/include <sys\/socket.h>/g' \
		configure
}

build() {
	cd "$_builddir"
	case "$CLIBC" in
	musl) export CFLAGS="$CFLAGS -Dsigcontext_struct=sigcontext" ;;
	esac
	 ac_cv_have_long_long_off_t=yes \
	./configure \
		--build=$CBUILD \
		--host=$CHOST \
		--prefix=/usr \
		|| return 1
	make || return 1
}

package() {
	cd "$srcdir/$pkgname-$pkgver"
	make -j1 DESTDIR="$pkgdir" install
}
md5sums="c575ef43829586801f514fd91bfe7575  strace-4.8.tar.xz
4dca5e173da85798ad4d628774db6053  strace-musl.patch
4906d85aaf996831cca1dcbd13f3f5b5  uclibc-fix.patch"
sha256sums="f492291f07a7c805c07a8395cce1ea054a6401ad414f4cc12185672215e1d7f8  strace-4.8.tar.xz
47875682d64258806b76202c9d05f9b0547a93dca52bfb4d1fb62cd3993771cd  strace-musl.patch
b089fc949aab33d791acb5939ef64cc74726fa0e599300be4fcb41ca005be78f  uclibc-fix.patch"
sha512sums="c3316382f60cd4d02eec1eef46a0ef2d000afbccf2c176a6fec652e1b3391685f0e33f184497cb3ccf54d72d460471a4945d3a864fb5bce1f45f32fdf132cfe3  strace-4.8.tar.xz
79cf73c292afe8ed6a78792f32a763bb39ba643f3696f0931867a6e93fb0f32ee1833e872c54bf5509c50dc382999202de677f37242356952df5dee367b0cc50  strace-musl.patch
672b5b240bd79ca0b7145cda33e29d9aea4067ff78eae993062381010868a5e31d2d58fc3329dfa5dbe76f029a057710489d50ba6a104adc727f287704622125  uclibc-fix.patch"