diff --git a/srcpkgs/pioneer/files/pioneer.desktop b/srcpkgs/pioneer/files/pioneer.desktop new file mode 100644 index 00000000000..5f3f9f50d9e --- /dev/null +++ b/srcpkgs/pioneer/files/pioneer.desktop @@ -0,0 +1,10 @@ +[Desktop Entry] +Name=Pioneer +Comment=Space adventure game set in our galaxy at the turn of the 31st century. +Path=/usr/share/pioneer/ +Exec=pioneer +Icon=pioneer +Terminal=false +Type=Application +Categories=Game;StrategyGame; + diff --git a/srcpkgs/pioneer/patches/musl.patch b/srcpkgs/pioneer/patches/musl.patch new file mode 100644 index 00000000000..41c63784223 --- /dev/null +++ b/srcpkgs/pioneer/patches/musl.patch @@ -0,0 +1,20 @@ +--- src/posix/OSPosix.cpp.orig 2017-08-19 20:00:23.645790781 +0200 ++++ src/posix/OSPosix.cpp 2017-08-19 20:00:44.153855997 +0200 +@@ -48,7 +48,7 @@ + + void EnableFPE() + { +-#if defined(_GNU_SOURCE) && !defined(__APPLE__) ++#if defined(_GNU_SOURCE) && !defined(__APPLE__) && defined(__GLIBC__) + // clear any outstanding exceptions before enabling, otherwise they'll + // trip immediately + feclearexcept(FE_DIVBYZERO | FE_INVALID | FE_OVERFLOW); +@@ -58,7 +58,7 @@ + + void DisableFPE() + { +-#if defined(_GNU_SOURCE) && !defined(__APPLE__) ++#if defined(_GNU_SOURCE) && !defined(__APPLE__) && defined(__GLIBC__) + fedisableexcept(FE_DIVBYZERO | FE_INVALID | FE_OVERFLOW); + #endif + } diff --git a/srcpkgs/pioneer/template b/srcpkgs/pioneer/template new file mode 100644 index 00000000000..73bceadae43 --- /dev/null +++ b/srcpkgs/pioneer/template @@ -0,0 +1,34 @@ +# Template file for 'pioneer' +pkgname=pioneer +version=20170813 +revision=1 +build_style=gnu-configure +hostmakedepends="automake pkg-config" +makedepends="freetype-devel libassimp-devel libsigc++-devel + libvorbis-devel SDL2_image-devel" +depends="desktop-file-utils hicolor-icon-theme libtxc_dxtn" +maintainer="cr6git " +short_desc="Space adventure game set in our galaxy at the turn of the 31st century" +homepage="https://pioneerspacesim.net" +license="GPL-3" +distfiles="https://github.com/pioneerspacesim/pioneer/archive/${version}.tar.gz" +checksum=9a2feec5236f8ca6ee8f0d75bccdee7bf6ae62f7a08b9e37cdd178642fdd32f3 + +pre_configure() { + export PIONEER_DATA_DIR=/usr/share/pioneer + ./bootstrap +} + +post_install() { + vinstall ${FILESDIR}/pioneer.desktop 644 usr/share/applications + + for icon in application-icon/pngs/* + do + if [[ $icon =~ pioneer-([0-9]+x[0-9]+).png ]]; then + vinstall $icon 644 usr/share/icons/hicolor/${BASH_REMATCH[1]}/apps pioneer.png + fi + done + + vinstall application-icon/badge-enlarged-text.svg 644 usr/share/icons/hicolor/scalable/apps pioneer.svg +} +