commit:     dfb458adec58627bc15622058456789afe48ec1a
Author:     Maciej Barć <xgqt <AT> gentoo <DOT> org>
AuthorDate: Tue May  2 00:37:50 2023 +0000
Commit:     Maciej Barć <xgqt <AT> gentoo <DOT> org>
CommitDate: Tue May  2 00:39:03 2023 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=dfb458ad

app-emulation/uxn: bump to 0_p20230501

Signed-off-by: Maciej Barć <xgqt <AT> gentoo.org>

 app-emulation/uxn/Manifest               |  1 +
 app-emulation/uxn/uxn-0_p20230501.ebuild | 56 ++++++++++++++++++++++++++++++++
 2 files changed, 57 insertions(+)

diff --git a/app-emulation/uxn/Manifest b/app-emulation/uxn/Manifest
index a1c9e253ed8b..459860c024d2 100644
--- a/app-emulation/uxn/Manifest
+++ b/app-emulation/uxn/Manifest
@@ -1,2 +1,3 @@
 DIST uxn-0_p20221211.tar.gz 284943 BLAKE2B 
de116e87120bc71975271c9ad0c1b01cba6e13a78cba0faaf811a2cace72204f15fca620bb4c87518542208e1c2af49e6db98b1b3b442ec3a855fb8b592acb2d
 SHA512 
d59504f994b487aff151fefdb2f0f87a707fe998c1ea08539dc8d67aed28a4c93c9ff4bde036a9eb44401e8e6a12b7a15c17e434d5cab7b44a17e2e18e50e978
 DIST uxn-0_p20230201.tar.gz 285942 BLAKE2B 
2ace9aba9e7c5c7cd60c8db2208e16b4af4830dee5bb10eaa228028ada8701154069423a6b920a09821f63e52dd8955c48e2f13b58061aa08256045e20aaf020
 SHA512 
e33ff693124d14ee94c8192adb47d940f08d37c22067264afdcae7f4f9ac713915c4daa3bbee3e38385cb71b988a30991ca8ea123dd542438367eaf3a4c88f84
+DIST uxn-0_p20230501.tar.gz 285942 BLAKE2B 
2ace9aba9e7c5c7cd60c8db2208e16b4af4830dee5bb10eaa228028ada8701154069423a6b920a09821f63e52dd8955c48e2f13b58061aa08256045e20aaf020
 SHA512 
e33ff693124d14ee94c8192adb47d940f08d37c22067264afdcae7f4f9ac713915c4daa3bbee3e38385cb71b988a30991ca8ea123dd542438367eaf3a4c88f84

diff --git a/app-emulation/uxn/uxn-0_p20230501.ebuild 
b/app-emulation/uxn/uxn-0_p20230501.ebuild
new file mode 100644
index 000000000000..8ecf6d857beb
--- /dev/null
+++ b/app-emulation/uxn/uxn-0_p20230501.ebuild
@@ -0,0 +1,56 @@
+# Copyright 1999-2023 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+inherit toolchain-funcs
+
+DESCRIPTION="An assembler and emulator for the Uxn stack-machine, written in 
ANSI C"
+HOMEPAGE="https://wiki.xxiivv.com/site/uxn.html
+       https://git.sr.ht/~rabbits/uxn/";
+
+if [[ ${PV} == *9999* ]] ; then
+       inherit git-r3
+       EGIT_REPO_URI="https://git.sr.ht/~rabbits/uxn.git";
+elif [[ ${PV} == *_p20230501 ]] ; then
+       COMMIT=0dcc3b4c2e12bf2a61e682e9168e8bdb469caae0
+       SRC_URI="https://git.sr.ht/~rabbits/uxn/archive/${COMMIT}.tar.gz
+               -> ${P}.tar.gz"
+       S="${WORKDIR}"/${PN}-${COMMIT}
+       KEYWORDS="~amd64 ~x86"
+else
+       die "wrong package version (PV), given: ${PV}"
+fi
+
+LICENSE="MIT"
+SLOT="0"
+
+RDEPEND="media-libs/libsdl2:="
+DEPEND="${RDEPEND}"
+
+PATCHES=( "${FILESDIR}"/uxn-build.sh.patch )
+
+src_compile() {
+       CC="$(tc-getCC)" CFLAGS="${CFLAGS} ${LDFLAGS}" ./build.sh --no-run ||
+               die "build failed"
+
+       local f
+       local f_base
+       for f in ./projects/{examples/*,software,utils}/*.tal ; do
+               f_base="$(basename "${f}" .tal)"
+               ebegin "Assembling ROM ${f_base}"
+               ./bin/uxnasm "${f}" "$(dirname "${f}")"/"${f_base}".rom
+               eend ${?} ||  die "failed to assemble ${f}"
+       done
+}
+
+src_install() {
+       exeinto /usr/bin
+       doexe bin/uxn*
+
+       insinto /usr/share/uxn
+       doins bin/*.rom
+       doins -r projects
+
+       einstalldocs
+}

Reply via email to