void-packages/srcpkgs/proot/template
jbu 2bda6cac40 proot: unbreak musl
This makes proot build on musl, but requires testing to make
sure the resulting binary works as expected.
2015-07-12 13:48:44 +02:00

31 lines
951 B
Bash

# Template file for 'proot'
pkgname=proot
version=5.1.0
revision=2
wrksrc="PRoot-${version}"
makedepends="libarchive-devel talloc-devel"
short_desc="User-space implementation of chroot, mount --bind, and binfmt_misc"
maintainer="Juan RP <xtraeme@voidlinux.eu>"
license="GPL-2"
homepage="http://proot.me"
distfiles="https://github.com/cedric-vincent/PRoot/archive/v${version}.tar.gz"
checksum=50fcb882662b2de3e64e603b68d1af75e920d480191a49e11c0cb63d50040386
pre_build() {
sed -i "s,strip,:,g" src/GNUmakefile
sed -i "s,objcopy,${OBJCOPY},g" src/GNUmakefile
sed -i "s,objdump,${OBJDUMP},g" src/GNUmakefile
sed -i "s,--input ,--input-target ,g" src/GNUmakefile
sed -i "s,--output ,--output-target ,g" src/GNUmakefile
# Fix glibc ptrace.h specific constants for musl libc
cp ${FILESDIR}/ptrace_compat.h ${wrksrc}/src
}
do_build() {
cd src
make CC=$CC CFLAGS="$CFLAGS" ${makejobs}
}
do_install() {
vbin src/proot
vman doc/proot/man.1 proot.1
}