ioquake3-rpi: unbreak on musl and rpi2.

This commit is contained in:
Juan RP 2015-10-23 18:36:11 +02:00
parent f90bf0579e
commit 281c4d0d7b
2 changed files with 12 additions and 7 deletions

View File

@ -19,7 +19,7 @@
# prefix of arm cross compiler installed
-CROSS_COMPILE=bcm2708-
+CROSS_COMPILE=arm-linux-gnueabihf-
+CROSS_COMPILE=@XBPS_CROSS_TRIPLET@
# clean
if [ $# -ge 1 ] && [ $1 = clean ]; then

View File

@ -7,23 +7,28 @@ maintainer="Juan RP <xtraeme@voidlinux.eu>"
license="GPL-2"
homepage="http://ioquake3.org/"
distfiles="http://ftp.gwdg.de/pub/misc/ftp.idsoftware.com/idstuff/quake3/linux/linuxq3apoint-1.32b-3.x86.run"
skip_extraction="linuxq3apoint-1.32b-3.x86.run"
checksum=c36132c5556b35e01950f1e9c646235033a5130f87ad776ba2bc7becf4f4f186
# XXX only for rpi
only_for_archs="armv6l"
hostmakedepends="which pkg-config git"
makedepends="SDL-devel rpi-firmware"
create_wrksrc=yes
only_for_archs="armv6l armv6l-musl armv7l armv7l-musl"
hostmakedepends="pkg-config git"
makedepends="SDL-devel rpi-userland-devel"
do_configure() {
# Fetch ioquake3 for rpi
git clone git://github.com/raspberrypi/quake3.git $pkgname --depth=1
cd $pkgname
patch build.sh < ${FILESDIR}/ioquake3-build.sh.patch
sed -e "s,/opt/vc,$XBPS_CROSS_BASE/opt/vc,g" -i build.sh
patch < ${FILESDIR}/ioquake3-build.sh.patch
sed -e "s,@XBPS_CROSS_TRIPLET@,${XBPS_CROSS_TRIPLET}-,g" \
-e "s,/opt/vc,${XBPS_CROSS_BASE}/opt/vc,g" \
-e "s,SDL_LIB=.*,SDL_LIB=${XBPS_CROSS_BASE}/usr/lib,g" \
-i build.sh
# Extract Patch Files
cp $XBPS_SRCDISTDIR/linuxq3apoint-1.32b-3.x86.run .
cp $XBPS_SRCDISTDIR/${pkgname}-${version}/linuxq3apoint-1.32b-3.x86.run .
chmod +x linuxq3apoint-1.32b-3.x86.run
./linuxq3apoint-1.32b-3.x86.run --tar xf