diff --git a/srcpkgs/ioquake3-rpi/files/ioquake3-build.sh.patch b/srcpkgs/ioquake3-rpi/files/ioquake3-build.sh.patch index b9f53649506..d8ce580270c 100644 --- a/srcpkgs/ioquake3-rpi/files/ioquake3-build.sh.patch +++ b/srcpkgs/ioquake3-rpi/files/ioquake3-build.sh.patch @@ -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 diff --git a/srcpkgs/ioquake3-rpi/template b/srcpkgs/ioquake3-rpi/template index db3e2269f0a..b0923399ffd 100644 --- a/srcpkgs/ioquake3-rpi/template +++ b/srcpkgs/ioquake3-rpi/template @@ -7,23 +7,28 @@ maintainer="Juan RP " 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