# Template file for 'mupen64plus'
pkgname=mupen64plus
version=2.6.0
revision=1
archs="x86_64* i686*"
hostmakedepends="pkg-config which nasm"
makedepends="SDL2-devel speexdsp-devel freetype-devel glu-devel
 libpng-devel libsamplerate-devel"
depends="desktop-file-utils"
short_desc="Nintendo64 Emulator"
maintainer="Orphaned <orphan@voidlinux.org>"
license="GPL-2.0-only"
homepage="http://www.mupen64plus.org"
distfiles="https://github.com/mupen64plus/mupen64plus-core/releases/download/${version}/${pkgname}-bundle-src-${version}.tar.gz"
checksum=297e17180cd76a7b8ea809d1a1be2c98ed5c7352dc716965a80deb598b21e131
nopie=yes
nocross=yes

CFLAGS="-fcommon"

do_build() {
	sh m64p_build.sh
}
do_install() {
	 ./m64p_install.sh DESTDIR=${DESTDIR} PREFIX=/usr MANDIR=/usr/share/man
	# Remove devel files, not interested on it.
	rm -rf ${DESTDIR}/usr/include
}
