summaryrefslogtreecommitdiff
path: root/games-emulation/openmsx
diff options
context:
space:
mode:
authorV3n3RiX <venerix@redcorelinux.org>2020-12-25 23:06:25 +0000
committerV3n3RiX <venerix@redcorelinux.org>2020-12-25 23:06:25 +0000
commit441d1370330332b7d78f238d2f5e13f7aed5e4e0 (patch)
tree6a5171dd615dfeee62a45044144c66e864738fb0 /games-emulation/openmsx
parentab3da91fb6c91a9df52fff8f991570f456fd3c7a (diff)
gentoo christmass resync : 25.12.2020
Diffstat (limited to 'games-emulation/openmsx')
-rw-r--r--games-emulation/openmsx/Manifest3
-rw-r--r--games-emulation/openmsx/metadata.xml19
-rw-r--r--games-emulation/openmsx/openmsx-16.0.ebuild111
3 files changed, 133 insertions, 0 deletions
diff --git a/games-emulation/openmsx/Manifest b/games-emulation/openmsx/Manifest
new file mode 100644
index 000000000000..ef6f9a21b08c
--- /dev/null
+++ b/games-emulation/openmsx/Manifest
@@ -0,0 +1,3 @@
+DIST openmsx-16.0.tar.gz 3997584 BLAKE2B 040bb3f6ff0338740b5212aae21db2c97fcee0e8c8ada1bc84a59d94b1b72180c4b2d5eff8cc4ae84dd95bc77f121e15c2f818f1f2e05ba7dc4781b63770db38 SHA512 a06ec56a8a768356b628e59e587ec85898643b04379da5c72bbbd8e48a0533da34a451b7e4d2a2f540f14e6bbcf833534a1bdac9014ce0c35dfd4ca179618f48
+EBUILD openmsx-16.0.ebuild 2854 BLAKE2B 406a20e7831d8ada8911240c945331577e6eaaed31be72c4a03b60f7eeccd5d33f0096a386e2a053cf2ef82393f585f87acf3a4a2c734758c2e7084abacf2fac SHA512 8030615732d37b53c29541ec3e1dbe20dbb44fc97a96658cdb4bd18ef4f42239249734ad00a3f2664524fec8c82354fdeee7ed541d8010e2ff443579e3b9927d
+MISC metadata.xml 568 BLAKE2B 1bfc2740e73372e2e6583b5a7ee33e2354b1288543812728ae4d2a8b269ce55bb51a559a155d0331fe2e4f393ed9ff7d2a8a714fdad0c3ad0c592d4771296666 SHA512 bb481002ea3fc30faa397785a95c3092c343d8affd19ae31d1c6b3f5c980c4ad98024b40495e25598f85a1d295291ebdbe57cc1c4b1cbf0399619bee8f5335a3
diff --git a/games-emulation/openmsx/metadata.xml b/games-emulation/openmsx/metadata.xml
new file mode 100644
index 000000000000..4ae0b02dc389
--- /dev/null
+++ b/games-emulation/openmsx/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="project">
+ <email>games@gentoo.org</email>
+ <name>Gentoo Games Project</name>
+ </maintainer>
+ <maintainer type="person">
+ <email>jchelmert3@posteo.net</email>
+ <name>John Helmert III</name>
+ </maintainer>
+ <maintainer type="project">
+ <email>proxy-maint@gentoo.org</email>
+ <name>Proxy Maintainers</name>
+ </maintainer>
+ <upstream>
+ <remote-id type="github">openmsx/openmsx</remote-id>
+ </upstream>
+</pkgmetadata>
diff --git a/games-emulation/openmsx/openmsx-16.0.ebuild b/games-emulation/openmsx/openmsx-16.0.ebuild
new file mode 100644
index 000000000000..30edf81cdd26
--- /dev/null
+++ b/games-emulation/openmsx/openmsx-16.0.ebuild
@@ -0,0 +1,111 @@
+# Copyright 1999-2020 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+PYTHON_COMPAT=( python3_{6,7,8,9} )
+
+inherit desktop flag-o-matic python-any-r1 readme.gentoo-r1 toolchain-funcs xdg
+
+DESCRIPTION="MSX emulator that aims for perfection"
+HOMEPAGE="https://openmsx.org/"
+SRC_URI="https://github.com/openMSX/openMSX/releases/download/RELEASE_${PV//./_}/${P}.tar.gz"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+
+RDEPEND="dev-lang/tcl:0=
+ media-libs/alsa-lib
+ media-libs/libogg
+ media-libs/libpng:0=
+ media-libs/libsdl2[sound,video]
+ media-libs/libtheora
+ media-libs/libvorbis
+ media-libs/sdl2-ttf
+ >=media-libs/glew-1.3.2:0=
+ sys-libs/zlib
+ virtual/opengl"
+DEPEND="${RDEPEND}"
+BDEPEND="${PYTHON_DEPS}"
+
+DOC_CONTENTS="
+If you want to if you want to emulate real MSX systems and not
+only the free C-BIOS machines, put the system ROMs in one of
+the following directories: /usr/share/${PN}/systemroms
+or ~/.openMSX/share/systemroms
+"
+
+src_prepare() {
+ default
+ sed -i \
+ -e '/^LDFLAGS:=/d' \
+ -e '/LINK_FLAGS_PREFIX/d' \
+ -e '/LINK_FLAGS+=/s/-s//' \
+ -e '/LINK_FLAGS+=\$(TARGET_FLAGS)/s/$/ $(LDFLAGS)/' \
+ build/main.mk \
+ || die
+ sed -i -e '/SYMLINK/s:true:false:' build/custom.mk || die
+ sed -i -e 's/GPL.txt//' doc/node.mk || die
+
+ # Build system only configured to use bundled version - but not from the
+ # directory it's distributed in
+ cp "${S}/Contrib/catch2/catch.hpp" "${S}/src/unittest" || die
+}
+
+src_configure() {
+ tc-export CXX
+
+ # Doesn't compile without this, and build system doesn't consistently add
+ # it properly for all compilers
+ append-cxxflags '-std=c++17'
+
+ default
+}
+
+src_compile() {
+ emake \
+ CXXFLAGS="${CXXFLAGS}" \
+ INSTALL_SHARE_DIR="${EPREFIX}/usr/share/${PN}" \
+ V=1
+}
+
+src_test() {
+ # To get tests, we need to build with OPENMSX_FLAVOUR=unittest and then the
+ # build is stored in a directory of the pattern
+ # ${WORKDIR}/derived/*-unittest/. This is separate from the actual build,
+ # stored in ${WORKDIR}/derived/*-opt. The unittest binary and the workdir
+ # binary are in each of these directories under their `bin` directories.
+ emake \
+ V=1 \
+ CXXFLAGS="${CXXFLAGS}" \
+ OPENMSX_FLAVOUR=unittest
+
+ # There will only ever be one *-unittest directory
+ "${S}"/derived/*-unittest/bin/openmsx || die
+}
+
+src_install() {
+ # To guarantee installing the proper binary in case tests were built,
+ # specify the default OPENMSX_FLAVOUR
+ emake \
+ V=1 \
+ INSTALL_BINARY_DIR="${ED}/usr/bin" \
+ INSTALL_SHARE_DIR="${ED}/usr/share/${PN}" \
+ INSTALL_DOC_DIR="${ED}/usr/share/doc/${PF}" \
+ OPENMSX_FLAVOUR=opt \
+ install
+
+ einstalldocs
+ readme.gentoo_create_doc
+
+ for i in 16 32 48 64 128 256 ; do
+ newicon -s "${i}" "share/icons/openMSX-logo-${i}.png" "${PN}.png"
+ done
+ make_desktop_entry "${PN}" "openMSX"
+}
+
+pkg_postinst() {
+ readme.gentoo_print_elog
+ xdg_pkg_postinst
+}