Script 'mail_helper' called by obssrc
Hello community,

here is the log from the commit of package devilutionx for 
openSUSE:Factory:NonFree checked in at 2022-12-23 10:20:12
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory:NonFree/devilutionx (Old)
 and      /work/SRC/openSUSE:Factory:NonFree/.devilutionx.new.1563 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "devilutionx"

Fri Dec 23 10:20:12 2022 rev:5 rq:981400 version:1.4.0

Changes:
--------
--- /work/SRC/openSUSE:Factory:NonFree/devilutionx/devilutionx.changes  
2021-04-15 16:55:50.426524593 +0200
+++ 
/work/SRC/openSUSE:Factory:NonFree/.devilutionx.new.1563/devilutionx.changes    
    2022-12-23 10:20:13.443042274 +0100
@@ -1,0 +2,65 @@
+Fri May 20 12:07:33 UTC 2022 - Ferdinand Thiessen <r...@fthiessen.de>
+
+- Update to version 1.4.0
+  * Added Translations for Ukraine, Greek, Japanese, and Swedish
+  * Fix some items causing crashes for Spanish and French translations
+  * Improve Bulgarian, Chinese (Simplified), Croatian, Czech, French,
+    German, Italian, Korean, Portuguese, Romanian, Russian,
+    and Spanish localization
+  * Added a stash at Gillian's house
+  * Remove missile limit
+  * Added settings menu
+  * Added xp share indicator to monster health bar
+  * Added option to see exact health/mana
+  * Always draw hotkeys on spell list
+  * Do not stop music when navigating in the main menu
+  * Don't hide automap when opening help screen
+  * Don't restart music if the same track is played
+  * Match unique monster's missiles color to their owner's
+  * Show game Difficulty in Automap
+  * Use unique unused graphics for Long War Bow
+  * Display numeric max resists on character panel
+  * Add additional emojis
+  * Mute videos when minimized
+  * MP3 support
+  * Remove stippled transparency option
+  * Multiplayer:
+    * Improve how public games are displayed
+    * Revamped chat
+    * Enable dungeon messages
+    * OpenDingux Lepus: Enable ZeroTier
+  * A large number of actions can now be mapped to custom keys
+  * Increase spell hotkeys from 4 to 12
+  * Added support for touch controls on all devices
+  * Prevent spells from targeting other players in friendly mode
+  * Add support for multiple lines in quick messages
+  * Reduce memory consumption during movies
+- Add accept-libzt-tarball.patch, this allows bundling a tarball
+  instead of a full git clone with history. It simply changes
+  git clone to archive download (which will not work normally
+  because it would not contain the required submodules, but we are
+  providing a custom, previously fetched archive containing all
+  submodules anyway). This reduces the source RPM by about 100MB.
+- Add aarch64-fix-detection.patch from upstream
+
+-------------------------------------------------------------------
+Mon Jan 31 21:03:33 UTC 2022 - Ferdinand Thiessen <r...@fthiessen.de>
+
+- Add use-system-libraries.patch to use system libraries instead
+  of bundled libraries
+- Only bundle simpleini and ZeroTier SDK
+
+-------------------------------------------------------------------
+Sat Dec  4 13:12:00 UTC 2021 - Ferdinand Thiessen <r...@fthiessen.de>
+
+- Update to version 1.3.0
+  * Animations are now updated at render time for high fps visuals
+  * Added support for hardware cursor (solves cursor lag)
+  * Quests being ordered logically in the quest panel
+  * Quest panel now lists completed quests
+  * Added support for unencrypted public games
+  * Add support for translations and add translations
+  * A lot other features and bug fixes, see:
+    https://github.com/diasurgical/devilutionX/releases/tag/1.3.0
+
+-------------------------------------------------------------------

Old:
----
  devilutionx-1.2.1.tar.gz

New:
----
  _service
  aarch64-fix-detection.patch
  accept-libzt-tarball.patch
  devilutionx-1.4.0.tar.gz
  devilutionx-rpmlintrc
  libmpq-0f10bd1600f406b13932bf5351ba713361262184.tar.gz
  libsmackerdec-2997ee0e41e91bb723003bc09234be553b190e38.tar.gz
  libzt-a34ba7f.obscpio
  libzt.obsinfo
  simpleini-9b3ed7ec815997bc8c5b9edf140d6bde653e1458.tar.gz
  use-system-libraries.patch

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ devilutionx.spec ++++++
--- /var/tmp/diff_new_pack.gVFu5a/_old  2022-12-23 10:20:15.287052812 +0100
+++ /var/tmp/diff_new_pack.gVFu5a/_new  2022-12-23 10:20:15.291052835 +0100
@@ -1,7 +1,7 @@
 #
 # spec file for package devilutionx
 #
-# Copyright (c) 2021 SUSE LLC
+# Copyright (c) 2022 SUSE LLC
 # Copyright (c) 2019-2021, Martin Hauke <mar...@gmx.de>
 #
 # All modifications and additions to the file contributed by third parties
@@ -17,27 +17,50 @@
 #
 
 
+# See 3rdParty/simpleini/CMakeLists.txt
+%define zerotier_hash  a34ba7f
+%define mpq_hash 0f10bd1600f406b13932bf5351ba713361262184
+%define simpleini_hash 9b3ed7ec815997bc8c5b9edf140d6bde653e1458
+%define smackerdec_hash 2997ee0e41e91bb723003bc09234be553b190e38
 Name:           devilutionx
-Version:        1.2.1
+Version:        1.4.0
 Release:        0
 Summary:        An open source implementation of the Diablo 1 game engine
-# 3rdParty/asio/* is licensed under BSL-1.0
 # 3rdParty/libsmacker/* is licensed under CC-BY-NC-2.0 and CC-BY-SA-NC-2.0
 # 3rdParty/[Storm|StormLib]/* is licensed under MIT
 # 3rdParty/Radon/* is licensed under MIT
-License:        SUSE-Public-Domain
+# libzt is licensed under the BUSL-1.1
+# simpleini is licensed under the MIT license
+License:        BUSL-1.1 AND SUSE-Public-Domain AND MIT
 Group:          Amusements/Games/RPG
 URL:            https://github.com/diasurgical/devilutionX
 #Git-Clone:     https://github.com/diasurgical/devilutionX.git
-Source:         
https://github.com/diasurgical/devilutionX/archive/%{version}.tar.gz#/%{name}-%{version}.tar.gz
+Source0:        
https://github.com/diasurgical/devilutionX/archive/%{version}.tar.gz#/%{name}-%{version}.tar.gz
+Source1:        
https://github.com/brofield/simpleini/archive/%{simpleini_hash}.tar.gz#/simpleini-%{simpleini_hash}.tar.gz
+Source2:        
https://github.com/diasurgical/libsmackerdec/archive/%{smackerdec_hash}.tar.gz#/libsmackerdec-%{smackerdec_hash}.tar.gz
+Source3:        
https://github.com/diasurgical/libmpq/archive/%{mpq_hash}.tar.gz#/libmpq-%{mpq_hash}.tar.gz
+Source4:        libzt-%{zerotier_hash}.tar
+Source98:       devilutionx-rpmlintrc
 Source99:       baselibs.conf
+# PATCH-FIX-OPENSUSE accept-libzt-tarball.patch -- Allow tarball instead of 
full git clone for zerotier
+Patch0:         accept-libzt-tarball.patch
+# PATCH-FIX-OPENSUSE use-system-libraries.patch -- Use system asio, 
SDL_audiolib, SDL2_image, libpng, sodium, and fmt
+Patch1:         use-system-libraries.patch
+# PATCH-FIX-UPSTREAM aarch64-fix-detection.patch -- Fix arch detection to fix 
aarch64 build
+Patch2:         
https://github.com/zerotier/libzt/pull/179.patch#/aarch64-fix-detection.patch
+BuildRequires:  asio-devel
 BuildRequires:  cmake >= 3.13
 BuildRequires:  gcc-c++
+BuildRequires:  gmock
+BuildRequires:  gtest
 BuildRequires:  hicolor-icon-theme
 BuildRequires:  pkgconfig
 BuildRequires:  update-desktop-files
-BuildRequires:  pkgconfig(SDL2_mixer)
-BuildRequires:  pkgconfig(SDL2_ttf)
+BuildRequires:  (cmake(fmt) >= 7 and cmake(fmt) < 8)
+BuildRequires:  pkgconfig(SDL2_image)
+BuildRequires:  pkgconfig(SDL_audiolib)
+BuildRequires:  pkgconfig(bzip2)
+BuildRequires:  pkgconfig(libpng)
 BuildRequires:  pkgconfig(libsodium)
 BuildRequires:  pkgconfig(sdl2)
 # CharisSILB.ttf:
@@ -51,13 +74,31 @@
 
 %prep
 %setup -q -n devilutionX-%{version}
+%patch0 -p1
+%patch1 -p1
+mkdir prefetched
+pushd prefetched
+for s in %{SOURCE1} %{SOURCE2} %{SOURCE3} %{SOURCE4}; do tar -xf "$s"; done
+pushd libzt-%{zerotier_hash}
+%patch2 -p1
+popd
+popd
 
 %build
-export CXXFLAGS='%{optflags} 
-DTTF_FONT_PATH=\"/usr/share/fonts/truetype/CharisSILB.ttf\"'
+export CXXFLAGS='%{optflags} 
-DTTF_FONT_PATH=\"%{_datadir}/fonts/truetype/CharisSILB.ttf\"'
 %cmake \
   -DVERSION_NUM=%{version} \
-  -DBINARY_RELEASE=ON
-%make_jobs
+  -DBINARY_RELEASE=ON \
+  -DPIE=ON \
+  -DDEVILUTIONX_SYSTEM_ASIO=ON \
+  -DDEVILUTIONX_SYSTEM_SDL_AUDIOLIB=ON \
+  -DDEVILUTIONX_SYSTEM_SDL_IMAGE=ON \
+  -DBUILD_SHARED_LIBS:BOOL=OFF -DBUILD_STATIC_LIBS:BOOL=ON \
+  -DFETCHCONTENT_SOURCE_DIR_LIBMPQ=../prefetched/libmpq-%{mpq_hash} \
+  
-DFETCHCONTENT_SOURCE_DIR_SIMPLEINI=../prefetched/simpleini-%{simpleini_hash} \
+  -DFETCHCONTENT_SOURCE_DIR_LIBZT=../prefetched/libzt-%{zerotier_hash} \
+  
-DFETCHCONTENT_SOURCE_DIR_LIBSMACKERDEC=../prefetched/libsmackerdec-%{smackerdec_hash}
+%cmake_build
 
 %install
 install -D -m 0755 build/devilutionx %{buildroot}%{_bindir}/devilutionx

++++++ _service ++++++
<services>
  <service name="obs_scm" mode="manual">
    <param name="url">https://github.com/diasurgical/libzt.git</param>
    <param name="scm">git</param>
    <param name="revision">a34ba7f1cc2e41b05badd25d1b01fdc5fd2f4e02</param>
    <param name="versionformat">%h</param>
    <param name="filename">libzt</param>
  </service>
  <service mode="buildtime" name="tar">
        <param name="obsinfo">libzt.obsinfo</param>
  </service>
</services>


++++++ aarch64-fix-detection.patch ++++++
>From 2bee330b1506e7964b45762e47e5fdcf4ceb5952 Mon Sep 17 00:00:00 2001
From: Alexander Arlt <alexander.a...@arlt-labs.com>
Date: Fri, 25 Mar 2022 18:33:56 -0500
Subject: [PATCH] cmake: add arch detection.

---
 CMakeLists.txt | 47 +++++++++++++++++++++++++++++++++++++++++++++++
 1 file changed, 47 insertions(+)

diff --git a/CMakeLists.txt b/CMakeLists.txt
index be00ded3..1aa2098e 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -56,6 +56,53 @@ if(BUILD_WIN32
     set(BUILD_WIN TRUE)
 endif()
 
+SET(ZT_ARCHITECTURE 999)
+IF (${CMAKE_SYSTEM_PROCESSOR} MATCHES "x86_64" OR ${CMAKE_SYSTEM_PROCESSOR} 
MATCHES "amd64")
+    SET(ZT_ARCHITECTURE 2)
+    SET(ZT_USE_X64_ASM_SALSA 1)
+    SET(ZT_USE_X64_ASM_ED25519 1)
+    SET(ZT_SSO_SUPPORTED 1)
+    SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -msse -msse2")
+    SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -msse -msse2")
+ELSEIF (${CMAKE_SYSTEM_PROCESSOR} MATCHES "powerpc64le")
+    SET(ZT_ARCHITECTURE 8)
+    ADD_DEFINITIONS(-DZT_NO_TYPE_PUNNING)
+ELSEIF (${CMAKE_SYSTEM_PROCESSOR} MATCHES "powerpc")
+    SET(ZT_ARCHITECTURE 8)
+    ADD_DEFINITIONS(-DZT_NO_TYPE_PUNNING -DZT_NO_CAPABILITIES)
+ELSEIF (${CMAKE_SYSTEM_PROCESSOR} MATCHES "ppc64el")
+    SET(ZT_ARCHITECTURE 8)
+ELSEIF (${CMAKE_SYSTEM_PROCESSOR} MATCHES "e2k")
+    SET(ZT_ARCHITECTURE 2)
+ELSEIF (${CMAKE_SYSTEM_PROCESSOR} MATCHES "i386" OR ${CMAKE_SYSTEM_PROCESSOR} 
MATCHES "i486" OR ${CMAKE_SYSTEM_PROCESSOR} MATCHES "i586" OR 
${CMAKE_SYSTEM_PROCESSOR} MATCHES "i686")
+    SET(ZT_ARCHITECTURE 1)
+    SET(ZT_SSO_SUPPORTED 1)
+ELSEIF (${CMAKE_SYSTEM_PROCESSOR} MATCHES "arm" OR ${CMAKE_SYSTEM_PROCESSOR} 
MATCHES "armel" OR ${CMAKE_SYSTEM_PROCESSOR} MATCHES "armhf" OR 
${CMAKE_SYSTEM_PROCESSOR} MATCHES "armv6" OR ${CMAKE_SYSTEM_PROCESSOR} MATCHES 
"armv6l" OR ${CMAKE_SYSTEM_PROCESSOR} MATCHES "armv6zk" OR 
${CMAKE_SYSTEM_PROCESSOR} MATCHES "armv7" OR ${CMAKE_SYSTEM_PROCESSOR} MATCHES 
"armv7l" OR ${CMAKE_SYSTEM_PROCESSOR} MATCHES "armv7hl" OR 
${CMAKE_SYSTEM_PROCESSOR} MATCHES "armv7ve")
+    SET(ZT_ARCHITECTURE 3)
+    SET(ZT_USE_ARM32_NEON_ASM_CRYPTO 1)
+    ADD_DEFINITIONS(-DZT_NO_TYPE_PUNNING)
+ELSEIF (${CMAKE_SYSTEM_PROCESSOR} MATCHES "arm64" OR ${CMAKE_SYSTEM_PROCESSOR} 
MATCHES "aarch64")
+    SET(ZT_ARCHITECTURE 4)
+    SET(ZT_SSO_SUPPORTED 1)
+    ADD_DEFINITIONS(-DZT_NO_TYPE_PUNNING -DZT_ARCH_ARM_HAS_NEON 
-march=armv8-a+crypto -mtune=generic -mstrict-align)
+ELSEIF (${CMAKE_SYSTEM_PROCESSOR} MATCHES "mipsel" OR 
${CMAKE_SYSTEM_PROCESSOR} MATCHES "mips")
+    SET(ZT_ARCHITECTURE 5)
+    ADD_DEFINITIONS(-DZT_NO_TYPE_PUNNING)
+ELSEIF (${CMAKE_SYSTEM_PROCESSOR} MATCHES "mips64" OR 
${CMAKE_SYSTEM_PROCESSOR} MATCHES "mips64el")
+    SET(ZT_ARCHITECTURE 6)
+    ADD_DEFINITIONS(-DZT_NO_TYPE_PUNNING)
+ELSEIF (${CMAKE_SYSTEM_PROCESSOR} MATCHES "s390x")
+    SET(ZT_ARCHITECTURE 16)
+ELSEIF (${CMAKE_SYSTEM_PROCESSOR} MATCHES "riscv64")
+    SET(ZT_ARCHITECTURE 0)
+ENDIF ()
+
+IF (${ZT_ARCHITECTURE} EQUAL 999)
+    message(FATAL_ERROR "FATAL: architecture could not be determined by CMake: 
${CMAKE_SYSTEM_PROCESSOR}")
+else()
+    message(STATUS "Detected architecture: ${CMAKE_SYSTEM_PROCESSOR}")
+ENDIF()
+
 # Linux
 # if(${CMAKE_SYSTEM_NAME} MATCHES "Linux")
 

++++++ accept-libzt-tarball.patch ++++++
diff -Nur devilutionX-1.4.0/3rdParty/libzt/CMakeLists.txt 
new/3rdParty/libzt/CMakeLists.txt
--- devilutionX-1.4.0/3rdParty/libzt/CMakeLists.txt     2022-04-13 
23:33:49.000000000 +0200
+++ new/3rdParty/libzt/CMakeLists.txt   2022-05-22 12:35:35.007999594 +0200
@@ -4,8 +4,9 @@
 
 include(FetchContent)
 FetchContent_Declare(libzt
-  GIT_REPOSITORY https://github.com/diasurgical/libzt.git
-  GIT_TAG a34ba7f1cc2e41b05badd25d1b01fdc5fd2f4e02)
+    URL https://github.com/diasurgical/libzt/archive/a34ba7f.tar.gz
+    URL_HASH MD5=1c88c07e4cade2ba859922a7da233389
+)
 FetchContent_MakeAvailableExcludeFromAll(libzt)
 
 if(NOT ANDROID)

++++++ devilutionx-1.2.1.tar.gz -> devilutionx-1.4.0.tar.gz ++++++
/work/SRC/openSUSE:Factory:NonFree/devilutionx/devilutionx-1.2.1.tar.gz 
/work/SRC/openSUSE:Factory:NonFree/.devilutionx.new.1563/devilutionx-1.4.0.tar.gz
 differ: char 12, line 1

++++++ devilutionx-rpmlintrc ++++++
addFilter("devilutionx.*: E: use-of-home-in-%post")

++++++ libzt.obsinfo ++++++
name: libzt
version: a34ba7f
mtime: 1648870047
commit: a34ba7f1cc2e41b05badd25d1b01fdc5fd2f4e02

++++++ use-system-libraries.patch ++++++
diff -Nur devilutionX-1.4.0/CMake/Dependencies.cmake 
new/CMake/Dependencies.cmake
--- devilutionX-1.4.0/CMake/Dependencies.cmake  2022-04-13 23:33:49.000000000 
+0200
+++ new/CMake/Dependencies.cmake        2022-05-22 15:05:46.136463096 +0200
@@ -167,7 +167,11 @@
 add_subdirectory(3rdParty/PKWare)
 
 if(NOT NONET AND NOT DISABLE_TCP)
-  add_subdirectory(3rdParty/asio)
+  if (DEVILUTIONX_SYSTEM_ASIO)
+    find_package(asio REQUIRED)
+  else()
+    add_subdirectory(3rdParty/asio)
+  endif()
 endif()
 
 if(NOT NONET AND NOT DISABLE_ZERO_TIER)
diff -Nur devilutionX-1.4.0/CMake/Findasio.cmake new/CMake/Findasio.cmake
--- devilutionX-1.4.0/CMake/Findasio.cmake      1970-01-01 01:00:00.000000000 
+0100
+++ new/CMake/Findasio.cmake    2022-05-22 15:03:41.727854893 +0200
@@ -0,0 +1,46 @@
+# To the extent possible under law, the author(s) have dedicated all
+# copyright and related and neighboring rights to this software to the
+# public domain worldwide. This software is distributed without any warranty.
+#
+# You should have received a copy of the CC0 Public Domain Dedication
+# along with this software. If not, see
+#
+#     https://creativecommons.org/publicdomain/zero/1.0/
+#
+########################################################################
+# Tries to find the local asio installation.
+#
+# Once done the following variables will be defined:
+#
+#   asio_FOUND
+#   asio_INCLUDE_DIR
+#
+# Furthermore an imported "asio" target is created.
+#
+
+if (CMAKE_C_COMPILER_ID STREQUAL "GNU"
+    OR CMAKE_C_COMPILER_ID STREQUAL "Clang")
+    set(_GCC_COMPATIBLE 1)
+endif()
+
+find_path(asio_INCLUDE_DIR asio.hpp
+    HINTS include
+)
+
+# communicate results
+include(FindPackageHandleStandardArgs)
+find_package_handle_standard_args(
+    asio
+    REQUIRED_VARS
+        asio_INCLUDE_DIR
+)
+
+# mark file paths as advanced
+mark_as_advanced(asio_INCLUDE_DIR)
+set(_LIB_TYPE SHARED)
+add_library(asio INTERFACE IMPORTED)
+
+set_target_properties(asio PROPERTIES
+    INTERFACE_INCLUDE_DIRECTORIES "${asio_INCLUDE_DIR}"
+    IMPORTED_LINK_INTERFACE_LANGUAGES "CPP"
+)
diff -Nur devilutionX-1.4.0/CMake/FindSDL_audiolib.cmake 
new/CMake/FindSDL_audiolib.cmake
--- devilutionX-1.4.0/CMake/FindSDL_audiolib.cmake      1970-01-01 
01:00:00.000000000 +0100
+++ new/CMake/FindSDL_audiolib.cmake    2022-05-22 15:03:41.727854893 +0200
@@ -0,0 +1,64 @@
+# To the extent possible under law, the author(s) have dedicated all
+# copyright and related and neighboring rights to this software to the
+# public domain worldwide. This software is distributed without any warranty.
+#
+# You should have received a copy of the CC0 Public Domain Dedication
+# along with this software. If not, see
+#
+#     https://creativecommons.org/publicdomain/zero/1.0/
+#
+########################################################################
+# Tries to find the local SDL_audiolib installation.
+#
+# Once done the following variables will be defined:
+#
+#   SDL_audiolib_FOUND
+#   SDL_audiolib_INCLUDE_DIR
+#   SDL_audiolib_LIBRARY
+#
+# Furthermore an imported "SDL_audiolib" target is created.
+#
+
+find_package(PkgConfig QUIET)
+if (PKG_CONFIG_FOUND)
+  pkg_check_modules(SDL_audiolib_PKG QUIET SDL_audiolib)
+endif()
+
+if(SDL_audiolib_PKG STREQUAL "")
+  set(SDL_audiolib_PKG SDL_audiolib)
+endif()
+    
+# Feed pkgconfig results (if found) into standard find_* to populate
+# the right CMake cache variables
+find_path(SDL_audiolib_INCLUDE_DIR aulib.h
+    HINTS ${SDL_audiolib_PKG_INCLUDE_DIRS}
+)
+find_library(SDL_audiolib_LIBRARY NAMES ${SDL_audiolib_PKG_LIBRARIES}
+    HINTS ${SDL_audiolib_PKG_LIBRARY_DIRS}
+)
+
+
+########################################################################
+# communicate results
+include(FindPackageHandleStandardArgs)
+find_package_handle_standard_args(
+    SDL_audiolib # The name must be either uppercase or match the filename 
case.
+    REQUIRED_VARS
+        SDL_audiolib_LIBRARY
+        SDL_audiolib_INCLUDE_DIR
+    VERSION_VAR
+       SDL_audiolib_PKG_VERSION
+)
+
+# mark file paths as advanced
+mark_as_advanced(SDL_audiolib_INCLUDE_DIR)
+mark_as_advanced(SDL_audiolib_LIBRARY_RELEASE)
+
+add_library(SDL_audiolib SHARED IMPORTED)
+set_target_properties(SDL_audiolib PROPERTIES
+    INTERFACE_INCLUDE_DIRECTORIES "${SDL_audiolib_INCLUDE_DIR}"
+    IMPORTED_LINK_INTERFACE_LANGUAGES "C"
+)
+set_target_properties(SDL_audiolib PROPERTIES
+    IMPORTED_LOCATION "${SDL_audiolib_LIBRARY}"
+)
diff -Nur devilutionX-1.4.0/CMake/FindSDL_image.cmake 
new/CMake/FindSDL_image.cmake
--- devilutionX-1.4.0/CMake/FindSDL_image.cmake 1970-01-01 01:00:00.000000000 
+0100
+++ new/CMake/FindSDL_image.cmake       2022-05-22 15:03:41.727854893 +0200
@@ -0,0 +1,83 @@
+# To the extent possible under law, the author(s) have dedicated all
+# copyright and related and neighboring rights to this software to the
+# public domain worldwide. This software is distributed without any warranty.
+#
+# You should have received a copy of the CC0 Public Domain Dedication
+# along with this software. If not, see
+#
+#     https://creativecommons.org/publicdomain/zero/1.0/
+#
+########################################################################
+# Tries to find the local SDL_image installation.
+#
+# Once done the following variables will be defined:
+#
+#   SDL_image_FOUND
+#   SDL_image_INCLUDE_DIR
+#   SDL_image_LIBRARY
+#
+# Furthermore an imported "SDL_image" target is created.
+#
+
+if(USE_SDL1)
+  set(XNAME "SDL")
+else()
+  set(XNAME "SDL2")
+endif()
+
+find_package(PkgConfig QUIET)
+if (PKG_CONFIG_FOUND)
+  pkg_check_modules(SDL_image_PKG QUIET ${XNAME}_image)
+endif()
+
+if(SDL_image_PKG STREQUAL "")
+  set(SDL_image_PKG ${XNMAE}_image)
+endif()
+    
+# Feed pkgconfig results (if found) into standard find_* to populate
+# the right CMake cache variables
+find_path(SDL_image_INCLUDE_DIR ${XNAME}/SDL_image.h
+    HINTS ${SDL_image_PKG_INCLUDE_DIRS}
+)
+find_library(SDL_image_LIBRARY NAMES ${SDL_image_PKG_LIBRARIES}
+    HINTS ${SDL_image_PKG_LIBRARY_DIRS}
+)
+
+
+########################################################################
+# common stuff
+
+if (SDL_image_INCLUDE_DIR)
+  set(_VERSION_HEADER "${SDL_image_INCLUDE_DIR}/${XNAME}/SDL_image.h")
+  if(EXISTS "${_VERSION_HEADER}")
+        file(READ "${_VERSION_HEADER}" _VERSION_HEADER_CONTENT)
+    string(REGEX REPLACE ".*define[ \t]+SDL_IMAGE_MAJOR_VERSION[ 
\t]+([0-9]+).*" "\\1" major "${_VERSION_HEADER_CONTENT}")
+    string(REGEX REPLACE ".*define[ \t]+SDL_IMAGE_MINOR_VERSION[ 
\t]+([0-9]+).*" "\\1" minor "${_VERSION_HEADER_CONTENT}")
+    string(REGEX REPLACE ".*define[ \t]+SDL_IMAGE_PATCHLEVEL[ \t]+([0-9]+).*" 
"\\1" patch "${_VERSION_HEADER_CONTENT}")
+    set(SDL_image_VERSION_STRING "${major}.${minor}.${patch}")
+    endif()
+endif()
+
+# communicate results
+include(FindPackageHandleStandardArgs)
+find_package_handle_standard_args(
+    SDL_image # The name must be either uppercase or match the filename case.
+    REQUIRED_VARS
+        SDL_image_LIBRARY
+        SDL_image_INCLUDE_DIR
+    VERSION_VAR
+       SDL_image_VERSION_STRING
+)
+
+# mark file paths as advanced
+mark_as_advanced(SDL_image_INCLUDE_DIR)
+mark_as_advanced(SDL_image_LIBRARY_RELEASE)
+
+add_library(SDL_image SHARED IMPORTED)
+set_target_properties(SDL_image PROPERTIES
+    INTERFACE_INCLUDE_DIRECTORIES "${SDL_image_INCLUDE_DIR}"
+    IMPORTED_LINK_INTERFACE_LANGUAGES "C"
+)
+set_target_properties(SDL_image PROPERTIES
+    IMPORTED_LOCATION "${SDL_image_LIBRARY}"
+)
diff -Nur devilutionX-1.4.0/CMakeLists.txt new/CMakeLists.txt
--- devilutionX-1.4.0/CMakeLists.txt    2022-04-13 23:33:49.000000000 +0200
+++ new/CMakeLists.txt  2022-05-22 15:04:49.476186098 +0200
@@ -154,6 +154,8 @@
   set(DISABLE_TCP ON)
   set(DISABLE_ZERO_TIER ON)
   set(PACKET_ENCRYPTION OFF)
+else()
+  option(DEVILUTIONX_SYSTEM_ASIO "Use system-provided asio" OFF)
 endif()
 
 find_program(CCACHE_PROGRAM ccache)

Reply via email to