diff options
author | Jan Cholasta | 2022-04-14 14:16:24 +0200 |
---|---|---|
committer | Jan Cholasta | 2022-04-14 14:16:35 +0200 |
commit | bf15a916fa4fb2edd7656e6cf6b0868255462773 (patch) | |
tree | aba03216546354ab53b6e0bc9cc27dd11ffb05ff | |
parent | d8fd6d0fc4299f3e6832adeed3fa97e28ceeca7a (diff) | |
download | aur-bf15a916fa4fb2edd7656e6cf6b0868255462773.tar.gz |
slade-git-3.2.0_b4+35+gf7bd1432-1
-rw-r--r-- | .SRCINFO | 4 | ||||
-rw-r--r-- | 0001-compatibility-with-stable-wxWidgets.patch | 43 | ||||
-rw-r--r-- | PKGBUILD | 23 |
3 files changed, 61 insertions, 9 deletions
@@ -20,12 +20,14 @@ pkgbase = slade-git depends = mpg123 depends = sfml>=2.5 depends = webkit2gtk - depends = wxgtk3-dev-opt=3.1.5 + depends = wxgtk3>=3.0 depends = zlib provides = slade conflicts = slade source = slade::git+https://github.com/sirjuddington/SLADE.git + source = 0001-compatibility-with-stable-wxWidgets.patch sha256sums = SKIP + sha256sums = ababb76f64b4cfbdabd283ffb8e5d7900f270893161433e84a93f2655767d5d2 pkgname = slade-git diff --git a/0001-compatibility-with-stable-wxWidgets.patch b/0001-compatibility-with-stable-wxWidgets.patch new file mode 100644 index 000000000000..7b2508f80c07 --- /dev/null +++ b/0001-compatibility-with-stable-wxWidgets.patch @@ -0,0 +1,43 @@ +From be61a443c87e97d7a1b8716428c7e3fedcc7a34c Mon Sep 17 00:00:00 2001 +From: Jan Cholasta <jan@cholasta.net> +Date: Thu, 14 Apr 2022 14:15:13 +0200 +Subject: [PATCH] compatibility with stable wxWidgets + +--- + src/Graphics/Icons.cpp | 2 ++ + src/UI/SAuiTabArt.cpp | 5 ++++- + 2 files changed, 6 insertions(+), 1 deletion(-) + +diff --git a/src/Graphics/Icons.cpp b/src/Graphics/Icons.cpp +index 61d5475c..8c6e5c44 100644 +--- a/src/Graphics/Icons.cpp ++++ b/src/Graphics/Icons.cpp +@@ -373,7 +373,9 @@ wxBitmap loadPNGIcon(const IconDef& icon, int size, Point2i padding) + bool icons::loadIcons() + { + // Check for dark mode ++#if wxCHECK_VERSION(3, 1, 0) + ui_icons_dark = wxSystemSettings::GetAppearance().IsDark(); ++#endif + + // Get slade.pk3 + auto* res_archive = app::archiveManager().programResourceArchive(); +diff --git a/src/UI/SAuiTabArt.cpp b/src/UI/SAuiTabArt.cpp +index 15aad09e..1fa29b73 100644 +--- a/src/UI/SAuiTabArt.cpp ++++ b/src/UI/SAuiTabArt.cpp +@@ -550,7 +550,10 @@ void SAuiDockArt::DrawCaption(wxDC& dc, wxWindow* window, const wxString& text, + } + + // Draw the icon centered vertically +- int xOffset = window->FromDIP(2); ++ int xOffset = 2; ++#if wxCHECK_VERSION(3, 1, 0) ++ xOffset = window->FromDIP(xOffset); ++#endif + dc.DrawBitmap(pane.icon, + rect.x+xOffset, rect.y+(rect.height-pane.icon.GetHeight())/2, + true); +-- +2.35.1 + @@ -1,7 +1,6 @@ # Maintainer: Jan Cholasta <grubber at grubber cz> -_name=slade -pkgname=${_name}-git +pkgname=slade-git pkgver=3.2.0_b4+35+gf7bd1432 pkgrel=1 pkgdesc='SLADE3 Doom editor (git version)' @@ -19,15 +18,17 @@ depends=('bzip2' 'mpg123' 'sfml>=2.5' 'webkit2gtk' - 'wxgtk3-dev-opt=3.1.5' + 'wxgtk3>=3.0' 'zlib') makedepends=('cmake' 'git' 'p7zip') -provides=("${_name}") -conflicts=("${_name}") -source=("${_name}::git+https://github.com/sirjuddington/SLADE.git") -sha256sums=('SKIP') +provides=('slade') +conflicts=('slade') +source=('slade::git+https://github.com/sirjuddington/SLADE.git' + '0001-compatibility-with-stable-wxWidgets.patch') +sha256sums=('SKIP' + 'ababb76f64b4cfbdabd283ffb8e5d7900f270893161433e84a93f2655767d5d2') pkgver() { cd slade @@ -35,13 +36,19 @@ pkgver() { git describe --long --tags | sed -r 's/-/+/g' } +prepare() { + cd slade + + patch -i "$srcdir"/0001-compatibility-with-stable-wxWidgets.patch -p 1 +} + build() { cd slade export CCACHE_SLOPPINESS=pch_defines,time_macros cmake -DCMAKE_BUILD_TYPE=Release \ -DCMAKE_INSTALL_PREFIX=/usr \ - -DwxWidgets_CONFIG_EXECUTABLE=/opt/wxgtk-dev/bin/wx-config-gtk3 \ + -DwxWidgets_CONFIG_EXECUTABLE=/usr/bin/wx-config-gtk3 \ . make } |