From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by finch.gentoo.org (Postfix) with ESMTPS id 1D61015808B for ; Sat, 16 Apr 2022 08:09:35 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 6B923E097C; Sat, 16 Apr 2022 08:09:34 +0000 (UTC) Received: from smtp.gentoo.org (woodpecker.gentoo.org [140.211.166.183]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id 1B9FFE097C for ; Sat, 16 Apr 2022 08:09:34 +0000 (UTC) Received: from oystercatcher.gentoo.org (oystercatcher.gentoo.org [148.251.78.52]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id DF76B34217A for ; Sat, 16 Apr 2022 08:09:32 +0000 (UTC) Received: from localhost.localdomain (localhost [IPv6:::1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id 312CD1BF for ; Sat, 16 Apr 2022 08:09:31 +0000 (UTC) From: "James Le Cuirot" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "James Le Cuirot" Message-ID: <1650096513.da2f9eba4f975c62d061491987f6616e24b53ac5.chewi@gentoo> Subject: [gentoo-commits] repo/gentoo:master commit in: games-util/slade/, games-util/slade/files/ X-VCS-Repository: repo/gentoo X-VCS-Files: games-util/slade/Manifest games-util/slade/files/slade-3.2.0-bundled-libs.patch games-util/slade/files/slade-3.2.0-wx3.0.patch games-util/slade/slade-3.2.0.ebuild X-VCS-Directories: games-util/slade/files/ games-util/slade/ X-VCS-Committer: chewi X-VCS-Committer-Name: James Le Cuirot X-VCS-Revision: da2f9eba4f975c62d061491987f6616e24b53ac5 X-VCS-Branch: master Date: Sat, 16 Apr 2022 08:09:31 +0000 (UTC) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org X-Auto-Response-Suppress: DR, RN, NRN, OOF, AutoReply X-Archives-Salt: 53c305ca-46a0-4011-88fa-8904d46ac0a8 X-Archives-Hash: 3cc630e9d8083cedafb730e4de0a8553 commit: da2f9eba4f975c62d061491987f6616e24b53ac5 Author: James Le Cuirot gentoo org> AuthorDate: Sat Apr 16 08:08:33 2022 +0000 Commit: James Le Cuirot gentoo org> CommitDate: Sat Apr 16 08:08:33 2022 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=da2f9eba games-util/slade: Version bump to 3.2.0, EAPI 8 Closes: https://bugs.gentoo.org/838124 Signed-off-by: James Le Cuirot gentoo.org> games-util/slade/Manifest | 1 + .../slade/files/slade-3.2.0-bundled-libs.patch | 84 ++++++++++++++++++++++ games-util/slade/files/slade-3.2.0-wx3.0.patch | 66 +++++++++++++++++ games-util/slade/slade-3.2.0.ebuild | 78 ++++++++++++++++++++ 4 files changed, 229 insertions(+) diff --git a/games-util/slade/Manifest b/games-util/slade/Manifest index 2ca180f19853..2349b328e65a 100644 --- a/games-util/slade/Manifest +++ b/games-util/slade/Manifest @@ -1 +1,2 @@ +DIST slade-3.2.0.tar.gz 6464839 BLAKE2B 8e13f153c64526784bd5fa3d03520942d9dbc1b0b0d1e4d0650fb91ed63a7f860655f5d580b4c0a04a52aa98f617b1f4448f47cd1e55c1b3f78fc552b8101654 SHA512 916be3b9556e76ca815514bb472335af80a72bfb8ecd0ae4287db2c0d6ad092a8ada1b335762f8589d300b1fd81adbdede3e6c315cfdc1d49b1624294b405b92 DIST slade-3.2.0_beta2.tar.gz 5999580 BLAKE2B 29cd515e4553fa1d74a43dc982b376b10d95ebbe2da4a25bc39329c15967466142c73ec134ada371b9aa65d8fc8d9f4a1820cece7fe8dca59fec039aaad32331 SHA512 e46d9664348233c7ee7fa8ed748d7e23914bb1bb6dd65d40aff7603b386e032e988e0990d4a435f597ba8a6416c7ec377c8334a66efacd55ebdd994d3fd11073 diff --git a/games-util/slade/files/slade-3.2.0-bundled-libs.patch b/games-util/slade/files/slade-3.2.0-bundled-libs.patch new file mode 100644 index 000000000000..c4eae37f945f --- /dev/null +++ b/games-util/slade/files/slade-3.2.0-bundled-libs.patch @@ -0,0 +1,84 @@ +From 5ecc80d27276ba978b8c0268aab722fe8f09b394 Mon Sep 17 00:00:00 2001 +From: James Le Cuirot +Date: Sat, 20 Feb 2021 12:22:24 +0000 +Subject: [PATCH] Unbundle the DUMB library + +--- + src/Application/App.cpp | 2 +- + src/Audio/ModMusic.cpp | 2 +- + src/CMakeLists.txt | 4 +++- + thirdparty/CMakeLists.txt | 1 - + 4 files changed, 5 insertions(+), 4 deletions(-) + +diff --git a/src/Application/App.cpp b/src/Application/App.cpp +index 936a8212..2960ca1d 100644 +--- a/src/Application/App.cpp ++++ b/src/Application/App.cpp +@@ -60,7 +60,7 @@ + #include "UI/WxUtils.h" + #include "Utility/StringUtils.h" + #include "Utility/Tokenizer.h" +-#include "thirdparty/dumb/dumb.h" ++#include + #include + + using namespace slade; +diff --git a/src/Audio/ModMusic.cpp b/src/Audio/ModMusic.cpp +index cc4b60cf..6d54516d 100644 +--- a/src/Audio/ModMusic.cpp ++++ b/src/Audio/ModMusic.cpp +@@ -32,7 +32,7 @@ + // ----------------------------------------------------------------------------- + #include "Main.h" + #include "ModMusic.h" +-#include "thirdparty/dumb/dumb.h" ++#include + + using namespace slade; + using namespace audio; +diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt +index fef3d009..5363802c 100644 +--- a/src/CMakeLists.txt ++++ b/src/CMakeLists.txt +@@ -107,6 +107,7 @@ if (NOT NO_LUA) + find_package(Lua REQUIRED) + endif() + find_package(MPG123 REQUIRED) ++pkg_check_modules(DUMB REQUIRED dumb>=1.0) + include_directories( + ${FREEIMAGE_INCLUDE_DIR} + ${SFML_INCLUDE_DIR} +@@ -114,9 +115,9 @@ include_directories( + ${FTGL_INCLUDE_DIR} + ${LUA_INCLUDE_DIR} + ${MPG123_INCLUDE_DIR} ++ ${DUMB_INCLUDE_DIRS} + . + .. +- ../thirdparty/dumb + ../thirdparty/glad/include + ./Application + ) +@@ -201,6 +202,7 @@ target_link_libraries(slade + ${OPENGL_LIBRARIES} + ${LUA_LIBRARIES} + ${MPG123_LIBRARIES} ++ ${DUMB_LIBRARIES} + ) + + if(LINUX) +diff --git a/thirdparty/CMakeLists.txt b/thirdparty/CMakeLists.txt +index f84cfc8a..2622852b 100644 +--- a/thirdparty/CMakeLists.txt ++++ b/thirdparty/CMakeLists.txt +@@ -10,7 +10,6 @@ set(BZIP2_LIBRARIES ${BZIP2_LIBRARIES} PARENT_SCOPE) + set(EXTERNAL_SOURCES + ) + file(GLOB_RECURSE EXTERNAL_SOURCES +- dumb/*.c + lzma/C/LzmaDec.c + mus2mid/mus2mid.cpp + zreaders/*.cpp +-- +2.34.1 + diff --git a/games-util/slade/files/slade-3.2.0-wx3.0.patch b/games-util/slade/files/slade-3.2.0-wx3.0.patch new file mode 100644 index 000000000000..2e519b45181b --- /dev/null +++ b/games-util/slade/files/slade-3.2.0-wx3.0.patch @@ -0,0 +1,66 @@ +From 45537095187cb5b985713e7558a230651b599589 Mon Sep 17 00:00:00 2001 +From: Simon Judd +Date: Thu, 14 Apr 2022 21:52:16 -0700 +Subject: [PATCH] Keep up wx3.0 compatibility + +I'd like to drop it ideally, but for now it'll stay + +Fix #1336 +--- + src/Graphics/Icons.cpp | 15 +++++++++++++++ + src/UI/SAuiTabArt.cpp | 5 ++++- + 2 files changed, 19 insertions(+), 1 deletion(-) + +diff --git a/src/Graphics/Icons.cpp b/src/Graphics/Icons.cpp +index 61d5475c..67147f7e 100644 +--- a/src/Graphics/Icons.cpp ++++ b/src/Graphics/Icons.cpp +@@ -373,7 +373,22 @@ wxBitmap loadPNGIcon(const IconDef& icon, int size, Point2i padding) + bool icons::loadIcons() + { + // Check for dark mode ++#if wxMAJOR_VERSION >= 3 && wxMINOR_VERSION >= 1 + ui_icons_dark = wxSystemSettings::GetAppearance().IsDark(); ++#else ++ auto fg = wxSystemSettings::GetColour(wxSYS_COLOUR_WINDOWTEXT); ++ auto fg_r = fg.Red(); ++ auto fg_g = fg.Green(); ++ auto fg_b = fg.Blue(); ++ auto bg = wxSystemSettings::GetColour(wxSYS_COLOUR_WINDOW); ++ auto bg_r = bg.Red(); ++ auto bg_g = bg.Green(); ++ auto bg_b = bg.Blue(); ++ wxColour::MakeGrey(&fg_r, &fg_g, &fg_b); ++ wxColour::MakeGrey(&bg_r, &bg_g, &bg_b); ++ log::info("DARK MODE CHECK: FG {} BG {}", fg_r, bg_r); ++ ui_icons_dark = fg_r > bg_r; ++#endif + + // Get slade.pk3 + auto* res_archive = app::archiveManager().programResourceArchive(); +diff --git a/src/UI/SAuiTabArt.cpp b/src/UI/SAuiTabArt.cpp +index 15aad09e..240de8b9 100644 +--- a/src/UI/SAuiTabArt.cpp ++++ b/src/UI/SAuiTabArt.cpp +@@ -542,6 +542,7 @@ void SAuiDockArt::DrawCaption(wxDC& dc, wxWindow* window, const wxString& text, + int caption_offset = 0; + if (pane.icon.IsOk()) + { ++#if wxMAJOR_VERSION >= 3 && wxMINOR_VERSION >= 1 + // Ensure the icon fits into the title bar. + wxSize iconSize = pane.icon.GetSize(); + if (iconSize.y > rect.height) +@@ -554,7 +555,9 @@ void SAuiDockArt::DrawCaption(wxDC& dc, wxWindow* window, const wxString& text, + dc.DrawBitmap(pane.icon, + rect.x+xOffset, rect.y+(rect.height-pane.icon.GetHeight())/2, + true); +- ++#else ++ DrawIcon(dc, rect, pane); ++#endif + caption_offset += pane.icon.GetWidth() + px3; + } + +-- +2.34.1 + diff --git a/games-util/slade/slade-3.2.0.ebuild b/games-util/slade/slade-3.2.0.ebuild new file mode 100644 index 000000000000..76979d24ed46 --- /dev/null +++ b/games-util/slade/slade-3.2.0.ebuild @@ -0,0 +1,78 @@ +# Copyright 1999-2022 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +LUA_COMPAT=( lua5-{1..3} ) +WX_GTK_VER="3.0-gtk3" + +inherit cmake lua-single wxwidgets + +MY_PV="${PV/beta/b}" +DESCRIPTION="Modern editor for Doom-engine based games and source ports" +HOMEPAGE="https://slade.mancubus.net/" +SRC_URI="https://github.com/sirjuddington/${PN^^}/archive/${MY_PV}.tar.gz -> ${P}.tar.gz" +LICENSE="GPL-2 MIT" +SLOT="0" +KEYWORDS="~amd64" +IUSE="fluidsynth timidity webkit" +REQUIRED_USE="${LUA_REQUIRED_USE}" + +DEPEND=" + ${LUA_DEPS} + app-arch/bzip2:= + dev-libs/libfmt:= + >=media-libs/dumb-2:= + media-libs/freeimage[jpeg,png,tiff] + media-libs/glew:0= + media-libs/libsfml:= + media-sound/mpg123 + net-misc/curl + sys-libs/zlib + x11-libs/wxGTK:${WX_GTK_VER}[opengl,webkit?,X] + fluidsynth? ( media-sound/fluidsynth:= ) +" + +RDEPEND=" + ${DEPEND} + timidity? ( media-sound/timidity++ ) +" + +BDEPEND=" + app-arch/p7zip + virtual/pkgconfig +" + +S="${WORKDIR}/${PN^^}-${MY_PV}" + +PATCHES=( + "${FILESDIR}"/${PN}-3.2.0-bundled-libs.patch + "${FILESDIR}"/${PN}-3.2.0_beta2-fluidsynth-driver.patch + "${FILESDIR}"/${PN}-3.2.0-wx3.0.patch +) + +src_prepare() { + cmake_src_prepare + + # Delete bundled libraries just in case. + rm -r thirdparty/dumb/ || die + +} + +src_configure() { + local luav=$(lua_get_version) + + local mycmakeargs=( + -DLua_FIND_VERSION_MAJOR=$(ver_cut 1 "${luav}") + -DLua_FIND_VERSION_MINOR=$(ver_cut 2 "${luav}") + -DLua_FIND_VERSION_COUNT=2 + -DLua_FIND_VERSION_EXACT=ON + -DNO_FLUIDSYNTH=$(usex fluidsynth OFF ON) + -DNO_WEBVIEW=$(usex webkit OFF ON) + -DUSE_SFML_RENDERWINDOW=ON + -DWX_GTK3=ON + ) + + setup-wxwidgets + cmake_src_configure +}