diff options
author | Sebastian Riedel | 2021-02-02 19:37:20 +0100 |
---|---|---|
committer | Sebastian Riedel | 2021-02-02 19:37:20 +0100 |
commit | 8ebd908606333bfdd68871f5643376bdea799673 (patch) | |
tree | 80d4bb479ee619abd9281d766b13f396f39a7d81 | |
parent | b4383f1b71edd299ce6da814f39e26e8fc69424a (diff) | |
download | aur-8ebd908606333bfdd68871f5643376bdea799673.tar.gz |
Add icons and .desktop file
-rw-r--r-- | .SRCINFO | 6 | ||||
-rw-r--r-- | PKGBUILD | 24 |
2 files changed, 25 insertions, 5 deletions
@@ -1,6 +1,6 @@ pkgbase = sameboy-git pkgdesc = An accuracy-focused Game Boy/Game Boy Color emulator - pkgver = 1266.9e8b4345 + pkgver = 1413.8ad08c1b pkgrel = 1 url = https://github.com/LIJI32/SameBoy arch = x86_64 @@ -8,7 +8,11 @@ pkgbase = sameboy-git makedepends = rgbds makedepends = make makedepends = git + makedepends = gendesk + makedepends = libicns + makedepends = imagemagick depends = sdl2 + depends = hicolor-icon-theme provides = sameboy source = git+https://github.com/LIJI32/SameBoy sha1sums = SKIP @@ -1,21 +1,26 @@ # Maintainer: Jakub Kądziołka <kuba@kadziolka.net> +# Maintainer: basxto <archlinux basxto de> pkgname=sameboy-git +_genericname="Emulator" pkgdesc="An accuracy-focused Game Boy/Game Boy Color emulator" -pkgver=1266.9e8b4345 +_mimetype="application/x-gameboy-rom;application/x-gameboy-color-rom" +pkgver=1413.8ad08c1b pkgrel=1 arch=(x86_64) url="https://github.com/LIJI32/SameBoy" license=(MIT) provides=(sameboy) -depends=(sdl2) +depends=(sdl2 hicolor-icon-theme) # Upstream suggests using clang, but gcc is supported on Linux: https://github.com/LIJI32/SameBoy/issues/164#issuecomment-486464194 -makedepends=(rgbds make git) +makedepends=(rgbds make git gendesk libicns imagemagick) source=(git+https://github.com/LIJI32/SameBoy) -sha1sums=(SKIP) +sha1sums=('SKIP') prepare(){ + gendesk -f -n sed -i 's/-Werror//' SameBoy/Makefile + icns2png -x "${srcdir}/SameBoy/Cocoa/AppIcon.icns" -o "${srcdir}" } pkgver(){ @@ -29,6 +34,17 @@ build(){ } package(){ + # copy existing icon sizes + for i in 16 32 256 512 1024;do + install -d "${pkgdir}/usr/share//icons/hicolor/${i}x${i}/apps/" + install -Dm644 "${srcdir}/AppIcon_${i}x${i}x32.png" "${pkgdir}/usr/share/icons/hicolor/${i}x${i}/apps/${provides[0]}.png" + done + # generate all other icon sizes + for i in 24 48 64 72 96 128;do + install -d "${pkgdir}/usr/share//icons/hicolor/${i}x${i}/apps/" + magick convert "${srcdir}/AppIcon_256x256x32.png" -resize ${i}x${i} "${pkgdir}/usr/share/icons/hicolor/${i}x${i}/apps/${provides[0]}.png" + done + install -Dm644 "${provides[0]}.desktop" "${pkgdir}/usr/share/applications/${provides[0]}.desktop" cd SameBoy install -Dm755 build/bin/SDL/sameboy "$pkgdir/usr/bin/sameboy" find build/bin/SDL -type f -not -executable | while read f; do |