summaryrefslogtreecommitdiff
path: root/app-emulation/gallium-nine-standalone
diff options
context:
space:
mode:
authorV3n3RiX <venerix@redcorelinux.org>2019-01-22 10:09:44 +0000
committerV3n3RiX <venerix@redcorelinux.org>2019-01-22 10:09:44 +0000
commit09351e78166b5e864197c4456ebae3f89dd0bed9 (patch)
tree41a96399f56ed3aa399006871bfce4430db84aa2 /app-emulation/gallium-nine-standalone
parentc8a77dfe4d3d307c1d5dd2650b7297447d8b609d (diff)
gentoo resync : 22.01.2019
Diffstat (limited to 'app-emulation/gallium-nine-standalone')
-rw-r--r--app-emulation/gallium-nine-standalone/Manifest6
-rw-r--r--app-emulation/gallium-nine-standalone/files/flags.patch28
-rw-r--r--app-emulation/gallium-nine-standalone/files/nine-dll-path.patch12
-rw-r--r--app-emulation/gallium-nine-standalone/gallium-nine-standalone-0_p20190113.ebuild110
-rw-r--r--app-emulation/gallium-nine-standalone/gallium-nine-standalone-9999.ebuild110
-rw-r--r--app-emulation/gallium-nine-standalone/metadata.xml20
6 files changed, 286 insertions, 0 deletions
diff --git a/app-emulation/gallium-nine-standalone/Manifest b/app-emulation/gallium-nine-standalone/Manifest
new file mode 100644
index 000000000000..b779be5ba222
--- /dev/null
+++ b/app-emulation/gallium-nine-standalone/Manifest
@@ -0,0 +1,6 @@
+AUX flags.patch 928 BLAKE2B 62f7d6c3e904ad13f39f6e554fb02784b1d68bcea92208c16f0583d41dbd95c1bc52d6b58ee7b88aff54073f9afc078839759f752ee765ebb8059a81fe52dee3 SHA512 e37221abb35a4c170a38db0129a0413b54863952ed00efa36dd0b8af67850cde3949d8b81547bad8c13783ddd7a32407b6eaf33881505cdfe165a29ec9c31c19
+AUX nine-dll-path.patch 550 BLAKE2B 8f9478144cef848f813a044a7c7f56f197aa604d2e5bfb872962cdae67f7f2a62a2d9196959998a2cfe4043ec547956c2fb48d15784257de8af97c5483f8e328 SHA512 98e697430ea2ed59e213bb4af0d87312e5931996bfaa04834877e2405562f881b761c6886aa1331a82d1fd6ad63e2e1c2d83b271df8ce3cd2ed4a2a039737f85
+DIST gallium-nine-standalone-0_p20190113.tar.gz 58954 BLAKE2B 29be3f5501cc4463aa05216b7360e2a5a949c498dd1c3a0170d5a2f7f508c1fe3171f90f8e35bbe95530be5d6b98b70c5a99362e69d4a64615e40fbb9c8eb96a SHA512 2b2ab79b3d9f2c19967a16200cf69e7eba589d4d3d8918890b9504a5cb4895cd76000b6f3852baa738845e8508c6d67843f45d368225878d446ec6e907f75de4
+EBUILD gallium-nine-standalone-0_p20190113.ebuild 2883 BLAKE2B 228f96e4547f11e361ba4e91e397dd10b51b845a8c2ebe9d1b0c2192eeda707cf5ce64a6429b16ca6a7ede0ab87bf640b48fa1c6b2701decb508b6ddec6e8cea SHA512 1f0a69c12b618fa34d6f8b8d4db3f97b7fa9f5474aae367dc605767e5e3240966e233291e4d6bc224f2cde4475448649d62a0cd64f2f2ef029d62ae2183a03cf
+EBUILD gallium-nine-standalone-9999.ebuild 2843 BLAKE2B 6fe8899d0f247b3e4d61bdbdc2ea51af18062444b80e9182c1b46ec5459b8c7753e824e0d5e72b49a83ebed5b46b0fda1fb911690497e46e8f31fe9dcebfad64 SHA512 7b1bf2b0696612bd026ea81d2391b1503c5b44ac7b8e5e979b3754f258844eb0e98a2c486cce5f98632c18c104584c3b595b9883342d35e38c106c9599692d94
+MISC metadata.xml 759 BLAKE2B 926b6b0ea3893a2dad8506f19ecc42a6ba51086fe536aad0bc0db750a809c9e184ed5e0118f89edf8fdccf4f5efd163242ff2b5ce5384d400219022c163ec896 SHA512 ea74c7b0efd60b6c40a6d4b2c371dca663220c3d196fd942a9c896d1695f803cca02f3c9b4c427b2e4e894248229cb5869c7f567bebc8b88a2f6ae384db3ecd5
diff --git a/app-emulation/gallium-nine-standalone/files/flags.patch b/app-emulation/gallium-nine-standalone/files/flags.patch
new file mode 100644
index 000000000000..217dcddf35b9
--- /dev/null
+++ b/app-emulation/gallium-nine-standalone/files/flags.patch
@@ -0,0 +1,28 @@
+diff -Naur a/tools/cross-wine32.in b/tools/cross-wine32.in
+--- a/tools/cross-wine32.in 2019-01-12 16:45:09.190471883 +0000
++++ b/tools/cross-wine32.in 2019-01-12 16:48:22.569404982 +0000
+@@ -5,8 +5,8 @@
+ pkgconfig = '@PKG_CONFIG@'
+
+ [properties]
+-c_args = ['-m32', '--no-gnu-unique']
+-c_link_args = ['-m32', '-mwindows']
++c_args = @CFLAGS@ + ['-m32', '--no-gnu-unique']
++c_link_args = @LDFLAGS@ + ['-m32', '-mwindows']
+ needs_exe_wrapper = true
+
+ [host_machine]
+diff -Naur a/tools/cross-wine64.in b/tools/cross-wine64.in
+--- a/tools/cross-wine64.in 2019-01-12 16:45:09.190471883 +0000
++++ b/tools/cross-wine64.in 2019-01-12 16:48:19.865349306 +0000
+@@ -5,8 +5,8 @@
+ pkgconfig = '@PKG_CONFIG@'
+
+ [properties]
+-c_args = ['-m64', '--no-gnu-unique']
+-c_link_args = ['-m64', '-mwindows']
++c_args = @CFLAGS@ + ['-m64', '--no-gnu-unique']
++c_link_args = @LDFLAGS@ + ['-m64', '-mwindows']
+ needs_exe_wrapper = true
+
+ [host_machine]
diff --git a/app-emulation/gallium-nine-standalone/files/nine-dll-path.patch b/app-emulation/gallium-nine-standalone/files/nine-dll-path.patch
new file mode 100644
index 000000000000..9399dde3e4f6
--- /dev/null
+++ b/app-emulation/gallium-nine-standalone/files/nine-dll-path.patch
@@ -0,0 +1,12 @@
+diff -Naur a/ninewinecfg/main.c b/ninewinecfg/main.c
+--- a/ninewinecfg/main.c 2019-01-12 19:43:40.113737110 +0000
++++ b/ninewinecfg/main.c 2019-01-12 19:46:54.213703713 +0000
+@@ -47,7 +47,7 @@
+ #define WINE_STAGING 1
+ #endif
+
+-static const char * const fn_nine_dll = "d3d9-nine.dll";
++static const char * const fn_nine_dll = G9DLL;
+ static const char * const reg_path_dll_overrides = "Software\\Wine\\DllOverrides";
+ static const char * const reg_path_dll_redirects = "Software\\Wine\\DllRedirects";
+ static const char * const reg_key_d3d9 = "d3d9";
diff --git a/app-emulation/gallium-nine-standalone/gallium-nine-standalone-0_p20190113.ebuild b/app-emulation/gallium-nine-standalone/gallium-nine-standalone-0_p20190113.ebuild
new file mode 100644
index 000000000000..74e8ff9eb033
--- /dev/null
+++ b/app-emulation/gallium-nine-standalone/gallium-nine-standalone-0_p20190113.ebuild
@@ -0,0 +1,110 @@
+# Copyright 1999-2019 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+inherit meson multilib-minimal toolchain-funcs
+
+DESCRIPTION="A standalone version of the WINE parts of Gallium Nine"
+HOMEPAGE="https://github.com/dhewg/nine"
+
+if [[ $PV = 9999* ]]; then
+ inherit git-r3
+ EGIT_REPO_URI="https://github.com/dhewg/nine.git"
+else
+ COMMIT="e10dd1a770c91d5ff13343c9a0186665b7df6114"
+ SRC_URI="https://github.com/dhewg/nine/archive/${COMMIT}.tar.gz -> ${P}.tar.gz"
+ S="${WORKDIR}/nine-${COMMIT}"
+ KEYWORDS="-* ~amd64 ~x86"
+fi
+
+LICENSE="LGPL-2.1+"
+SLOT="0"
+
+# We don't put Wine in RDEPEND because you can also use this with
+# Steam's Proton.
+
+RDEPEND="
+ media-libs/mesa[d3d9,egl,${MULTILIB_USEDEP}]
+ x11-libs/libX11[${MULTILIB_USEDEP}]
+ x11-libs/libXext[${MULTILIB_USEDEP}]
+ x11-libs/libxcb[${MULTILIB_USEDEP}]
+"
+
+DEPEND="
+ ${RDEPEND}
+ virtual/pkgconfig[${MULTILIB_USEDEP}]
+ virtual/wine[${MULTILIB_USEDEP}]
+"
+
+PATCHES=(
+ "${FILESDIR}"/flags.patch
+ "${FILESDIR}"/nine-dll-path.patch
+)
+
+bits() {
+ if [[ ${ABI} = amd64 ]]; then
+ echo 64
+ else
+ echo 32
+ fi
+}
+
+src_prepare() {
+ default
+
+ # Upstream includes a bootstrap.sh script with hardcoded CHOSTs to
+ # create the Meson cross files. We improve on that here but also
+ # inject CFLAGS and LDFLAGS, partly to simply respect these, and
+ # partly to allow d3d9-nine.dll to be loaded from a location outside
+ # WINEPREFIX. This avoids the need for the nine-install.sh script,
+ # which doesn't play well with our multi-Wine environment.
+ bootstrap_nine() {
+ local file=tools/cross-wine$(bits)
+ local g9dll=Z:${EPREFIX//\//\\}\\usr\\$(get_libdir)\\d3d9-nine.dll.so
+
+ # Yes, these ridiculous backslashes are needed!
+ g9dll=\\\\\\\\\\\"${g9dll//\\/\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\}\\\\\\\\\\\"
+
+ sed \
+ -e "s!@PKG_CONFIG@!$(tc-getPKG_CONFIG)!" \
+ -e "s!@CFLAGS@!$(_meson_env_array "${CFLAGS} -DG9DLL=${g9dll}")!" \
+ -e "s!@LDFLAGS@!$(_meson_env_array "${LDFLAGS}")!" \
+ ${file}.in > ${file} || die
+ }
+
+ multilib_foreach_abi bootstrap_nine
+}
+
+multilib_src_configure() {
+ # We override bindir because otherwise the 32-bit exe is overwritten
+ # by the 64-bit exe and we need both of them.
+ local emesonargs=(
+ --cross-file "${S}/tools/cross-wine$(bits)"
+ --bindir "$(get_libdir)"
+ )
+ meson_src_configure
+}
+
+multilib_src_compile() {
+ meson_src_compile
+}
+
+multilib_src_install() {
+ meson_src_install
+}
+
+pkg_postinst() {
+ local bits=$(bits)
+
+ einfo "Don't remove the Z: drive from your WINEPREFIX as this relies on it."
+ einfo
+ einfo "To set up the ${bits}-bit library, launch your preferred Wine as follows:"
+ einfo " wine${bits/32} ${EPREFIX}/usr/$(get_libdir)/ninewinecfg.exe.so"
+
+ if use abi_x86_64 && use abi_x86_32; then
+ einfo
+ einfo "To set up the 32-bit library, launch your preferred Wine as follows:"
+ einfo " wine ${EPREFIX}/usr/$(ABI=x86 get_libdir)/ninewinecfg.exe.so"
+ fi
+}
diff --git a/app-emulation/gallium-nine-standalone/gallium-nine-standalone-9999.ebuild b/app-emulation/gallium-nine-standalone/gallium-nine-standalone-9999.ebuild
new file mode 100644
index 000000000000..0e73ee93be3c
--- /dev/null
+++ b/app-emulation/gallium-nine-standalone/gallium-nine-standalone-9999.ebuild
@@ -0,0 +1,110 @@
+# Copyright 1999-2019 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+inherit meson multilib-minimal toolchain-funcs
+
+DESCRIPTION="A standalone version of the WINE parts of Gallium Nine"
+HOMEPAGE="https://github.com/dhewg/nine"
+
+if [[ $PV = 9999* ]]; then
+ inherit git-r3
+ EGIT_REPO_URI="https://github.com/dhewg/nine.git"
+else
+ COMMIT=""
+ SRC_URI="https://github.com/dhewg/nine/archive/${COMMIT}.tar.gz -> ${P}.tar.gz"
+ S="${WORKDIR}/nine-${COMMIT}"
+ KEYWORDS="-* ~amd64 ~x86"
+fi
+
+LICENSE="LGPL-2.1+"
+SLOT="0"
+
+# We don't put Wine in RDEPEND because you can also use this with
+# Steam's Proton.
+
+RDEPEND="
+ media-libs/mesa[d3d9,egl,${MULTILIB_USEDEP}]
+ x11-libs/libX11[${MULTILIB_USEDEP}]
+ x11-libs/libXext[${MULTILIB_USEDEP}]
+ x11-libs/libxcb[${MULTILIB_USEDEP}]
+"
+
+DEPEND="
+ ${RDEPEND}
+ virtual/pkgconfig[${MULTILIB_USEDEP}]
+ virtual/wine[${MULTILIB_USEDEP}]
+"
+
+PATCHES=(
+ "${FILESDIR}"/flags.patch
+ "${FILESDIR}"/nine-dll-path.patch
+)
+
+bits() {
+ if [[ ${ABI} = amd64 ]]; then
+ echo 64
+ else
+ echo 32
+ fi
+}
+
+src_prepare() {
+ default
+
+ # Upstream includes a bootstrap.sh script with hardcoded CHOSTs to
+ # create the Meson cross files. We improve on that here but also
+ # inject CFLAGS and LDFLAGS, partly to simply respect these, and
+ # partly to allow d3d9-nine.dll to be loaded from a location outside
+ # WINEPREFIX. This avoids the need for the nine-install.sh script,
+ # which doesn't play well with our multi-Wine environment.
+ bootstrap_nine() {
+ local file=tools/cross-wine$(bits)
+ local g9dll=Z:${EPREFIX//\//\\}\\usr\\$(get_libdir)\\d3d9-nine.dll.so
+
+ # Yes, these ridiculous backslashes are needed!
+ g9dll=\\\\\\\\\\\"${g9dll//\\/\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\}\\\\\\\\\\\"
+
+ sed \
+ -e "s!@PKG_CONFIG@!$(tc-getPKG_CONFIG)!" \
+ -e "s!@CFLAGS@!$(_meson_env_array "${CFLAGS} -DG9DLL=${g9dll}")!" \
+ -e "s!@LDFLAGS@!$(_meson_env_array "${LDFLAGS}")!" \
+ ${file}.in > ${file} || die
+ }
+
+ multilib_foreach_abi bootstrap_nine
+}
+
+multilib_src_configure() {
+ # We override bindir because otherwise the 32-bit exe is overwritten
+ # by the 64-bit exe and we need both of them.
+ local emesonargs=(
+ --cross-file "${S}/tools/cross-wine$(bits)"
+ --bindir "$(get_libdir)"
+ )
+ meson_src_configure
+}
+
+multilib_src_compile() {
+ meson_src_compile
+}
+
+multilib_src_install() {
+ meson_src_install
+}
+
+pkg_postinst() {
+ local bits=$(bits)
+
+ einfo "Don't remove the Z: drive from your WINEPREFIX as this relies on it."
+ einfo
+ einfo "To set up the ${bits}-bit library, launch your preferred Wine as follows:"
+ einfo " wine${bits/32} ${EPREFIX}/usr/$(get_libdir)/ninewinecfg.exe.so"
+
+ if use abi_x86_64 && use abi_x86_32; then
+ einfo
+ einfo "To set up the 32-bit library, launch your preferred Wine as follows:"
+ einfo " wine ${EPREFIX}/usr/$(ABI=x86 get_libdir)/ninewinecfg.exe.so"
+ fi
+}
diff --git a/app-emulation/gallium-nine-standalone/metadata.xml b/app-emulation/gallium-nine-standalone/metadata.xml
new file mode 100644
index 000000000000..c661f33f58dd
--- /dev/null
+++ b/app-emulation/gallium-nine-standalone/metadata.xml
@@ -0,0 +1,20 @@
+<?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>
+ <maintainer type="project">
+ <email>wine@gentoo.org</email>
+ <name>Wine</name>
+ </maintainer>
+ <longdescription>
+Gallium Nine Standalone, as the name implies, is a standalone version of the WINE parts of Gallium Nine.
+
+This decouples Gallium Nine from the WINE tree, so that it can be used with any WINE version. There is no need for any WINE patches. A stable, development, or staging WINE release is sufficient.
+ </longdescription>
+ <upstream>
+ <remote-id type="github">dhewg/nine</remote-id>
+ </upstream>
+</pkgmetadata>