diff options
author | Arvedui | 2021-02-28 12:24:48 +0100 |
---|---|---|
committer | Arvedui | 2021-02-28 12:24:48 +0100 |
commit | 2b1a2016d40328bde057029b8c6d775aea2d38b9 (patch) | |
tree | 553d2121c21c08676b397dd818a8eda1a3403b7c | |
parent | 7098ad513dfc1f4dab13621d8fa20b63caeb9c6a (diff) | |
download | aur-2b1a2016d40328bde057029b8c6d775aea2d38b9.tar.gz |
sameboy: update packaging
-rw-r--r-- | .SRCINFO | 6 | ||||
-rw-r--r-- | PKGBUILD | 33 |
2 files changed, 28 insertions, 11 deletions
@@ -1,17 +1,21 @@ pkgbase = sameboy pkgdesc = An accuracy-focused Game Boy/Game Boy Color emulator pkgver = 0.14 - pkgrel = 1 + pkgrel = 2 url = https://github.com/LIJI32/SameBoy arch = x86_64 license = MIT makedepends = rgbds makedepends = make makedepends = git + makedepends = xdg-utils depends = sdl2 + depends = hicolor-icon-theme conflicts = sameboy-git source = sameboy-0.14.tar.gz::https://github.com/LIJI32/SameBoy/archive/v0.14.tar.gz + source = sameboy-0a4cb814-fix-destdir.patch::https://github.com/LIJI32/SameBoy/commit/0a4cb8148f6bcecd20486a6563a43eb9c074500c.patch md5sums = c98eb4bd5a645ade48cd0dba1f496bd5 + md5sums = dab79f4afa38cabf94a46634eb3e2d66 pkgname = sameboy @@ -4,16 +4,23 @@ pkgname=sameboy pkgdesc="An accuracy-focused Game Boy/Game Boy Color emulator" pkgver=0.14 -pkgrel=1 +pkgrel=2 arch=(x86_64) url="https://github.com/LIJI32/SameBoy" license=(MIT) -depends=(sdl2) +depends=(sdl2 hicolor-icon-theme) conflicts=(sameboy-git) # Upstream suggests using clang, but gcc is supported on Linux: https://github.com/LIJI32/SameBoy/issues/164#issuecomment-486464194 -makedepends=(rgbds make git) -source=("${pkgname}-${pkgver}.tar.gz::https://github.com/LIJI32/SameBoy/archive/v${pkgver}.tar.gz") -md5sums=('c98eb4bd5a645ade48cd0dba1f496bd5') +makedepends=(rgbds make git xdg-utils) +source=("${pkgname}-${pkgver}.tar.gz::https://github.com/LIJI32/SameBoy/archive/v${pkgver}.tar.gz" + "sameboy-0a4cb814-fix-destdir.patch::https://github.com/LIJI32/SameBoy/commit/0a4cb8148f6bcecd20486a6563a43eb9c074500c.patch") +md5sums=('c98eb4bd5a645ade48cd0dba1f496bd5' + 'dab79f4afa38cabf94a46634eb3e2d66') + +prepare() { + cd "${srcdir}/SameBoy-${pkgver}" + patch -p1 < "${srcdir}/sameboy-0a4cb814-fix-destdir.patch" +} build(){ cd "${srcdir}/SameBoy-${pkgver}" @@ -22,9 +29,15 @@ build(){ package(){ cd "${srcdir}/SameBoy-${pkgver}" - install -Dm755 build/bin/SDL/sameboy "$pkgdir/usr/bin/sameboy" - find build/bin/SDL -type f -not -executable | while read f; do - install -Dm644 "$f" "$pkgdir/usr/share/games/sameboy/${f#build/bin/SDL/}" - done - install -Dm644 LICENSE "$pkgdir/usr/share/licenses/sameboy/LICENSE" + + make install CONF=release PREFIX=/usr/ DESTDIR="${pkgdir}" + install -D "${pkgdir}/usr/share/sameboy/LICENSE" "${pkgdir}/usr/share/licenses/sameboy/LICENSE" + rm "${pkgdir}/usr/share/sameboy/LICENSE" + install -Dm644 FreeDesktop/sameboy.desktop "${pkgdir}/usr/share/applications/sameboy.desktop" + + # mimetype icons don't belong here + # that could lead to file conflicts + find "${pkgdir}" -name 'x-gameboy*-rom.png' -delete + find "${pkgdir}" -name mimetypes -delete + } |