summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJames Le Cuirot <chewi@gentoo.org>2019-12-10 21:28:38 +0000
committerJames Le Cuirot <chewi@gentoo.org>2019-12-10 21:38:14 +0000
commit290247e5dd1e4b7ad50452a1a2e5a18ed9c12d7c (patch)
tree935e6032ca19ddd2e650834faa619505ec83bcfc /app-emulation/aranym
parentprofiles: Mask app-emulation/aranym[jit] except on amd64/x86 (diff)
downloadgentoo-290247e5dd1e4b7ad50452a1a2e5a18ed9c12d7c.tar.gz
gentoo-290247e5dd1e4b7ad50452a1a2e5a18ed9c12d7c.tar.bz2
gentoo-290247e5dd1e4b7ad50452a1a2e5a18ed9c12d7c.zip
app-emulation/aranym: New package
Package-Manager: Portage-2.3.81, Repoman-2.3.19 Signed-off-by: James Le Cuirot <chewi@gentoo.org>
Diffstat (limited to 'app-emulation/aranym')
-rw-r--r--app-emulation/aranym/Manifest1
-rw-r--r--app-emulation/aranym/aranym-1.1.0.ebuild94
-rw-r--r--app-emulation/aranym/files/aranym-1.1.0-conditional-installs.patch93
-rw-r--r--app-emulation/aranym/metadata.xml19
4 files changed, 207 insertions, 0 deletions
diff --git a/app-emulation/aranym/Manifest b/app-emulation/aranym/Manifest
new file mode 100644
index 000000000000..e50669b9613e
--- /dev/null
+++ b/app-emulation/aranym/Manifest
@@ -0,0 +1 @@
+DIST aranym_1.1.0.orig.tar.gz 3785612 BLAKE2B 52b5fa34c78c67cb94cbe0d94795368cb7007f37571282d67387a0237500143f8078117132c9df392c5fd48b32cdb8c1cf727fe4d22a3d24eac0595215bddf4e SHA512 723b1a7c80532734e1dea288dbffd66746d9c7d1302ccb0259248a26aac5dedc7f66a134929de7064686af6c676d10918d90e2cf58cb010fd445979945177b51
diff --git a/app-emulation/aranym/aranym-1.1.0.ebuild b/app-emulation/aranym/aranym-1.1.0.ebuild
new file mode 100644
index 000000000000..de23d6c707ea
--- /dev/null
+++ b/app-emulation/aranym/aranym-1.1.0.ebuild
@@ -0,0 +1,94 @@
+# Copyright 1999-2019 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+inherit autotools multibuild xdg
+
+DESCRIPTION="Atari Running on Any Machine, VM running Atari ST/TT/Falcon OS and TOS/GEM apps"
+HOMEPAGE="https://aranym.github.io"
+SRC_URI="https://github.com/${PN}/${PN}/releases/download/${PN^^}_${PV//./_}/${PN}_${PV}.orig.tar.gz"
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+IUSE="+clipboard +jit jpeg lilo opengl osmesa pmmu +standard usb"
+REQUIRED_USE="|| ( jit pmmu standard ) lilo? ( pmmu )"
+
+# LILO can be used without zlib but the zlib dependency is automagic so
+# we just require it unconditionally.
+
+RDEPEND="
+ dev-libs/gmp:0=
+ media-libs/libsdl2[video]
+ clipboard? ( !kernel_Winnt? ( x11-libs/libX11 ) )
+ jpeg? ( virtual/jpeg )
+ kernel_linux? ( virtual/libudev )
+ lilo? ( sys-libs/zlib )
+ opengl? ( virtual/opengl )
+ osmesa? ( media-libs/mesa[osmesa] )
+ pmmu? ( dev-libs/mpfr:0= )
+ usb? ( virtual/libusb:1 )
+"
+
+DEPEND="${RDEPEND}"
+BDEPEND="virtual/pkgconfig"
+
+PATCHES=(
+ "${FILESDIR}"/${PN}-1.1.0-conditional-installs.patch
+)
+
+ECONF_SOURCE="${S}"
+DOCS=()
+
+src_prepare() {
+ xdg_src_prepare
+ eautoreconf
+}
+
+src_configure() {
+ # standard must come last otherwise the aranym executable gets
+ # overwritten by the others.
+ MULTIBUILD_VARIANTS=(
+ $(usev jit)
+ $(usev pmmu)
+ $(usev standard)
+ )
+
+ multibuild_foreach_variant run_in_build_dir multibuild_src_configure
+}
+
+multibuild_src_configure() {
+ # jit-fpu doesn't work on some platforms. FPUs were optional in
+ # Ataris anyway so just disable.
+ local myconf=(
+ $(use_enable opengl)
+ $(use_enable usb usbhost)
+ $(use_enable osmesa nfosmesa)
+ $(use_enable jpeg nfjpeg)
+ $(use_enable clipboard nfclipbrd)
+ --disable-jit-fpu
+ )
+
+ if [[ ${MULTIBUILD_VARIANT} == jit ]]; then
+ myconf+=( --enable-jit-compiler )
+ else
+ myconf+=( --disable-jit-compiler )
+ fi
+
+ if [[ ${MULTIBUILD_VARIANT} == pmmu ]]; then
+ myconf+=( --enable-fullmmu $(use_enable lilo) )
+ else
+ myconf+=( --disable-fullmmu --disable-lilo )
+ fi
+
+ # Force use of SDL2 over SDL1.
+ ac_cv_path_SDL_CONFIG=no econf "${myconf[@]}"
+
+ # https://github.com/aranym/aranym/issues/54
+ echo "#define HAVE_X11_XLIB_H 1" >> config.h || die
+}
+
+src_install() {
+ multibuild_foreach_variant run_in_build_dir default
+ rm "${ED}"/usr/share/doc/${PF}/COPYING || die
+}
diff --git a/app-emulation/aranym/files/aranym-1.1.0-conditional-installs.patch b/app-emulation/aranym/files/aranym-1.1.0-conditional-installs.patch
new file mode 100644
index 000000000000..20ba1c1c4a0e
--- /dev/null
+++ b/app-emulation/aranym/files/aranym-1.1.0-conditional-installs.patch
@@ -0,0 +1,93 @@
+From 944ae098635d8bd4320b2acafc5746448e241db6 Mon Sep 17 00:00:00 2001
+From: James Le Cuirot <chewi@gentoo.org>
+Date: Wed, 4 Dec 2019 23:31:04 +0000
+Subject: [PATCH] Reuse icon file and install normal/JIT/MMU files
+ conditionally
+
+---
+ Makefile.am | 19 ++++++++++---------
+ contrib/aranym-jit.desktop | 2 +-
+ contrib/aranym-mmu.desktop | 2 +-
+ doc/Makefile.am | 8 +++++++-
+ 4 files changed, 19 insertions(+), 12 deletions(-)
+
+diff --git a/Makefile.am b/Makefile.am
+index 9fbc64b6..9dc7b71b 100644
+--- a/Makefile.am
++++ b/Makefile.am
+@@ -79,18 +79,19 @@ install-data-local:
+ for s in 32 48; do \
+ $(mkinstalldirs) "${DESTDIR}${datadir}/icons/hicolor/$${s}x$${s}/apps/"; \
+ $(INSTALL_DATA) $(top_srcdir)/contrib/icon-$${s}.png "${DESTDIR}${datadir}/icons/hicolor/$${s}x$${s}/apps/aranym.png"; \
+- $(INSTALL_DATA) $(top_srcdir)/contrib/icon-$${s}.png "${DESTDIR}${datadir}/icons/hicolor/$${s}x$${s}/apps/aranym-jit.png"; \
+- $(INSTALL_DATA) $(top_srcdir)/contrib/icon-$${s}.png "${DESTDIR}${datadir}/icons/hicolor/$${s}x$${s}/apps/aranym-mmu.png"; \
+ done
+ $(mkinstalldirs) "${DESTDIR}${datadir}/pixmaps"
+- rm -f "${DESTDIR}${datadir}/pixmaps/aranym"*.png
+- ln -s ../icons/hicolor/32x32/apps/aranym.png "${DESTDIR}${datadir}/pixmaps/aranym.png"
+- ln -s ../icons/hicolor/32x32/apps/aranym.png "${DESTDIR}${datadir}/pixmaps/aranym-jit.png"
+- ln -s ../icons/hicolor/32x32/apps/aranym.png "${DESTDIR}${datadir}/pixmaps/aranym-mmu.png"
++ ln -sf ../icons/hicolor/32x32/apps/aranym.png "${DESTDIR}${datadir}/pixmaps/aranym.png"
+ $(mkinstalldirs) "${DESTDIR}${datadir}/applications"
+- for name in aranym aranym-jit aranym-mmu; do \
+- $(INSTALL_DATA) "$(top_srcdir)/contrib/$${name}.desktop" "${DESTDIR}${datadir}/applications/$${name}.desktop"; \
+- done
++if USE_JIT
++ $(INSTALL_DATA) "$(top_srcdir)/contrib/aranym-jit.desktop" "${DESTDIR}${datadir}/applications/aranym-jit.desktop"
++else
++if FULLMMU
++ $(INSTALL_DATA) "$(top_srcdir)/contrib/aranym-mmu.desktop" "${DESTDIR}${datadir}/applications/aranym-mmu.desktop"
++else
++ $(INSTALL_DATA) "$(top_srcdir)/contrib/aranym.desktop" "${DESTDIR}${datadir}/applications/aranym.desktop"
++endif
++endif
+
+ uninstall-local:
+ rm -f $(DESTDIR)$(docdir)/changelog
+diff --git a/contrib/aranym-jit.desktop b/contrib/aranym-jit.desktop
+index 1ca2c55a..5a4ee582 100644
+--- a/contrib/aranym-jit.desktop
++++ b/contrib/aranym-jit.desktop
+@@ -3,7 +3,7 @@ Encoding=UTF-8
+ Name=ARAnyM JIT
+ Comment=Virtual Machine with JIT CPU compiler for max speed
+ Exec=aranym-jit
+-Icon=aranym-jit
++Icon=aranym
+ Terminal=false
+ Type=Application
+ Categories=System;Emulator;
+diff --git a/contrib/aranym-mmu.desktop b/contrib/aranym-mmu.desktop
+index 610d0e52..2b841f23 100644
+--- a/contrib/aranym-mmu.desktop
++++ b/contrib/aranym-mmu.desktop
+@@ -3,7 +3,7 @@ Encoding=UTF-8
+ Name=ARAnyM MMU
+ Comment=Virtual Machine with MMU for FreeMiNT and Linux-m68k
+ Exec=aranym-mmu
+-Icon=aranym-mmu
++Icon=aranym
+ Terminal=false
+ Type=Application
+ Categories=System;Emulator;
+diff --git a/doc/Makefile.am b/doc/Makefile.am
+index 3f466ef8..f0a0688e 100644
+--- a/doc/Makefile.am
++++ b/doc/Makefile.am
+@@ -1,6 +1,12 @@
+ man1dir = $(mandir)/man1
+
+-man1_MANS = aranym.1 aranym-mmu.1 aranym-jit.1
++man1_MANS = aranym.1
++if USE_JIT
++man1_MANS += aranym-jit.1
++endif
++if FULLMMU
++man1_MANS += aranym-mmu.1
++endif
+ if NEED_ARATAPIF
+ man1_MANS += aratapif.1
+ endif
+--
+2.24.0
+
diff --git a/app-emulation/aranym/metadata.xml b/app-emulation/aranym/metadata.xml
new file mode 100644
index 000000000000..a9d26d2bbfb7
--- /dev/null
+++ b/app-emulation/aranym/metadata.xml
@@ -0,0 +1,19 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+ <maintainer type="person">
+ <email>chewi@gentoo.org</email>
+ <name>James Le Cuirot</name>
+ </maintainer>
+ <upstream>
+ <remote-id type="github">aranym/aranym</remote-id>
+ </upstream>
+ <use>
+ <flag name="clipboard">Enable bidirectional clipboard transfer between the host and FreeMiNT</flag>
+ <flag name="jit">Build Just-In-Time compiler variant with increased performance</flag>
+ <flag name="lilo">Enable support for directly booting kernels such as Linux</flag>
+ <flag name="osmesa">Allow images to be rendered in memory using the host CPU</flag>
+ <flag name="pmmu">Build full PMMU variant, required for running mainline Linux</flag>
+ <flag name="standard">Build standard (no JIT or PMMU) variant</flag>
+ </use>
+</pkgmetadata>