commit:     df34395764ddccaa2fe8454d739802be4aa3c0c4
Author:     William Breathitt Gray <vilhelm.gray <AT> gmail <DOT> com>
AuthorDate: Sat Oct 23 01:38:14 2021 +0000
Commit:     James Le Cuirot <chewi <AT> gentoo <DOT> org>
CommitDate: Sat Oct 23 07:34:44 2021 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=df343957

games-fps/gzdoom: Version bump to 4.7.1

Closes: https://bugs.gentoo.org/815274
Signed-off-by: William Breathitt Gray <vilhelm.gray <AT> gmail.com>
Signed-off-by: James Le Cuirot <chewi <AT> gentoo.org>

 games-fps/gzdoom/Manifest                          |  1 +
 ...-4.7.1-Introduce-the-BUILD_NONFREE-option.patch | 36 ++++++++++
 games-fps/gzdoom/gzdoom-4.7.1.ebuild               | 82 ++++++++++++++++++++++
 3 files changed, 119 insertions(+)

diff --git a/games-fps/gzdoom/Manifest b/games-fps/gzdoom/Manifest
index 830e1f26f61..0cb8608c746 100644
--- a/games-fps/gzdoom/Manifest
+++ b/games-fps/gzdoom/Manifest
@@ -1,3 +1,4 @@
 DIST gzdoom-4.6.1.tar.gz 13937864 BLAKE2B 
59ea057b42058944566a66c21f441752bd014235ac4644f9b50182673856fedc33414cbe12505a294842e46c93faaf120d844ccd49fb9afeede67640feab3764
 SHA512 
cec64f4f6a3be3693b35d716a44930cfa9fd10b794b380cf0ea624e7901f78f3e5211b17a0905b65de367fa62046cd6ebd099f5300c7f49e1c020faaae15dd41
 DIST gzdoom-4.7.0.tar.gz 14070204 BLAKE2B 
4cf0555e7d1e34f71057502bce0973d49ffca6bccd2396faee6360832511b90450008c4ec22a0cdadfa3edcd13ec73bf412c0af7c6298c560c087f8a3d5f0bdb
 SHA512 
539d1de85b3e2313e57fc8fcb0fa4b7a5110107f5436ee3412342c1140cebbe4ccec45efa3211b43aba8bc3715ce0e7819dd593f55d8ee906f2382573435361f
+DIST gzdoom-4.7.1.tar.gz 19562412 BLAKE2B 
48b089c9d0ca0f26820ea90ea1a1a6ce3fa325f6f7bd36ded66ba43eeaab610ca99eacb1ca0aec75b0888a65108573e2c85d2ce0e88663031583267f1143386e
 SHA512 
040a51d2783616cca9f3d7e70bf83adf0d6afa8d7378a9f743cbf152811c07c4f03eecdbbdb617d9fda625049a6f13313dce6e5017698bf36fae74e107c012f0
 DIST widepix-d458411.tar.gz 2542783 BLAKE2B 
622355d61c102cf71f724ed709b80ba6ba652905fb806bfd6dad6a0944eabd3bac71c7fdad17354af17493f64d6418e93eef37c032e85615dffa27f9e8faa97f
 SHA512 
fe8a243e2dbe6330121bf139e310baf677ec4803d6b0ecd24a93792a2f7071ba739b1c038ca7aa7eeafcc83bf57c8a009189a90e3115305967ba23b675c96543

diff --git 
a/games-fps/gzdoom/files/gzdoom-4.7.1-Introduce-the-BUILD_NONFREE-option.patch 
b/games-fps/gzdoom/files/gzdoom-4.7.1-Introduce-the-BUILD_NONFREE-option.patch
new file mode 100644
index 00000000000..9e012a25307
--- /dev/null
+++ 
b/games-fps/gzdoom/files/gzdoom-4.7.1-Introduce-the-BUILD_NONFREE-option.patch
@@ -0,0 +1,36 @@
+From d164cfcde29980c23ece15f0be1b09dac5853843 Mon Sep 17 00:00:00 2001
+From: William Breathitt Gray <[email protected]>
+Date: Sat, 31 Aug 2019 21:23:23 +0900
+Subject: [PATCH] Introduce the BUILD_NONFREE option
+
+This allow users to disable building nonfree components (brightmaps.pk3,
+game_support.pk3, and game_widescreen_gfx.pk3) if they so desire.
+---
+ CMakeLists.txt | 9 ++++++---
+ 1 file changed, 6 insertions(+), 3 deletions(-)
+
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index 9013d8921..77bd703b1 100644
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -411,11 +411,14 @@ add_subdirectory( libraries/lzma )
+ add_subdirectory( tools )
+ add_subdirectory( libraries/gdtoa )
+ add_subdirectory( wadsrc )
+-add_subdirectory( wadsrc_bm )
+ add_subdirectory( wadsrc_lights )
+-add_subdirectory( wadsrc_extra )
+-add_subdirectory( wadsrc_widepix )
+ add_subdirectory( src )
++option (BUILD_NONFREE "Build nonfree components" ON)
++if( BUILD_NONFREE )
++       add_subdirectory( wadsrc_bm )
++       add_subdirectory( wadsrc_extra )
++       add_subdirectory( wadsrc_widepix )
++endif()
+ 
+ if( NOT CMAKE_CROSSCOMPILING )
+       export(TARGETS ${CROSS_EXPORTS} FILE 
"${CMAKE_BINARY_DIR}/ImportExecutables.cmake" )
+-- 
+2.33.1
+

diff --git a/games-fps/gzdoom/gzdoom-4.7.1.ebuild 
b/games-fps/gzdoom/gzdoom-4.7.1.ebuild
new file mode 100644
index 00000000000..d0da35c22a2
--- /dev/null
+++ b/games-fps/gzdoom/gzdoom-4.7.1.ebuild
@@ -0,0 +1,82 @@
+# Copyright 1999-2021 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+inherit cmake desktop xdg flag-o-matic
+
+DESCRIPTION="A modder-friendly OpenGL source port based on the DOOM engine"
+HOMEPAGE="https://zdoom.org";
+SRC_URI="https://github.com/coelckers/${PN}/archive/g${PV}.tar.gz -> 
${P}.tar.gz"
+
+LICENSE="Apache-2.0 BSD BZIP2 GPL-3 LGPL-2.1+ LGPL-3 MIT
+       non-free? ( Activision ChexQuest3 DOOM-COLLECTORS-EDITION freedist 
WidePix )"
+SLOT="0"
+KEYWORDS="~amd64 ~arm ~x86"
+IUSE="debug gles2 gtk +non-free openmp telemetry vulkan"
+
+DEPEND="
+       app-arch/bzip2
+       media-libs/libsdl2[gles2?,opengl,vulkan?]
+       media-libs/openal
+       media-libs/zmusic
+       sys-libs/zlib
+       virtual/jpeg:0
+       gtk? ( x11-libs/gtk+:3 )"
+RDEPEND="${DEPEND}"
+
+S="${WORKDIR}/${PN}-g${PV}"
+
+PATCHES=(
+       "${FILESDIR}/${P}-Introduce-the-BUILD_NONFREE-option.patch"
+)
+
+src_prepare() {
+       rm -rf docs/licenses || die
+       rm -rf libraries/{bzip2,jpeg,zlib} || die
+       if ! use non-free ; then
+               rm -rf wadsrc_bm wadsrc_extra wadsrc_widepix || die
+       fi
+
+       cmake_src_prepare
+}
+
+src_configure() {
+       local mycmakeargs=(
+               -DINSTALL_DOCS_PATH="${EPREFIX}/usr/share/doc/${PF}"
+               -DINSTALL_PK3_PATH="${EPREFIX}/usr/share/doom"
+               -DINSTALL_SOUNDFONT_PATH="${EPREFIX}/usr/share/doom"
+               -DDYN_OPENAL=OFF
+               -DNO_GTK="$(usex !gtk)"
+               -DNO_OPENAL=OFF
+               -DHAVE_VULKAN="$(usex vulkan)"
+               -DHAVE_GLES2="$(usex gles2)"
+               -DNO_OPENMP="$(usex !openmp)"
+               -DBUILD_NONFREE="$(usex non-free)"
+       )
+
+       use debug || append-cppflags -DNDEBUG
+       use telemetry || append-cppflags -DNO_SEND_STATS
+
+       cmake_src_configure
+}
+
+src_install() {
+       newicon src/posix/zdoom.xpm "${PN}.xpm"
+       make_desktop_entry "${PN}" "GZDoom" "${PN}" "Game;ActionGame"
+       cmake_src_install
+}
+
+pkg_postinst() {
+       xdg_pkg_postinst
+
+       if ! use non-free ; then
+               ewarn
+               ewarn "GZDoom installed without non-free components."
+               ewarn "Note: The non-free game_support.pk3 file is needed to 
play"
+               ewarn "      games natively supported by GZDoom."
+               ewarn "A list of games natively supported by GZDoom is 
available"
+               ewarn "on the ZDoom wiki: https://zdoom.org/wiki/IWAD";
+               ewarn
+       fi
+}

Reply via email to