From 7968d9c2a230f8cd2caf90abd31d4ad81e55a88779bbc57b8dd9f6585583fbe7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bj=C3=B8rn=20Lie?= Date: Wed, 27 Nov 2024 13:49:02 +0000 Subject: [PATCH] slade 3.2.6 (rq 1226915) --- ...e-option-to-skip-Lua-components-1175.patch | 231 ------------------ ...tivating-the-crash-handler-at-build-.patch | 32 +-- 3.1.13.tar.gz | 3 - 3.2.6.tar.gz | 3 + disable_sse.patch | 12 - slade.changes | 18 ++ slade.spec | 28 +-- 7 files changed, 45 insertions(+), 282 deletions(-) delete mode 100644 0001-build-add-cmake-option-to-skip-Lua-components-1175.patch delete mode 100644 3.1.13.tar.gz create mode 100644 3.2.6.tar.gz delete mode 100644 disable_sse.patch diff --git a/0001-build-add-cmake-option-to-skip-Lua-components-1175.patch b/0001-build-add-cmake-option-to-skip-Lua-components-1175.patch deleted file mode 100644 index a618942..0000000 --- a/0001-build-add-cmake-option-to-skip-Lua-components-1175.patch +++ /dev/null @@ -1,231 +0,0 @@ -From a54f12b4c29e949458949d5bede2f74b1aa8a34a Mon Sep 17 00:00:00 2001 -From: jengelh -Date: Mon, 29 Jun 2020 03:43:01 +0200 -Subject: [PATCH] build: add cmake option to skip Lua components (#1175) - -sol.hpp has a lot of templates which, when building with -g --fsanitize=address -fsanitize=undefined, incur long compile time and -high memory usage (~8500MB) [applies to Scripting/Export/Archive.cpp -and Scripting/Export/Graphics.cpp]. - -Add a cmake option so I can skip building some parts and focus on -the rest. - -Co-authored-by: Simon Judd ---- - src/Application/App.cpp | 8 ++++++++ - src/CMakeLists.txt | 11 ++++++++++- - src/MainEditor/UI/ArchivePanel.cpp | 10 ++++++++++ - src/MainEditor/UI/MainWindow.cpp | 2 ++ - src/MapEditor/UI/MapEditorWindow.cpp | 6 ++++++ - 5 files changed, 36 insertions(+), 1 deletion(-) - -Index: SLADE-3.1.12/src/Application/App.cpp -=================================================================== ---- SLADE-3.1.12.orig/src/Application/App.cpp -+++ SLADE-3.1.12/src/Application/App.cpp -@@ -450,8 +450,10 @@ bool App::init(vector& args, dou - SAction::setBaseWxId(26000); - SAction::initActions(); - -+#ifdef USE_LUA - // Init lua - Lua::init(); -+#endif - - // Init UI - UI::init(ui_scale); -@@ -515,8 +517,10 @@ bool App::init(vector& args, dou - Log::info("Loading game configurations"); - Game::init(); - -+#ifdef USE_LUA - // Init script manager - ScriptManager::init(); -+#endif - - // Show the main window - MainEditor::windowWx()->Show(true); -@@ -644,8 +648,10 @@ void App::exit(bool save_config) - // Save custom special presets - Game::saveCustomSpecialPresets(); - -+#ifdef USE_LUA - // Save custom scripts - ScriptManager::saveUserScripts(); -+#endif - } - - // Close all open archives -@@ -666,8 +672,10 @@ void App::exit(bool save_config) - files = temp.GetNext(&filename); - } - -+#ifdef USE_LUA - // Close lua - Lua::close(); -+#endif - - // Close DUMB - dumb_exit(); -Index: SLADE-3.1.12/src/CMakeLists.txt -=================================================================== ---- SLADE-3.1.12.orig/src/CMakeLists.txt -+++ SLADE-3.1.12/src/CMakeLists.txt -@@ -105,6 +105,9 @@ find_package(OpenGL REQUIRED) - find_package(GLEW REQUIRED) - find_package(Freetype REQUIRED) - find_package(CURL REQUIRED) -+if (NOT NO_LUA) -+ find_package(Lua REQUIRED) -+endif() - include_directories( - ${FREEIMAGE_INCLUDE_DIR} - ${SFML_INCLUDE_DIR} -@@ -133,6 +136,7 @@ endif () - - set(SLADE_SOURCES - ) -+set(SLADE_SCRIPTING_SOURCES) - # Don't include external libraries here as they should be compiled separately - file(GLOB_RECURSE SLADE_SOURCES - Application/*.cpp -@@ -147,9 +151,14 @@ file(GLOB_RECURSE SLADE_SOURCES - OpenGL/*.cpp - UI/*.cpp - Utility/*.cpp -- Scripting/*.cpp - TextEditor/*.cpp - ) -+if (NOT NO_LUA) -+ file(GLOB_RECURSE SLADE_SCRIPTING_SOURCES Scripting/*.cpp) -+ set(SLADE_SOURCES ${SLADE_SOURCES} ${SLADE_SCRIPTING_SOURCES}) -+ ADD_DEFINITIONS(-DUSE_LUA) -+else () -+endif () - set(SLADE_HEADERS - ) - file(GLOB_RECURSE SLADE_HEADERS *.h *.hpp) -Index: SLADE-3.1.12/src/MainEditor/UI/ArchivePanel.cpp -=================================================================== ---- SLADE-3.1.12.orig/src/MainEditor/UI/ArchivePanel.cpp -+++ SLADE-3.1.12/src/MainEditor/UI/ArchivePanel.cpp -@@ -522,7 +522,9 @@ void ArchivePanel::addMenus() - SAction::fromId("arch_replace_maps")->addToMenu(menu_clean); - menu_archive->AppendSubMenu(menu_clean, "&Maintenance"); - auto menu_scripts = new wxMenu(); -+#ifdef USE_LUA - ScriptManager::populateEditorScriptMenu(menu_scripts, ScriptManager::ScriptType::Archive, "arch_script"); -+#endif - menu_archive->AppendSubMenu(menu_scripts, "&Run Script"); - } - if (!menu_entry) -@@ -546,7 +548,9 @@ void ArchivePanel::addMenus() - menu_entry->AppendSeparator(); - SAction::fromId("arch_entry_bookmark")->addToMenu(menu_entry); - auto menu_scripts = new wxMenu(); -+#ifdef USE_LUA - ScriptManager::populateEditorScriptMenu(menu_scripts, ScriptManager::ScriptType::Entry, "arch_entry_script"); -+#endif - menu_entry->AppendSubMenu(menu_scripts, "&Run Script"); - } - -@@ -3189,9 +3193,11 @@ bool ArchivePanel::handleAction(string i - dlg.ShowModal(); - } - -+#ifdef USE_LUA - // Archive->Scripts->... - else if (id == "arch_script") - ScriptManager::runArchiveScript(archive_, wx_id_offset); -+#endif - - - // ------------------------------------------------------------------------ -@@ -3269,9 +3275,11 @@ bool ArchivePanel::handleAction(string i - else if (id == "arch_entry_openext") - openEntryExternal(); - -+#ifdef USE_LUA - // Entry->Run Script - else if (id == "arch_entry_script") - ScriptManager::runEntryScript(entry_list_->getSelectedEntries(), wx_id_offset, MainEditor::windowWx()); -+#endif - - - // Context menu actions -@@ -3785,6 +3793,7 @@ void ArchivePanel::onEntryListRightClick - #endif - } - -+#ifdef USE_LUA - // Entry scripts - if (!ScriptManager::editorScripts(ScriptManager::ScriptType::Entry).empty()) - { -@@ -3793,6 +3802,7 @@ void ArchivePanel::onEntryListRightClick - context.AppendSeparator(); - context.AppendSubMenu(menu_scripts, "Run &Script"); - } -+#endif - - // Popup the context menu - PopupMenu(&context); -Index: SLADE-3.1.12/src/MainEditor/UI/MainWindow.cpp -=================================================================== ---- SLADE-3.1.12.orig/src/MainEditor/UI/MainWindow.cpp -+++ SLADE-3.1.12/src/MainEditor/UI/MainWindow.cpp -@@ -661,12 +661,14 @@ bool MainWindow::handleAction(string id) - if (id == "main_showstartpage") - openStartPageTab(); - -+#ifdef USE_LUA - // Tools->Run Script - if (id == "main_runscript") - { - ScriptManager::open(); - return true; - } -+#endif - - // Help->About - if (id == "main_about") -Index: SLADE-3.1.12/src/MapEditor/UI/MapEditorWindow.cpp -=================================================================== ---- SLADE-3.1.12.orig/src/MapEditor/UI/MapEditorWindow.cpp -+++ SLADE-3.1.12/src/MapEditor/UI/MapEditorWindow.cpp -@@ -269,7 +269,9 @@ void MapEditorWindow::setupMenu() - // Tools menu - wxMenu* menu_tools = new wxMenu(""); - menu_scripts_ = new wxMenu(); -+#ifdef USE_LUA - ScriptManager::populateEditorScriptMenu(menu_scripts_, ScriptManager::ScriptType::Map, "mapw_script"); -+#endif - menu_tools->AppendSubMenu(menu_scripts_, "Run Script"); - SAction::fromId("mapw_runscript")->addToMenu(menu_tools); - menu->Append(menu_tools, "&Tools"); -@@ -1136,7 +1138,9 @@ void MapEditorWindow::reloadScriptsMenu( - while (menu_scripts_->FindItemByPosition(0)) - menu_scripts_->Delete(menu_scripts_->FindItemByPosition(0)); - -+#ifdef USE_LUA - ScriptManager::populateEditorScriptMenu(menu_scripts_, ScriptManager::ScriptType::Map, "mapw_script"); -+#endif - } - - // ---------------------------------------------------------------------------- -@@ -1436,6 +1440,7 @@ bool MapEditorWindow::handleAction(strin - return true; - } - -+#ifdef USE_LUA - // Tools->Run Script - else if (id == "mapw_script") - { -@@ -1449,6 +1454,7 @@ bool MapEditorWindow::handleAction(strin - ScriptManager::open(); - return true; - } -+#endif - - return false; - } diff --git a/0001-build-allow-deactivating-the-crash-handler-at-build-.patch b/0001-build-allow-deactivating-the-crash-handler-at-build-.patch index 4656521..c34cbdd 100644 --- a/0001-build-allow-deactivating-the-crash-handler-at-build-.patch +++ b/0001-build-allow-deactivating-the-crash-handler-at-build-.patch @@ -19,11 +19,11 @@ Fixes: #1166 src/CMakeLists.txt | 4 ++++ 3 files changed, 6 insertions(+), 1 deletion(-) -diff --git a/src/Application/SLADEWxApp.cpp b/src/Application/SLADEWxApp.cpp -index 375f62b8..d9196355 100644 ---- a/src/Application/SLADEWxApp.cpp -+++ b/src/Application/SLADEWxApp.cpp -@@ -523,7 +523,7 @@ bool SLADEWxApp::OnInit() +Index: SLADE-3.2.6/src/Application/SLADEWxApp.cpp +=================================================================== +--- SLADE-3.2.6.orig/src/Application/SLADEWxApp.cpp ++++ SLADE-3.2.6/src/Application/SLADEWxApp.cpp +@@ -449,7 +449,7 @@ bool SLADEWxApp::OnInit() #endif // Handle exceptions using wxDebug stuff, but only in release mode @@ -32,21 +32,15 @@ index 375f62b8..d9196355 100644 wxHandleFatalExceptions(true); #endif -diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt -index 4ce2403d..5eabe4c7 100644 ---- a/src/CMakeLists.txt -+++ b/src/CMakeLists.txt -@@ -132,6 +132,10 @@ if (NOT NO_FLUIDSYNTH) - include_directories(${FLUIDSYNTH_INCLUDE_DIR}) - endif() - +Index: SLADE-3.2.6/src/CMakeLists.txt +=================================================================== +--- SLADE-3.2.6.orig/src/CMakeLists.txt ++++ SLADE-3.2.6/src/CMakeLists.txt +@@ -41,3 +41,7 @@ if (WIN32 AND MSVC) + else () + include("unix") # Linux or MacOS + endif () +if (NOT NO_CRASHHANDLER) + add_definitions(-DUSE_CRASHHANDLER) +endif () + - set(SLADE_SOURCES - ) - # Don't include external libraries here as they should be compiled separately --- -2.27.0 - diff --git a/3.1.13.tar.gz b/3.1.13.tar.gz deleted file mode 100644 index f61cb02..0000000 --- a/3.1.13.tar.gz +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:a9719f8639ae579c9671fda8c8ccbcc1ed55f7c98208fdeb439fb8d52fe340d7 -size 5890835 diff --git a/3.2.6.tar.gz b/3.2.6.tar.gz new file mode 100644 index 0000000..fe419c2 --- /dev/null +++ b/3.2.6.tar.gz @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0412de60517f4301881b048aee271bd45bacc1374b1955284647e9bd6732d2ff +size 7027328 diff --git a/disable_sse.patch b/disable_sse.patch deleted file mode 100644 index 2a5b138..0000000 --- a/disable_sse.patch +++ /dev/null @@ -1,12 +0,0 @@ ---- SLADE-3.1.13/src/CMakeLists.txt.orig 2021-06-15 14:13:13.473287606 +0200 -+++ SLADE-3.1.13/src/CMakeLists.txt 2021-06-15 14:13:28.233451010 +0200 -@@ -159,9 +159,6 @@ if(APPLE) - set_source_files_properties(${OSX_ICON} PROPERTIES MACOSX_PACKAGE_LOCATION Resources) - endif(APPLE) - --# enable SSE instructions for dumb library --set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -D_USE_SSE -msse") -- - if(USE_SANITIZER) - set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fsanitize=address") - set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fsanitize=address") diff --git a/slade.changes b/slade.changes index e35ba05..c78777a 100644 --- a/slade.changes +++ b/slade.changes @@ -1,3 +1,21 @@ +------------------------------------------------------------------- +Wed Nov 27 12:15:46 UTC 2024 - Bjørn Lie + +- Update to version 3.2.6: + * Please see Release Notes upstream at + https://github.com/sirjuddington/SLADE/releases +- Drop patches fixed upstream: + * disable_sse.patch + * 0001-build-add-cmake-option-to-skip-Lua-components-1175.patch +- Disable patches that needs rebase or dropping: + * basepk3.diff + * wx.diff + * clzma.diff +- Rebase 0001-build-allow-deactivating-the-crash-handler-at-build-.patch +- Replace wxWidgets-3_0-devel for wxWidgets-devel BuildRequires: + Package builds just fine with the newer 3.2 version. +- Add pkgconfig(libmpg123) BuildRequires: New dependency. + ------------------------------------------------------------------- Mon Feb 26 13:25:20 UTC 2024 - Dominique Leuenberger diff --git a/slade.spec b/slade.spec index be565e8..6e1f24d 100644 --- a/slade.spec +++ b/slade.spec @@ -1,7 +1,7 @@ # # spec file for package slade # -# Copyright (c) 2021 SUSE LLC +# Copyright (c) 2024 SUSE LLC # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed @@ -17,28 +17,26 @@ Name: slade -Version: 3.1.13 +Version: 3.2.6 Release: 0 Summary: An editor for DOOM maps and WAD/PK3 archives License: GPL-2.0-or-later Group: Amusements/Games/3D/Shoot URL: https://github.com/sirjuddington/SLADE -Source: https://github.com/sirjuddington/SLADE/archive/refs/tags/%version.tar.gz +Source: %{url}/archive/refs/tags/%version.tar.gz Patch1: basepk3.diff Patch2: wx.diff Patch3: clzma.diff Patch4: 0001-build-allow-deactivating-the-crash-handler-at-build-.patch -Patch10: disable_sse.patch -Patch11: 0001-build-add-cmake-option-to-skip-Lua-components-1175.patch -# slade 3.2 will need gcc-c++>=8 and pkgconfig(fmt)>=6 + BuildRequires: ImageMagick BuildRequires: cmake >= 3.1 BuildRequires: freeimage-devel -BuildRequires: gcc-c++ >= 6 +BuildRequires: gcc-c++ >= 8 BuildRequires: pkg-config BuildRequires: strip-nondeterminism BuildRequires: update-desktop-files -BuildRequires: wxWidgets-3_0-devel +BuildRequires: wxWidgets-devel BuildRequires: zip BuildRequires: pkgconfig(clzma) BuildRequires: pkgconfig(fluidsynth) @@ -46,6 +44,7 @@ BuildRequires: pkgconfig(ftgl) BuildRequires: pkgconfig(gl) BuildRequires: pkgconfig(glew) BuildRequires: pkgconfig(libcurl) +BuildRequires: pkgconfig(libmpg123) BuildRequires: pkgconfig(sfml-all) BuildRequires: pkgconfig(x11) Provides: bundled(dumb) = 0.9.3 @@ -58,13 +57,8 @@ from/to other generic formats such as PNG. %prep %setup -q -n SLADE-%version -%patch -P 1 -P 2 -P 3 -P 4 -p1 -%ifnarch %ix86 x86_64 -%patch -P 10 -p1 -%endif -%if 0%{?suse_version} >= 1550 -%patch -P 11 -p1 -%endif +#%%patch -P 1 -P 2 -P 3 -p1 +%patch -P 4 -p1 %build %define _lto_cflags %nil @@ -79,11 +73,11 @@ strip-nondeterminism build/slade.pk3 %cmake_install %files -%license gpl-2.0.txt +%license LICENSE %doc README.md %_bindir/slade %_datadir/slade3/ -%_datadir/icons/net.mancubus.SLADE.png +%_datadir/icons/hicolor/scalable/apps/net.mancubus.SLADE.svg %_datadir/applications/net.mancubus.SLADE.desktop %_datadir/metainfo/net.mancubus.SLADE.metainfo.xml