void-packages/srcpkgs/Cataclysm-DDA/template

74 lines
1.7 KiB
Bash

# Template file for 'Cataclysm-DDA'
pkgname=Cataclysm-DDA
version=0.E
revision=1
build_style=cmake
configure_args="-DRELEASE=1 $(vopt_bool backtrace BACKTRACE) -DUSE_HOME_DIR=1 -DPREFIX=/usr"
hostmakedepends="gettext pkg-config"
makedepends="$(vopt_if tiles 'SDL2_image-devel SDL2_mixer-devel SDL2_ttf-devel freetype-devel')
ncurses-devel"
depends="Cataclysm-DDA-data>=${version}_${revision}"
short_desc="Turn-based survival game set in a post-apocalyptic world"
maintainer="John <me@johnnynator.dev>"
license="CC-BY-SA-3.0, CC-BY-3.0"
homepage="https://cataclysmdda.org/"
distfiles="https://github.com/CleverRaven/Cataclysm-DDA/archive/${version}.tar.gz"
checksum=b0af9a9292929e17332edcea770bca9a91f1d08ea47726d78a47e09281a42fa3
build_options="tiles backtrace"
build_options_default="tiles"
case $XBPS_TARGET_MACHINE in
*-musl);;
*) build_options_default+=" backtrace";;
esac
if [ "$build_option_tiles" ]; then
subpackages="Cataclysm-DDA-tiles-data Cataclysm-DDA-tiles"
post_configure() {
local cmake_builddir=build-tiles
configure_args+=" -DTILES=ON -DSOUND=ON"
do_configure
}
post_build() {
local cmake_builddir=build-tiles
do_build
}
post_install() {
local cmake_builddir=build-tiles
do_install
}
fi
subpackages+=" Cataclysm-DDA-data"
do_check() {
: #needs tap++.h
}
Cataclysm-DDA-tiles_package() {
short_desc+=" - SDL tiles version"
depends="Cataclysm-DDA-data Cataclysm-DDA-tiles-data"
pkg_install() {
vmove usr/bin/cataclysm-tiles
}
}
Cataclysm-DDA-tiles-data_package() {
short_desc+=" - tiles data files"
archs=noarch
pkg_install() {
vmove usr/share/cataclysm-dda/gfx
vmove usr/share/cataclysm-dda/sound
}
}
Cataclysm-DDA-data_package() {
short_desc+=" - data files"
archs=noarch
pkg_install() {
vmove usr/share
}
}