# Template file for 'dosbox-staging'
pkgname=dosbox-staging
version=0.82.0
revision=1
build_style=meson
build_helper=qemu
hostmakedepends="pkg-config"
makedepends="SDL2-devel SDL2_net-devel alsa-lib-devel fluidsynth-devel
 libiir1-devel libmt32emu-devel libpng-devel libslirp-devel opusfile-devel
 speexdsp-devel zlib-devel"
checkdepends="gtest-devel"
short_desc="DOS/x86 emulator focusing on ease of use"
maintainer="Joshua Krämer <joshua@kraemer.link>"
license="GPL-2.0-or-later"
homepage="https://dosbox-staging.github.io"
distfiles="https://github.com/dosbox-staging/dosbox-staging/archive/v${version}.tar.gz"
checksum=a3f63f86bf203ba28512e189ce6736cdb0273647e77a62ce47ed3d01b3b4a88d
conflicts="dosbox"

# ARMv6/v7: LTO leads to strange errors "Error: invalid literal constant: pool needs to be closer"

case "$XBPS_TARGET_MACHINE" in
	arm*) configure_args+=" -Db_lto=false"
esac
