forked from pool/gzdoom
Jan Engelhardt
155fd3f2e8
OBS-URL: https://build.opensuse.org/package/show/games/gzdoom?expand=0&rev=44
79 lines
2.8 KiB
Diff
79 lines
2.8 KiB
Diff
From: Jan Engelhardt <jengelh@inai.de>
|
|
Date: 2018-01-08 13:48:59+0100
|
|
|
|
Use LZMA system libraries instead of bundled code.
|
|
|
|
---
|
|
CMakeLists.txt | 4 ++--
|
|
src/CMakeLists.txt | 4 ++--
|
|
tools/zipdir/CMakeLists.txt | 4 ++--
|
|
3 files changed, 6 insertions(+), 6 deletions(-)
|
|
|
|
Index: gzdoom-g4.4.0/CMakeLists.txt
|
|
===================================================================
|
|
--- gzdoom-g4.4.0.orig/CMakeLists.txt
|
|
+++ gzdoom-g4.4.0/CMakeLists.txt
|
|
@@ -12,6 +12,7 @@ endif()
|
|
|
|
list( APPEND CMAKE_MODULE_PATH ${CMAKE_SOURCE_DIR}/cmake )
|
|
include( FindPackageHandleStandardArgs )
|
|
+include(FindPkgConfig)
|
|
|
|
# Support cross compiling
|
|
option( FORCE_CROSSCOMPILE "Turn on cross compiling." NO )
|
|
@@ -369,7 +370,7 @@ else()
|
|
endif()
|
|
|
|
|
|
-set( LZMA_INCLUDE_DIR "${CMAKE_CURRENT_SOURCE_DIR}/libraries/lzma/C" )
|
|
+pkg_check_modules(LZMA REQUIRED clzma)
|
|
|
|
if( NOT CMAKE_CROSSCOMPILING )
|
|
if( NOT CROSS_EXPORTS )
|
|
@@ -389,7 +390,6 @@ install(DIRECTORY docs/
|
|
|
|
option( DYN_OPENAL "Dynamically load OpenAL" ON )
|
|
|
|
-add_subdirectory( libraries/lzma )
|
|
add_subdirectory( tools )
|
|
add_subdirectory( libraries/gdtoa )
|
|
add_subdirectory( wadsrc )
|
|
Index: gzdoom-g4.4.0/src/CMakeLists.txt
|
|
===================================================================
|
|
--- gzdoom-g4.4.0.orig/src/CMakeLists.txt
|
|
+++ gzdoom-g4.4.0/src/CMakeLists.txt
|
|
@@ -437,7 +437,7 @@ set( ZDOOM_LIBS ${ZDOOM_LIBS} "${ZLIB_LI
|
|
if (HAVE_VULKAN)
|
|
set( ZDOOM_LIBS ${ZDOOM_LIBS} "glslang" "SPIRV" "OGLCompiler")
|
|
endif()
|
|
-include_directories( "${ZLIB_INCLUDE_DIR}" "${BZIP2_INCLUDE_DIR}" "${LZMA_INCLUDE_DIR}" "${JPEG_INCLUDE_DIR}" "${ZMUSIC_INCLUDE_DIR}" )
|
|
+include_directories( "${ZLIB_INCLUDE_DIR}" "${BZIP2_INCLUDE_DIR}" "${LZMA_INCLUDE_DIRS}" "${JPEG_INCLUDE_DIR}" "${ZMUSIC_INCLUDE_DIR}" )
|
|
|
|
if( ${HAVE_VM_JIT} )
|
|
add_definitions( -DHAVE_VM_JIT )
|
|
@@ -1238,7 +1238,7 @@ if( UNIX )
|
|
endif()
|
|
endif()
|
|
|
|
-target_link_libraries( zdoom ${ZDOOM_LIBS} gdtoa lzma ${ZMUSIC_LIBRARIES} )
|
|
+target_link_libraries( zdoom ${ZDOOM_LIBS} gdtoa ${LZMA_LIBRARIES} ${ZMUSIC_LIBRARIES} )
|
|
|
|
include_directories( .
|
|
common/audio/sound
|
|
Index: gzdoom-g4.4.0/tools/zipdir/CMakeLists.txt
|
|
===================================================================
|
|
--- gzdoom-g4.4.0.orig/tools/zipdir/CMakeLists.txt
|
|
+++ gzdoom-g4.4.0/tools/zipdir/CMakeLists.txt
|
|
@@ -1,9 +1,9 @@
|
|
cmake_minimum_required( VERSION 2.8.7 )
|
|
|
|
if( NOT CMAKE_CROSSCOMPILING )
|
|
- include_directories( "${ZLIB_INCLUDE_DIR}" "${BZIP2_INCLUDE_DIR}" "${LZMA_INCLUDE_DIR}" )
|
|
+ include_directories( "${ZLIB_INCLUDE_DIR}" "${BZIP2_INCLUDE_DIR}" "${LZMA_INCLUDE_DIRS}" )
|
|
add_executable( zipdir
|
|
zipdir.c )
|
|
- target_link_libraries( zipdir ${ZLIB_LIBRARIES} ${BZIP2_LIBRARIES} lzma )
|
|
+ target_link_libraries( zipdir ${ZLIB_LIBRARIES} ${BZIP2_LIBRARIES} ${LZMA_LDFLAGS})
|
|
set( CROSS_EXPORTS ${CROSS_EXPORTS} zipdir PARENT_SCOPE )
|
|
endif()
|