diff --git a/srcpkgs/xonotic/template b/srcpkgs/xonotic/template index 59a739eab3..6d3a2997e2 100644 --- a/srcpkgs/xonotic/template +++ b/srcpkgs/xonotic/template @@ -1,7 +1,7 @@ # Template file for 'xonotic' pkgname=xonotic version=0.8.1 -revision=2 +revision=3 wrksrc="Xonotic" homepage="http://xonotic.org" license="GPL-2, GPL-3" @@ -17,17 +17,24 @@ makedepends="gmp-devel MesaLib-devel SDL2-devel libcurl-devel alsa-lib-devel depends="desktop-file-utils xonotic-data" do_build() { + local target + make_build_args="SDL_CONFIG=sdl2-config DP_FS_BASEDIR=/usr/share/xonotic/ DP_LINK_TO_LIBJPEG=1" case "$XBPS_TARGET_MACHINE" in i686*|x86_64*) ;; *) make_build_args+=" CFLAGS_SSE= CFLAGS_SSE2=";; esac echo $make_build_args - make ${makejobs} -C source/darkplaces CPUOPTIMIZATIONS="${CFLAGS}" $make_build_args cl-release - make ${makejobs} -C source/darkplaces CPUOPTIMIZATIONS="${CFLAGS}" $make_build_args sdl-release - make ${makejobs} -C source/darkplaces CPUOPTIMIZATIONS="${CFLAGS}" $make_build_args sv-release + cd source/darkplaces + # Inject our $CFLAGS and $LDFLAGS + sed -i makefile.inc \ + -e "s;^\(CPUOPTIMIZATIONS\)?=\(.*\);\1=${CFLAGS} \2;" \ + -e "s;^\(LDFLAGS_UNIXCOMMON\)=\(.*\);\1=${LDFLAGS} \2;" + for target in cl sdl sv; do + make ${makejobs} ${make_build_args} ${target}-release + done - cd source/d0_blind_id + cd ${wrksrc}/source/d0_blind_id autoreconf -fi ./configure --prefix=/usr --disable-rijndael make ${makejobs}