aboutsummaryrefslogtreecommitdiffstats
path: root/main/strace/APKBUILD
blob: 160d04380754742c7536038de649779a26803e77 (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
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=strace
pkgver=4.10
pkgrel=0
pkgdesc="A useful diagnositic, instructional, and debugging tool"
url="http://sourceforge.net/projects/strace/"
arch="all"
license="BSD"
depends=
makedepends="linux-headers"
subpackages="$pkgname-doc"
source="http://downloads.sourceforge.net/sourceforge/$pkgname/$pkgname-$pkgver.tar.xz
	fix-includes.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="107a5be455493861189e9b57a3a51912  strace-4.10.tar.xz
574c38b9f5554b16af5ca94cf59e34e0  fix-includes.patch"
sha256sums="e6180d866ef9e76586b96e2ece2bfeeb3aa23f5cc88153f76e9caedd65e40ee2  strace-4.10.tar.xz
cfdff493a11b70369299e05f97a0efd0f096cf0ad7ea32619ac27a2ad3e53970  fix-includes.patch"
sha512sums="53d55b749224927cfcc9783db57eb8a057fc1329b2f5da2f54299dab17d530f5d1359480f03bea307fb72f6f372e50a0dbf0bd25d36a57a77632d9c1f690fc1d  strace-4.10.tar.xz
b084efed235fe781f997f5f2c1763fd45137340f4a8f832c44642946cfb7bcf1cabb7439f61aff4bdb91d0d0369e07bcad5c7e6fd27cd1110b90db8829f17d45  fix-includes.patch"