diff options
author | Claudia Pellegrino | 2023-09-19 14:32:52 +0200 |
---|---|---|
committer | Claudia Pellegrino | 2023-09-19 18:41:29 +0200 |
commit | 61465be7f5d67fb906fe534c722190e976c33b8b (patch) | |
tree | a6d0a74a5bcb662e5b23c066ed57890beb513b35 | |
parent | 8bd9cea89ef8f838b980e6c55fa1334fdbc2b527 (diff) | |
download | aur-61465be7f5d67fb906fe534c722190e976c33b8b.tar.gz |
nesfab v1.1
-rw-r--r-- | .SRCINFO | 12 | ||||
-rw-r--r-- | PKGBUILD | 24 | ||||
-rw-r--r-- | github-pr-20.patch | 37 | ||||
-rw-r--r-- | github-pr-22.patch | 20 |
4 files changed, 85 insertions, 8 deletions
@@ -1,7 +1,7 @@ pkgbase = nesfab pkgdesc = Programming language for creating NES games - pkgver = 1.0 - pkgrel = 2 + pkgver = 1.1 + pkgrel = 1 url = https://github.com/pubby/nesfab install = nesfab.install arch = x86_64 @@ -12,10 +12,14 @@ pkgbase = nesfab depends = boost-libs depends = gcc-libs depends = glibc - source = nesfab-1.0.tar.gz::https://github.com/pubby/nesfab/archive/v1.0.tar.gz + source = nesfab-1.1.tar.gz::https://github.com/pubby/nesfab/archive/v1.1.tar.gz + source = github-pr-20.patch + source = github-pr-22.patch source = version-no-git-commit.patch source = ada.png - sha512sums = 5c3cf4fbe824ff6c0a850f5bb891a2ce174c963665a65abca9ba74f7f130618d5079e544ebaaf749b1f8c7bca7c49d1317f505a196720519f44bf43daebbf0f6 + sha512sums = 2fca7187ab169c5554e42ed7356d1f6ea649531392b36fceecedba97523aff116098b248b7c3888e2f1d0296c790b8e3eff0c4f97c25d704df81757698cec5d9 + sha512sums = f30b5bc4bae177481ed33d0a0aa36f882ca60ff32bce0c36d5f6ae63158056506ea90ac4643e300888691fa45a856b5f3fbed25b46ef82b903668f0c0627bddf + sha512sums = 096bb42b779d9d95c41e14da60df9745a731aec9d8e2ef50b1d93be3a05e165727220f477254c01b6cc2877b9c132e0d856cad7ec8476c5ae70d7fdcd056146e sha512sums = aae378095d1cb2797ced05efb5ab87fdfc8e9c8c3c4aaa00d27a8ec76125a0a628364f314defdb29797cb7fd1c00035788e7f2393eb34d70a58a4a8db2b7898c sha512sums = 74f6199454f64ed2f4a4ba998bf11b1bab07d3944b35c49827f64cdf233e318393e4d93a954b8c39504b814db8ebe68d72b72566afecd3e275739d9b0afa194a @@ -1,8 +1,8 @@ # Maintainer: Claudia Pellegrino <aur ät cpellegrino.de> pkgname=nesfab -pkgver=1.0 -pkgrel=2 +pkgver=1.1 +pkgrel=1 pkgdesc='Programming language for creating NES games' arch=('x86_64') url='https://github.com/pubby/nesfab' @@ -13,12 +13,16 @@ install="${pkgname}.install" source=( "${pkgname}-${pkgver}.tar.gz::https://github.com/pubby/nesfab/archive/v${pkgver}.tar.gz" + 'github-pr-20.patch' + 'github-pr-22.patch' 'version-no-git-commit.patch' 'ada.png' ) sha512sums=( - '5c3cf4fbe824ff6c0a850f5bb891a2ce174c963665a65abca9ba74f7f130618d5079e544ebaaf749b1f8c7bca7c49d1317f505a196720519f44bf43daebbf0f6' + '2fca7187ab169c5554e42ed7356d1f6ea649531392b36fceecedba97523aff116098b248b7c3888e2f1d0296c790b8e3eff0c4f97c25d704df81757698cec5d9' + 'f30b5bc4bae177481ed33d0a0aa36f882ca60ff32bce0c36d5f6ae63158056506ea90ac4643e300888691fa45a856b5f3fbed25b46ef82b903668f0c0627bddf' + '096bb42b779d9d95c41e14da60df9745a731aec9d8e2ef50b1d93be3a05e165727220f477254c01b6cc2877b9c132e0d856cad7ec8476c5ae70d7fdcd056146e' 'aae378095d1cb2797ced05efb5ab87fdfc8e9c8c3c4aaa00d27a8ec76125a0a628364f314defdb29797cb7fd1c00035788e7f2393eb34d70a58a4a8db2b7898c' '74f6199454f64ed2f4a4ba998bf11b1bab07d3944b35c49827f64cdf233e318393e4d93a954b8c39504b814db8ebe68d72b72566afecd3e275739d9b0afa194a' ) @@ -26,6 +30,16 @@ sha512sums=( prepare() { cd "${srcdir}/${pkgname}-${pkgver}" + # Remove this patch once upstream PR #20 has been merged and + # included in a stable upstream release. + # See also: https://github.com/pubby/nesfab/pull/20 + patch -p1 < ../github-pr-20.patch + + # Remove this workaround once upstream issue #21 has been fixed + # and the fix has been included in a stable upstream release. + # See also: https://github.com/pubby/nesfab/issues/21 + patch -p1 < ../github-pr-22.patch + # Remove dependency on Git commit, which is unknown to this build. # Use sed to pre-process the Makefile to avoid conflicts during # patching, because the VERSION line in the surrounding context @@ -34,7 +48,9 @@ prepare() { patch -p1 < ../version-no-git-commit.patch # https://pursuit.unimelb.edu.au/articles/it-s-time-to-retire-lena-from-computer-science - cp -v ../ada.png examples/pbz/bg.png + for example in fade mmc3 pbz scanline_irq; do + cp -v ../ada.png "examples/${example}/bg.png" + done # Tweak example script so it expects the executable to live in /usr/bin # shellcheck disable=SC2016 diff --git a/github-pr-20.patch b/github-pr-20.patch new file mode 100644 index 000000000000..8c702fdbc94b --- /dev/null +++ b/github-pr-20.patch @@ -0,0 +1,37 @@ +From 1643cce810c0fb0b2ef9cb370292e4286a70f336 Mon Sep 17 00:00:00 2001 +From: Claudia <claui@users.noreply.github.com> +Date: Tue, 19 Sep 2023 17:14:51 +0200 +Subject: [PATCH] mmc1: fix duplicate function identifier + +Building the `mmc1` example: + +> nesfab ./mmc1/mmc1.cfg + +results in the following build error: + +> ../../../../../../../usr/share/nesfab/lib/mapper/mmc1.fab:94:8: error: Global identifier mmc1_set_chr_1 already in use. +> 94 | asm fn mmc1_set_chr_1(U value) +> ^^^^^^^^^^^^^^ +> ../../../../../../../usr/share/nesfab/lib/mapper/mmc1.fab:69:8: note: Previous definition here: +> 69 | asm fn mmc1_set_chr_1(U value) +> ^^^^^^^^^^^^^^ + +Fix the duplicate definition by appending an `_unsafe` suffix, just like +it was done with `mmc1_set_chr_0` vs. `mmc1_set_chr_0_unsafe`. +--- + lib/mapper/mmc1.fab | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/lib/mapper/mmc1.fab b/lib/mapper/mmc1.fab +index 60bd743..8605850 100644 +--- a/lib/mapper/mmc1.fab ++++ b/lib/mapper/mmc1.fab +@@ -91,7 +91,7 @@ asm fn mmc1_set_chr_1(U value) + rts + + // Writes the CHR_1 register, the unsafe bank switch version: +-asm fn mmc1_set_chr_1(U value) ++asm fn mmc1_set_chr_1_unsafe(U value) + : employs + : +static + lda &value diff --git a/github-pr-22.patch b/github-pr-22.patch new file mode 100644 index 000000000000..4fbd652a560e --- /dev/null +++ b/github-pr-22.patch @@ -0,0 +1,20 @@ +From 0831aa620cad2d617b10f72c6a20249dd1b945e2 Mon Sep 17 00:00:00 2001 +From: Claudia <claui@users.noreply.github.com> +Date: Tue, 19 Sep 2023 18:33:43 +0200 +Subject: [PATCH] scanline_irq: use MMC3 to work around issue #21 + +See also: https://github.com/pubby/nesfab/issues/21 +--- + examples/scanline_irq/scanline_irq.cfg | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/examples/scanline_irq/scanline_irq.cfg b/examples/scanline_irq/scanline_irq.cfg +index 4257762..0cd6b43 100644 +--- a/examples/scanline_irq/scanline_irq.cfg ++++ b/examples/scanline_irq/scanline_irq.cfg +@@ -1,4 +1,4 @@ +-mapper = 189 ++mapper = mmc3 + output = scanline_irq.nes + nesfab-dir = ../../ + input = lib/nes.fab |