# Maintainer: jc_gargma # Maintainer (AUR): George Rawlinson # Contributor (AUR): Max Zhao # Contributor (AUR): Leonard König # # I maintain this because: # AUR version uses /usr/share/games pkgname=endless-sky pkgver=0.9.12 pkgrel=1 arch=('i686' 'x86_64' 'aarch64') url="https://endless-sky.github.io/" depends=(openal libpng glew hicolor-icon-theme libjpeg-turbo sdl2 libmad) makedepends=(scons) optdepends=('endless-sky-high-dpi: high resolution graphics assets' 'endless-sky-editor: map editor') license=('GPL3' 'CCPL' 'custom:public domain') pkgdesc="A space exploration and combat game similar to Escape Velocity" source=("$pkgname-$pkgver.tar.gz::https://github.com/endless-sky/endless-sky/archive/v${pkgver}.tar.gz" ${pkgname}.desktop) b2sums=('8df20650524cb179e92306084668a8e341f88ca5adb1c6b6e2e48d450556a36556efcbff256dd6c0f47b4435739cfdbc7af357285af4ab15d5355e8f0ecba923' '8cb5f3300c003ae2c2316ac0ad342c7baa90851013e94811ec076cb6274d998b2aa9e0139b5bcb757b645c15382b4d2cb3f267eae589006902468e04a0534d01') build() { cd $pkgname-$pkgver export CFLAGS="$CFLAGS -O3 -flto=4 -fPIE" export CXXFLAGS="$CXXFLAGS -O3 -flto=4 -fPIE" export LDFLAGS="$LDFLAGS,-pie" scons "${MAKEFLAGS}" } package() { cd $pkgname-$pkgver # Install executable install -Dm755 endless-sky "${pkgdir}/usr/bin/endless-sky" # resources install -Dm644 credits.txt "${pkgdir}/usr/share/${pkgname}/credits.txt" install -Dm644 keys.txt "${pkgdir}/usr/share/${pkgname}/keys.txt" cp -rf data images sounds "${pkgdir}/usr/share/${pkgname}/" # .desktop install -Dm644 ${srcdir}/endless-sky.desktop "${pkgdir}/usr/share/applications/endless-sky.desktop" # icons for res in 16 22 24 32 48 128 256 512; do install -Dm644 \ "${srcdir}/${pkgname}-${pkgver}/icons/icon_${res}x${res}.png" \ "${pkgdir}/usr/share/icons/hicolor/${res}x${res}/apps/${pkgname}.png" done # manpage install -Dm644 -t "${pkgdir}/usr/share/man/man6" endless-sky.6 # copyright install -Dm644 copyright "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE" }