From a46ac5ad3f39a7e982535f50ab459abf4d332ac0 Mon Sep 17 00:00:00 2001 From: Solitude Date: Thu, 12 Jul 2018 23:41:07 +0300 Subject: [PATCH] yquake2: update template (#619) --- srcpkgs/yquake2/template | 21 ++++++++++++++------- 1 file changed, 14 insertions(+), 7 deletions(-) diff --git a/srcpkgs/yquake2/template b/srcpkgs/yquake2/template index 81019f67c6..a0c863d355 100644 --- a/srcpkgs/yquake2/template +++ b/srcpkgs/yquake2/template @@ -2,25 +2,32 @@ pkgname=yquake2 version=7.20 revision=1 -only_for_archs="i686 i686-musl x86_64 x86_64-musl" wrksrc="quake2-${version}" +build_style=gnu-makefile +make_build_args="WITH_SYSTEMWIDE=yes WITH_SYSTEMDIR=/usr/lib/${pkgname}" +make_use_env=yes hostmakedepends="pkg-config" makedepends="SDL2-devel libjpeg-turbo-devel libopenal-devel zlib-devel" depends="desktop-file-utils hicolor-icon-theme" short_desc="An enhanced client for id Software's Quake II (Yamagi Quake II)" maintainer="Juan RP " license="GPL-2.0-or-later" -homepage="http://www.yamagi.org/quake2/" -distfiles="http://deponie.yamagi.org/quake2/quake2-${version}.tar.xz" +homepage="https://www.yamagi.org/quake2/" +distfiles="https://deponie.yamagi.org/quake2/quake2-${version}.tar.xz" checksum=64136239ba08747ddfe7c18c17f87a9cd3730cd4a867b6e438eee9f34415a0ad -do_build() { - make ${makejobs} WITH_SYSTEMWIDE=yes WITH_SYSTEMDIR=/usr/lib/${pkgname} +case "$XBPS_TARGET_MACHINE" in + armv*) makedepends+=" MesaLib-devel";; +esac + +pre_build() { + case "$XBPS_TARGET_MACHINE" in + armv*|aarch*) sed -i -r 's/\$.+arm.+/arm/' Makefile;; + esac } do_install() { - vmkdir usr/lib/${pkgname} - vcopy release/quake2 usr/lib/${pkgname}/${pkgname} + vinstall release/quake2 755 usr/lib/${pkgname} ${pkgname} vmkdir usr/bin ln -sf /usr/lib/${pkgname}/${pkgname} ${DESTDIR}/usr/bin vbin release/q2ded ${pkgname}-q2ded