commit: d6568bd4c2730d27f91ccacd716ab00cd82b8fe0 Author: Azamat H. Hackimov <azamat.hackimov <AT> gmail <DOT> com> AuthorDate: Thu May 21 05:09:33 2020 +0000 Commit: Azamat H. Hackimov <winterheart <AT> gentoo <DOT> ru> CommitDate: Thu May 21 05:18:15 2020 +0000 URL: https://gitweb.gentoo.org/proj/gamerlay.git/commit/?id=d6568bd4
dev-games/netradiant: update Updated and simplified version of ebuild, based on xonotic works. Package-Manager: Portage-2.3.99, Repoman-2.3.22 Signed-off-by: Azamat H. Hackimov <azamat.hackimov <AT> gmail.com> ...adiant-1.5.0_p20200521_DBUILD_SHARED_LIBS.patch | 275 +++++++++++++++++++++ dev-games/netradiant/metadata.xml | 35 ++- .../netradiant/netradiant-1.5.0_p20120515.ebuild | 187 -------------- .../netradiant/netradiant-1.5.0_p20200521.ebuild | 73 ++++++ 4 files changed, 362 insertions(+), 208 deletions(-) diff --git a/dev-games/netradiant/files/netradiant-1.5.0_p20200521_DBUILD_SHARED_LIBS.patch b/dev-games/netradiant/files/netradiant-1.5.0_p20200521_DBUILD_SHARED_LIBS.patch new file mode 100644 index 0000000..d52024e --- /dev/null +++ b/dev-games/netradiant/files/netradiant-1.5.0_p20200521_DBUILD_SHARED_LIBS.patch @@ -0,0 +1,275 @@ +From bec73d0fa728f7162e879d8ebcd5ffa697c3a4b8 Mon Sep 17 00:00:00 2001 +From: "Azamat H. Hackimov" <azamat.hacki...@gmail.com> +Date: Thu, 21 May 2020 04:08:39 +0300 +Subject: [PATCH] Fixing compilation with -DBUILD_SHARED_LIBS=ON + +Libraries under libs should be forced STATIC since there circular +dependencies and implicit linking with external libraries. Otherwise +compilation will fails with underlinking errors. +--- + libs/cmdlib/CMakeLists.txt | 2 +- + libs/container/CMakeLists.txt | 2 +- + libs/crnrgba/CMakeLists.txt | 2 +- + libs/ddslib/CMakeLists.txt | 2 +- + libs/debugging/CMakeLists.txt | 2 +- + libs/etclib/CMakeLists.txt | 2 +- + libs/filematch/CMakeLists.txt | 2 +- + libs/generic/CMakeLists.txt | 2 +- + libs/gtkutil/CMakeLists.txt | 2 +- + libs/l_net/CMakeLists.txt | 2 +- + libs/math/CMakeLists.txt | 2 +- + libs/mathlib/CMakeLists.txt | 2 +- + libs/memory/CMakeLists.txt | 2 +- + libs/modulesystem/CMakeLists.txt | 2 +- + libs/os/CMakeLists.txt | 2 +- + libs/picomodel/CMakeLists.txt | 2 +- + libs/profile/CMakeLists.txt | 2 +- + libs/script/CMakeLists.txt | 2 +- + libs/signal/CMakeLists.txt | 2 +- + libs/splines/CMakeLists.txt | 2 +- + libs/stream/CMakeLists.txt | 2 +- + libs/string/CMakeLists.txt | 2 +- + libs/uilib/CMakeLists.txt | 2 +- + libs/xml/CMakeLists.txt | 2 +- + 24 files changed, 24 insertions(+), 24 deletions(-) + +diff --git a/libs/cmdlib/CMakeLists.txt b/libs/cmdlib/CMakeLists.txt +index 5d25ce82..b8c48b01 100644 +--- a/libs/cmdlib/CMakeLists.txt ++++ b/libs/cmdlib/CMakeLists.txt +@@ -1,3 +1,3 @@ +-add_library(cmdlib ++add_library(cmdlib STATIC + cmdlib.cpp ../cmdlib.h + ) +diff --git a/libs/container/CMakeLists.txt b/libs/container/CMakeLists.txt +index 00bfbb4a..028129ba 100644 +--- a/libs/container/CMakeLists.txt ++++ b/libs/container/CMakeLists.txt +@@ -1,4 +1,4 @@ +-add_library(container ++add_library(container STATIC + array.cpp array.h + cache.h + container.h +diff --git a/libs/crnrgba/CMakeLists.txt b/libs/crnrgba/CMakeLists.txt +index 6e8463dc..a5ec18e3 100644 +--- a/libs/crnrgba/CMakeLists.txt ++++ b/libs/crnrgba/CMakeLists.txt +@@ -1,4 +1,4 @@ +-add_library(crnrgba ++add_library(crnrgba STATIC + crn_rgba.h + crn_rgba.cpp + ../crunch/inc/crn_decomp.h +diff --git a/libs/ddslib/CMakeLists.txt b/libs/ddslib/CMakeLists.txt +index d4de1a7c..a45ccc7f 100644 +--- a/libs/ddslib/CMakeLists.txt ++++ b/libs/ddslib/CMakeLists.txt +@@ -1,3 +1,3 @@ +-add_library(ddslib ++add_library(ddslib STATIC + ddslib.c ../ddslib.h + ) +diff --git a/libs/debugging/CMakeLists.txt b/libs/debugging/CMakeLists.txt +index e5880de3..0b8f90d8 100644 +--- a/libs/debugging/CMakeLists.txt ++++ b/libs/debugging/CMakeLists.txt +@@ -1,3 +1,3 @@ +-add_library(debugging ++add_library(debugging STATIC + debugging.cpp debugging.h + ) +diff --git a/libs/etclib/CMakeLists.txt b/libs/etclib/CMakeLists.txt +index 8d8fb23a..68a12302 100644 +--- a/libs/etclib/CMakeLists.txt ++++ b/libs/etclib/CMakeLists.txt +@@ -1,3 +1,3 @@ +-add_library(etclib ++add_library(etclib STATIC + ../etclib.c ../etclib.h + ) +diff --git a/libs/filematch/CMakeLists.txt b/libs/filematch/CMakeLists.txt +index c7d8a9ed..fede3eb5 100644 +--- a/libs/filematch/CMakeLists.txt ++++ b/libs/filematch/CMakeLists.txt +@@ -1,3 +1,3 @@ +-add_library(filematch ++add_library(filematch STATIC + ../filematch.c ../filematch.h + ) +diff --git a/libs/generic/CMakeLists.txt b/libs/generic/CMakeLists.txt +index d89f5743..e05637ef 100644 +--- a/libs/generic/CMakeLists.txt ++++ b/libs/generic/CMakeLists.txt +@@ -1,4 +1,4 @@ +-add_library(generic ++add_library(generic STATIC + arrayrange.h + bitfield.h + callback.cpp callback.h +diff --git a/libs/gtkutil/CMakeLists.txt b/libs/gtkutil/CMakeLists.txt +index b62098c1..80eca88c 100644 +--- a/libs/gtkutil/CMakeLists.txt ++++ b/libs/gtkutil/CMakeLists.txt +@@ -1,4 +1,4 @@ +-add_library(gtkutil ++add_library(gtkutil STATIC + accelerator.cpp accelerator.h + button.cpp button.h + clipboard.cpp clipboard.h +diff --git a/libs/l_net/CMakeLists.txt b/libs/l_net/CMakeLists.txt +index a0a19a84..c4984b83 100644 +--- a/libs/l_net/CMakeLists.txt ++++ b/libs/l_net/CMakeLists.txt +@@ -7,7 +7,7 @@ else () + list(APPEND L_NETLIST l_net_berkley.c) + endif () + +-add_library(l_net ${L_NETLIST}) ++add_library(l_net STATIC ${L_NETLIST}) + + if (WIN32) + target_link_libraries(l_net PRIVATE ws2_32) +diff --git a/libs/math/CMakeLists.txt b/libs/math/CMakeLists.txt +index 6cfedbef..4dc8a8ce 100644 +--- a/libs/math/CMakeLists.txt ++++ b/libs/math/CMakeLists.txt +@@ -1,4 +1,4 @@ +-add_library(math ++add_library(math STATIC + _.cpp + aabb.h + curve.h +diff --git a/libs/mathlib/CMakeLists.txt b/libs/mathlib/CMakeLists.txt +index 5682a5e1..27b087a8 100644 +--- a/libs/mathlib/CMakeLists.txt ++++ b/libs/mathlib/CMakeLists.txt +@@ -1,4 +1,4 @@ +-add_library(mathlib ++add_library(mathlib STATIC + bbox.c + line.c + m4x4.c +diff --git a/libs/memory/CMakeLists.txt b/libs/memory/CMakeLists.txt +index 1c345734..bebfc22d 100644 +--- a/libs/memory/CMakeLists.txt ++++ b/libs/memory/CMakeLists.txt +@@ -1,3 +1,3 @@ +-add_library(memory ++add_library(memory STATIC + allocator.cpp allocator.h + ) +diff --git a/libs/modulesystem/CMakeLists.txt b/libs/modulesystem/CMakeLists.txt +index d27aa633..489ee4a5 100644 +--- a/libs/modulesystem/CMakeLists.txt ++++ b/libs/modulesystem/CMakeLists.txt +@@ -1,4 +1,4 @@ +-add_library(modulesystem ++add_library(modulesystem STATIC + moduleregistry.h + modulesmap.h + singletonmodule.cpp singletonmodule.h +diff --git a/libs/os/CMakeLists.txt b/libs/os/CMakeLists.txt +index 437b506c..a1e47599 100644 +--- a/libs/os/CMakeLists.txt ++++ b/libs/os/CMakeLists.txt +@@ -1,4 +1,4 @@ +-add_library(os ++add_library(os STATIC + _.cpp + dir.h + file.h +diff --git a/libs/picomodel/CMakeLists.txt b/libs/picomodel/CMakeLists.txt +index 0f1286d0..4800fb46 100644 +--- a/libs/picomodel/CMakeLists.txt ++++ b/libs/picomodel/CMakeLists.txt +@@ -1,4 +1,4 @@ +-add_library(picomodel ++add_library(picomodel STATIC + lwo/clip.c + lwo/envelope.c + lwo/list.c +diff --git a/libs/profile/CMakeLists.txt b/libs/profile/CMakeLists.txt +index e3822f42..745238f3 100644 +--- a/libs/profile/CMakeLists.txt ++++ b/libs/profile/CMakeLists.txt +@@ -1,4 +1,4 @@ +-add_library(profile ++add_library(profile STATIC + file.cpp file.h + profile.cpp profile.h + ) +diff --git a/libs/script/CMakeLists.txt b/libs/script/CMakeLists.txt +index 6e49527d..0adfd124 100644 +--- a/libs/script/CMakeLists.txt ++++ b/libs/script/CMakeLists.txt +@@ -1,4 +1,4 @@ +-add_library(script ++add_library(script STATIC + _.cpp + scripttokeniser.h + scripttokenwriter.h +diff --git a/libs/signal/CMakeLists.txt b/libs/signal/CMakeLists.txt +index 499a4838..026c7249 100644 +--- a/libs/signal/CMakeLists.txt ++++ b/libs/signal/CMakeLists.txt +@@ -1,4 +1,4 @@ +-add_library(signal ++add_library(signal STATIC + isignal.h + signal.cpp signal.h + signalfwd.h +diff --git a/libs/splines/CMakeLists.txt b/libs/splines/CMakeLists.txt +index 3a6b603d..d301f272 100644 +--- a/libs/splines/CMakeLists.txt ++++ b/libs/splines/CMakeLists.txt +@@ -1,4 +1,4 @@ +-add_library(splines ++add_library(splines STATIC + math_angles.cpp math_angles.h + math_matrix.cpp math_matrix.h + math_quaternion.cpp math_quaternion.h +diff --git a/libs/stream/CMakeLists.txt b/libs/stream/CMakeLists.txt +index 6ce79395..ec1c9ae9 100644 +--- a/libs/stream/CMakeLists.txt ++++ b/libs/stream/CMakeLists.txt +@@ -1,4 +1,4 @@ +-add_library(stream ++add_library(stream STATIC + _.cpp + filestream.h + memstream.h +diff --git a/libs/string/CMakeLists.txt b/libs/string/CMakeLists.txt +index 4b0720a5..a9c2f471 100644 +--- a/libs/string/CMakeLists.txt ++++ b/libs/string/CMakeLists.txt +@@ -1,4 +1,4 @@ +-add_library(string ++add_library(string STATIC + pooledstring.cpp pooledstring.h + string.h + stringfwd.h +diff --git a/libs/uilib/CMakeLists.txt b/libs/uilib/CMakeLists.txt +index 080376b1..cfa95758 100644 +--- a/libs/uilib/CMakeLists.txt ++++ b/libs/uilib/CMakeLists.txt +@@ -1,4 +1,4 @@ +-add_library(uilib ++add_library(uilib STATIC + uilib.cpp + ) + +diff --git a/libs/xml/CMakeLists.txt b/libs/xml/CMakeLists.txt +index 96e1e216..cd0b040a 100644 +--- a/libs/xml/CMakeLists.txt ++++ b/libs/xml/CMakeLists.txt +@@ -1,4 +1,4 @@ +-add_library(xmllib ++add_library(xmllib STATIC + ixml.h + xmlelement.h + xmlparser.h +-- +2.26.2 + diff --git a/dev-games/netradiant/metadata.xml b/dev-games/netradiant/metadata.xml index 2354e25..fcf1f88 100644 --- a/dev-games/netradiant/metadata.xml +++ b/dev-games/netradiant/metadata.xml @@ -1,25 +1,18 @@ <?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> <pkgmetadata> - <maintainer type="person"> - <email>nik...@lavabit.com</email> - <name>Nikoli</name> - </maintainer> - <use> - <flag name='h2data'>Install h2data tool</flag> - <flag name='q2map'>Install q2map tool</flag> - <flag name='q3data'>Install q3data tool</flag> - <flag name='q3map2'>Install q3map2 tool</flag> - <flag name='qdata3'>Install qdata3 tool</flag> - <flag name='darkplaces'>Install DarkPlaces pack</flag> - <flag name='nexuiz'>Install Nexuiz pack</flag> - <flag name='openarena'>Install OpenArena non GPL pack</flag> - <flag name='osirion'>Install Osirion pack</flag> - <flag name='quake1'>Install Quake non GPL pack</flag> - <flag name='quake2'>Install Quake2 non GPL pack</flag> - <flag name='quake2world'>Install Quake2World pack</flag> - <flag name='tremulous'>Install Tremulous non GPL pack</flag> - <flag name='warsow'>Install Warsow pack</flag> - <flag name='xonotic'>Install Xonotic pack</flag> - </use> + <maintainer type="person"> + <email>nik...@lavabit.com</email> + <name>Nikoli</name> + </maintainer> + <maintainer type="person"> + <email>azamat.hacki...@gmail.com</email> + <name>Azamat H. Hackimov</name> + </maintainer> + <use> + <flag name="tools">Install additional tools</flag> + </use> + <upstream> + <remote-id type="gitlab">xonotic/netradiant</remote-id> + </upstream> </pkgmetadata> diff --git a/dev-games/netradiant/netradiant-1.5.0_p20120515.ebuild b/dev-games/netradiant/netradiant-1.5.0_p20120515.ebuild deleted file mode 100644 index 94d841c..0000000 --- a/dev-games/netradiant/netradiant-1.5.0_p20120515.ebuild +++ /dev/null @@ -1,187 +0,0 @@ -# Copyright 1999-2018 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI=4 - -inherit eutils multilib toolchain-funcs - -RADIANT_MAJOR_VERSION="5" -RADIANT_MINOR_VERSION="0" -DESCRIPTION="NetRadiant is a fork of map editor for Q3 based games, GtkRadiant 1.5" -HOMEPAGE="http://dev.alientrap.org/projects/netradiant" -BASE_ZIP_URI="http://ingar.satgnu.net/files/gtkradiant/gamepacks/" -SRC_URI="http://rion-overlay.googlecode.com/files/${P}.tar.xz - osirion? ( ${BASE_ZIP_URI}/OsirionPack.zip ) - quake1? ( ${BASE_ZIP_URI}/Quake1Pack.zip ) - warsow? ( ${BASE_ZIP_URI}/WarsowPack.zip ) - !bindist? ( - openarena? ( ${BASE_ZIP_URI}/OpenArenaPack.zip ) - quake2? ( ${BASE_ZIP_URI}/Quake2Pack.zip ) - tremulous? ( ${BASE_ZIP_URI}/TremulousPack.zip ) - ) -" - -LICENSE="GPL-2" -SLOT="0" -KEYWORDS="~amd64 ~x86" -RADIANT_GPL_PACKS="darkplaces nexuiz osirion quake2world warsow +xonotic" -RADIANT_NONGPL_PACKS="openarena quake1 quake2 tremulous" -RADIANT_TOOLS="h2data q2map q3data q3map2 qdata3" -RADIANT_PACKS="${RADIANT_GPL_PACKS} ${RADIANT_NONGPL_PACKS}" -RADIANT_BINS=" ${RADIANT_TOOLS} gtk" -IUSE="${RADIANT_PACKS} ${RADIANT_BINS// / +} bindist" - -RDEPEND=" - dev-libs/glib:2 - dev-libs/libxml2 - >=media-libs/libpng-1.2 - >=sys-libs/zlib-1.2 - gtk? ( - >=x11-libs/gtk+-2.4:2 - >=x11-libs/gtkglext-1 - x11-libs/pango - ) - !dev-games/gtkradiant -" -DEPEND="${RDEPEND} - app-arch/xz-utils - dev-vcs/subversion - virtual/pkgconfig - osirion? ( app-arch/unzip ) - quake1? ( app-arch/unzip ) - warsow? ( app-arch/unzip ) - !bindist? ( - openarena? ( app-arch/unzip ) - quake2? ( app-arch/unzip ) - tremulous? ( app-arch/unzip ) - ) -" - -radiant_zip_unpack() { - if use ${1,,}; then - cd "${WORKDIR}/packs/" || die - unpack "${1}Pack.zip" - mv ${1}Pack ${1,,} || die - fi -} - -pkg_setup() { - targets="" - for i in ${RADIANT_BINS};do - if use $i; then - targets+=" ${i/gtk/radiant}" - fi - done - if [ "x$targets" = "x" ]; then - targets=" q3map2" - ewarn "You disabled all binaries: defaulting to USE=\"q3map2\"" - fi -} - -src_unpack() { - unpack ${P}.tar.xz - - if use gtk; then - radiant_zip_unpack Osirion - radiant_zip_unpack Quake1 - radiant_zip_unpack Warsow - - if use !bindist; then - MY_RADIANT_PACKS="${RADIANT_GPL_PACKS//+/} ${RADIANT_NONGPL_PACKS}" - radiant_zip_unpack OpenArena - radiant_zip_unpack Quake2 - radiant_zip_unpack Tremulous - else - MY_RADIANT_PACKS="${RADIANT_GPL_PACKS//+/}" - for i in ${RADIANT_NONGPL_PACKS}; do - if use ${i}; then - ewarn "USE bindist disables ${i} non GPL pack" - fi - done - fi - fi -} - -src_prepare() { - sed -e '/$(INSTALLDIR)/s,heretic2/h2data,/h2data,' \ - -i Makefile || die -} - -src_configure() { - tc-export CC CXX AR RANLIB - - export TEE_STDERR="" - - # dependencies-check wants gtk - if use gtk; then - emake dependencies-check - fi -} - -src_compile() { - emake ${targets// / binaries-} -} - -src_install() { - insinto /usr/$(get_libdir)/${PN} - doins \ - setup/data/tools/q3data.qdt - - dodoc ChangeLog ChangeLog.idsoftware CONTRIBUTORS tools/quake3/q3map2/changelog.q3map{1,2.txt} - - pushd install || die - exeinto /usr/$(get_libdir)/${PN} - for i in ${targets}; do - doexe ${i}.x86 - dosym /usr/$(get_libdir)/${PN}/${i}.x86 /usr/bin/${i} - done - - # radiant - if use gtk; then - dosym /usr/$(get_libdir)/${PN}/radiant.x86 /usr/bin/${PN} - - newicon "${S}"/icons/radiant-src.png ${PN}.png - make_desktop_entry ${PN} NetRadiant ${PN} "Development;GTK;" - - # modules - insinto /usr/$(get_libdir)/${PN}/modules - doins modules/*.so - - # plugins - insinto /usr/$(get_libdir)/${PN}/plugins - doins plugins/*.so - - # data - popd || die - echo "$RADIANT_MINOR_VERSION" > RADIANT_MINOR || die - echo "$RADIANT_MAJOR_VERSION" > RADIANT_MAJOR || die - insinto /usr/$(get_libdir)/${PN} - doins -r \ - RADIANT_MAJOR \ - RADIANT_MINOR \ - setup/data/tools/bitmaps \ - setup/data/tools/gl \ - setup/data/tools/global.xlink \ - setup/data/tools/plugins \ - docs - - # packs - for x in ${MY_RADIANT_PACKS//+/}; do - if use $x; then - cd "${WORKDIR}"/packs/${x} || die - # USE and dir names differ - n="$(echo $x | sed \ - -e 's/^quake/q/' \ - -e 's/2world$/2w/' \ - -e 's/^openarena/oa/' \ - -e 's/^tremulous/trem/' \ - )" - insinto /usr/$(get_libdir)/${PN} - doins -r ${n}.game - - insinto /usr/$(get_libdir)/${PN}/games - doins games/${n}.game - fi - done - fi -} diff --git a/dev-games/netradiant/netradiant-1.5.0_p20200521.ebuild b/dev-games/netradiant/netradiant-1.5.0_p20200521.ebuild new file mode 100644 index 0000000..fd3045c --- /dev/null +++ b/dev-games/netradiant/netradiant-1.5.0_p20200521.ebuild @@ -0,0 +1,73 @@ +# Copyright 1999-2020 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 + +inherit cmake + +GIT_TAG="458a91b4539ea68ae6a02f5ad93c6fbc93a725a0" + +DESCRIPTION="NetRadiant is a fork of map editor for Q3 based games, GtkRadiant 1.5" +HOMEPAGE="https://netradiant.gitlab.io/" +BASE_ZIP_URI="http://ingar.intranifty.net/files/netradiant/gamepacks/" +SRC_URI="https://gitlab.com/xonotic/netradiant/-/archive/${GIT_TAG}/netradiant-${GIT_TAG}.tar.bz2 -> ${P}.tar.bz2" + +LICENSE="GPL-2" +SLOT="0" +KEYWORDS="~amd64 ~x86" + +IUSE="+gui tools" +REQUIRED_USE="|| ( gui tools )" + +RDEPEND=" + gui? ( + dev-games/netradiant-gamepacks + x11-libs/gtk+:2 + x11-libs/gtkglext + x11-libs/pango + ) + dev-libs/glib + dev-libs/libxml2 + media-libs/libpng:= + media-libs/libwebp:= + sys-libs/zlib:=[minizip] + virtual/jpeg + virtual/opengl +" + +DEPEND="${RDEPEND} + virtual/pkgconfig + " + +S="${WORKDIR}/${PN}-${GIT_TAG}" + +PATCHES=( + "${FILESDIR}/${P}_DBUILD_SHARED_LIBS.patch" +) + +src_configure() { + local mycmakeargs=( + -DBUILD_RADIANT=$(usex gui) + -DBUILD_TOOLS=$(usex tools) + -DBUILD_DAEMONMAP=OFF + -DBUILD_CRUNCH=OFF + -DBUNDLE_LIBRARIES=OFF + -DDOWNLOAD_GAMEPACKS=OFF + -DFHS_INSTALL=ON + ) + cmake_src_configure +} + +src_install() { + cmake_src_install +} + +pkg_postinst() { + xdg_desktop_database_update + xdg_mimeinfo_database_update +} + +pkg_postrm() { + xdg_desktop_database_update + xdg_mimeinfo_database_update +}