void-packages/srcpkgs/libretro-mupen64plus-rpi/template
2021-03-02 14:42:28 +01:00

36 lines
1.1 KiB
Bash

# Template file for 'libretro-mupen64plus-rpi'
pkgname=libretro-mupen64plus-rpi
version=20190611
revision=1
archs="armv6l* armv7l*"
_gitrev=e64ef9d9f214e32341fb7cd9633260fbb44b2326
wrksrc="mupen64plus-libretro-${_gitrev}"
hostmakedepends="pkg-config unzip"
makedepends="rpi-userland-devel zlib-devel"
short_desc="Libretro port of Mupen64 Plus"
maintainer="q66 <daniel@octaforge.org>"
license="GPL-3.0-or-later"
homepage="http://www.libretro.com/"
distfiles="https://github.com/libretro/mupen64plus-libretro/archive/${_gitrev}.tar.gz"
checksum=947abfb1d5ff34d6b22fecfb2df02bd3759fde3f4a0e5d238f65ec7e97d964d4
conflicts="ĺibretro-mupen64plus>=0"
CFLAGS="-fcommon"
do_build() {
local _args="ARCH=arm"
case "$XBPS_TARGET_MACHINE" in
armv6*) _args+=" platform=rpi";;
armv7*) _args+=" platform=rpi2";;
esac
install -d /opt/vc/lib
sed -i "s|-L/opt/vc/lib|-L${XBPS_CROSS_BASE}/opt/vc/lib -Wl,-R /opt/vc/lib|g" Makefile
sed -i 's|/opt/vc/include|${XBPS_CROSS_BASE}/opt/vc/include|g' Makefile
make CC=$CC ${_args} ${makejobs}
}
do_install() {
vinstall mupen64plus_libretro.so 755 usr/lib/libretro
}