- Folded gzdoom-asmjit.patch into gzdoom-staticlibs.patch.
- Rename gzdoom-lzma.patch to gzdoom-systemlibs.patch. OBS-URL: https://build.opensuse.org/package/show/games/gzdoom?expand=0&rev=22
This commit is contained in:
parent
45948f8f0e
commit
7c13bdb0ef
@ -1,22 +0,0 @@
|
||||
From: Jan Engelhardt <jengelh@inai.de>
|
||||
Date: 2019-01-03 14:48:11.831267534 +0100
|
||||
|
||||
Nothing else uses asmjit at this time, so save on the extra library.
|
||||
(`make install` also misses installing it as a shared library.)
|
||||
---
|
||||
asmjit/CMakeLists.txt | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
Index: gzdoom-3.7.1/asmjit/CMakeLists.txt
|
||||
===================================================================
|
||||
--- gzdoom-3.7.1.orig/asmjit/CMakeLists.txt
|
||||
+++ gzdoom-3.7.1/asmjit/CMakeLists.txt
|
||||
@@ -97,7 +97,7 @@ set(ASMJIT_SRCS
|
||||
asmjit/x86/x86regalloc.cpp
|
||||
)
|
||||
|
||||
-add_library(${ASMJITNAME} ${ASMJIT_SRCS} ${ASMJIT_PUBLIC_HDRS})
|
||||
+add_library(${ASMJITNAME} STATIC ${ASMJIT_SRCS} ${ASMJIT_PUBLIC_HDRS})
|
||||
|
||||
set_target_properties(${ASMJITNAME} PROPERTIES OUTPUT_NAME asmjit)
|
||||
|
@ -1,73 +0,0 @@
|
||||
---
|
||||
CMakeLists.txt | 4 ++--
|
||||
src/CMakeLists.txt | 4 ++--
|
||||
tools/zipdir/CMakeLists.txt | 4 ++--
|
||||
3 files changed, 6 insertions(+), 6 deletions(-)
|
||||
|
||||
Index: gzdoom-4.0.0/CMakeLists.txt
|
||||
===================================================================
|
||||
--- gzdoom-4.0.0.orig/CMakeLists.txt
|
||||
+++ gzdoom-4.0.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 )
|
||||
@@ -355,7 +356,7 @@ else()
|
||||
set( GME_LIBRARIES gme )
|
||||
endif()
|
||||
|
||||
-set( LZMA_INCLUDE_DIR "${CMAKE_CURRENT_SOURCE_DIR}/lzma/C" )
|
||||
+pkg_check_modules(LZMA REQUIRED clzma)
|
||||
|
||||
if( NOT CMAKE_CROSSCOMPILING )
|
||||
if( NOT CROSS_EXPORTS )
|
||||
@@ -373,7 +374,6 @@ install(DIRECTORY docs/
|
||||
DESTINATION ${INSTALL_DOCS_PATH}
|
||||
COMPONENT "Documentation")
|
||||
|
||||
-add_subdirectory( lzma )
|
||||
add_subdirectory( tools )
|
||||
add_subdirectory( dumb )
|
||||
add_subdirectory( gdtoa )
|
||||
Index: gzdoom-4.0.0/src/CMakeLists.txt
|
||||
===================================================================
|
||||
--- gzdoom-4.0.0.orig/src/CMakeLists.txt
|
||||
+++ gzdoom-4.0.0/src/CMakeLists.txt
|
||||
@@ -467,7 +467,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}" "${GME_INCLUDE_DIR}" )
|
||||
+include_directories( "${ZLIB_INCLUDE_DIR}" "${BZIP2_INCLUDE_DIR}" "${LZMA_INCLUDE_DIRS}" "${JPEG_INCLUDE_DIR}" "${GME_INCLUDE_DIR}" )
|
||||
|
||||
if( ${HAVE_VM_JIT} )
|
||||
add_definitions( -DHAVE_VM_JIT )
|
||||
@@ -1370,7 +1370,7 @@ if( UNIX )
|
||||
endif()
|
||||
endif()
|
||||
|
||||
-target_link_libraries( zdoom ${ZDOOM_LIBS} gdtoa dumb lzma )
|
||||
+target_link_libraries( zdoom ${ZDOOM_LIBS} gdtoa dumb ${LZMA_LIBRARIES})
|
||||
|
||||
include_directories( .
|
||||
g_statusbar
|
||||
Index: gzdoom-4.0.0/tools/zipdir/CMakeLists.txt
|
||||
===================================================================
|
||||
--- gzdoom-4.0.0.orig/tools/zipdir/CMakeLists.txt
|
||||
+++ gzdoom-4.0.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()
|
@ -7,13 +7,27 @@ cmake_install. Some of the code is also an older version and may not
|
||||
necessarily be suitable for getting switched out by system library copies.
|
||||
|
||||
---
|
||||
asmjit/CMakeLists.txt | 2 +-
|
||||
dumb/CMakeLists.txt | 2 +-
|
||||
gdtoa/CMakeLists.txt | 2 +-
|
||||
glslang/glslang/CMakeLists.txt | 2 +-
|
||||
glslang/spirv/CMakeLists.txt | 4 ++--
|
||||
lzma/CMakeLists.txt | 2 +-
|
||||
5 files changed, 6 insertions(+), 6 deletions(-)
|
||||
6 files changed, 7 insertions(+), 7 deletions(-)
|
||||
|
||||
Index: gzdoom-4.0.0/asmjit/CMakeLists.txt
|
||||
===================================================================
|
||||
--- gzdoom-4.0.0.orig/asmjit/CMakeLists.txt
|
||||
+++ gzdoom-4.0.0/asmjit/CMakeLists.txt
|
||||
@@ -97,7 +97,7 @@ set(ASMJIT_SRCS
|
||||
asmjit/x86/x86regalloc.cpp
|
||||
)
|
||||
|
||||
-add_library(${ASMJITNAME} ${ASMJIT_SRCS} ${ASMJIT_PUBLIC_HDRS})
|
||||
+add_library(${ASMJITNAME} STATIC ${ASMJIT_SRCS} ${ASMJIT_PUBLIC_HDRS})
|
||||
|
||||
set_target_properties(${ASMJITNAME} PROPERTIES OUTPUT_NAME asmjit)
|
||||
|
||||
Index: gzdoom-4.0.0/dumb/CMakeLists.txt
|
||||
===================================================================
|
||||
--- gzdoom-4.0.0.orig/dumb/CMakeLists.txt
|
||||
|
146
gzdoom-systemlibs.patch
Normal file
146
gzdoom-systemlibs.patch
Normal file
@ -0,0 +1,146 @@
|
||||
From: Jan Engelhardt <jengelh@inai.de>
|
||||
Date: 2018-01-08 13:48:59+0100
|
||||
|
||||
Use system libraries instead of bundled code.
|
||||
|
||||
---
|
||||
CMakeLists.txt | 7 ++-----
|
||||
src/CMakeLists.txt | 6 +++---
|
||||
src/rendering/vulkan/shaders/vk_shader.cpp | 2 +-
|
||||
src/rendering/vulkan/system/vk_builders.cpp | 22 +++++++++++-----------
|
||||
tools/zipdir/CMakeLists.txt | 4 ++--
|
||||
5 files changed, 19 insertions(+), 22 deletions(-)
|
||||
|
||||
Index: gzdoom-4.0.0/CMakeLists.txt
|
||||
===================================================================
|
||||
--- gzdoom-4.0.0.orig/CMakeLists.txt
|
||||
+++ gzdoom-4.0.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 )
|
||||
@@ -286,9 +287,6 @@ option(FORCE_INTERNAL_ASMJIT "Use intern
|
||||
mark_as_advanced( FORCE_INTERNAL_ASMJIT )
|
||||
|
||||
if (HAVE_VULKAN)
|
||||
- add_subdirectory( glslang/glslang)
|
||||
- add_subdirectory( glslang/spirv )
|
||||
- add_subdirectory( glslang/OGLCompilersDLL )
|
||||
endif()
|
||||
|
||||
# Fast math flags, required by some subprojects
|
||||
@@ -355,7 +353,7 @@ else()
|
||||
set( GME_LIBRARIES gme )
|
||||
endif()
|
||||
|
||||
-set( LZMA_INCLUDE_DIR "${CMAKE_CURRENT_SOURCE_DIR}/lzma/C" )
|
||||
+pkg_check_modules(LZMA REQUIRED clzma)
|
||||
|
||||
if( NOT CMAKE_CROSSCOMPILING )
|
||||
if( NOT CROSS_EXPORTS )
|
||||
@@ -373,7 +371,6 @@ install(DIRECTORY docs/
|
||||
DESTINATION ${INSTALL_DOCS_PATH}
|
||||
COMPONENT "Documentation")
|
||||
|
||||
-add_subdirectory( lzma )
|
||||
add_subdirectory( tools )
|
||||
add_subdirectory( dumb )
|
||||
add_subdirectory( gdtoa )
|
||||
Index: gzdoom-4.0.0/src/CMakeLists.txt
|
||||
===================================================================
|
||||
--- gzdoom-4.0.0.orig/src/CMakeLists.txt
|
||||
+++ gzdoom-4.0.0/src/CMakeLists.txt
|
||||
@@ -465,9 +465,9 @@ add_custom_target( revision_check ALL
|
||||
message( STATUS "Fluid synth libs: ${FLUIDSYNTH_LIBRARIES}" )
|
||||
set( ZDOOM_LIBS ${ZDOOM_LIBS} "${ZLIB_LIBRARIES}" "${JPEG_LIBRARIES}" "${BZIP2_LIBRARIES}" "${GME_LIBRARIES}" "${CMAKE_DL_LIBS}" )
|
||||
if (HAVE_VULKAN)
|
||||
- set( ZDOOM_LIBS ${ZDOOM_LIBS} "glslang" "SPIRV" "OGLCompiler")
|
||||
+ set( ZDOOM_LIBS ${ZDOOM_LIBS} -lglslang -lSPIRV -lOGLCompiler)
|
||||
endif()
|
||||
-include_directories( "${ZLIB_INCLUDE_DIR}" "${BZIP2_INCLUDE_DIR}" "${LZMA_INCLUDE_DIR}" "${JPEG_INCLUDE_DIR}" "${GME_INCLUDE_DIR}" )
|
||||
+include_directories( "${ZLIB_INCLUDE_DIR}" "${BZIP2_INCLUDE_DIR}" "${LZMA_INCLUDE_DIRS}" "${JPEG_INCLUDE_DIR}" "${GME_INCLUDE_DIR}" )
|
||||
|
||||
if( ${HAVE_VM_JIT} )
|
||||
add_definitions( -DHAVE_VM_JIT )
|
||||
@@ -1370,7 +1370,7 @@ if( UNIX )
|
||||
endif()
|
||||
endif()
|
||||
|
||||
-target_link_libraries( zdoom ${ZDOOM_LIBS} gdtoa dumb lzma )
|
||||
+target_link_libraries( zdoom ${ZDOOM_LIBS} gdtoa dumb ${LZMA_LIBRARIES})
|
||||
|
||||
include_directories( .
|
||||
g_statusbar
|
||||
Index: gzdoom-4.0.0/src/rendering/vulkan/shaders/vk_shader.cpp
|
||||
===================================================================
|
||||
--- gzdoom-4.0.0.orig/src/rendering/vulkan/shaders/vk_shader.cpp
|
||||
+++ gzdoom-4.0.0/src/rendering/vulkan/shaders/vk_shader.cpp
|
||||
@@ -4,7 +4,7 @@
|
||||
#include "hwrenderer/utility/hw_shaderpatcher.h"
|
||||
#include "w_wad.h"
|
||||
#include "doomerrors.h"
|
||||
-#include <ShaderLang.h>
|
||||
+#include <glslang/Public/ShaderLang.h>
|
||||
|
||||
VkShaderManager::VkShaderManager(VulkanDevice *device) : device(device)
|
||||
{
|
||||
Index: gzdoom-4.0.0/src/rendering/vulkan/system/vk_builders.cpp
|
||||
===================================================================
|
||||
--- gzdoom-4.0.0.orig/src/rendering/vulkan/system/vk_builders.cpp
|
||||
+++ gzdoom-4.0.0/src/rendering/vulkan/system/vk_builders.cpp
|
||||
@@ -2,8 +2,8 @@
|
||||
#include "vk_builders.h"
|
||||
#include "doomerrors.h"
|
||||
#include "r_data/renderstyle.h"
|
||||
-#include <ShaderLang.h>
|
||||
-#include <GlslangToSpv.h>
|
||||
+#include <glslang/Public/ShaderLang.h>
|
||||
+#include <SPIRV/GlslangToSpv.h>
|
||||
|
||||
static const TBuiltInResource DefaultTBuiltInResource = {
|
||||
/* .MaxLights = */ 32,
|
||||
@@ -89,15 +89,15 @@ static const TBuiltInResource DefaultTBu
|
||||
/* .MaxCullDistances = */ 8,
|
||||
/* .MaxCombinedClipAndCullDistances = */ 8,
|
||||
/* .MaxSamples = */ 4,
|
||||
-// /* .maxMeshOutputVerticesNV = */ 256,
|
||||
-// /* .maxMeshOutputPrimitivesNV = */ 512,
|
||||
-// /* .maxMeshWorkGroupSizeX_NV = */ 32,
|
||||
-// /* .maxMeshWorkGroupSizeY_NV = */ 1,
|
||||
-// /* .maxMeshWorkGroupSizeZ_NV = */ 1,
|
||||
-// /* .maxTaskWorkGroupSizeX_NV = */ 32,
|
||||
-// /* .maxTaskWorkGroupSizeY_NV = */ 1,
|
||||
-// /* .maxTaskWorkGroupSizeZ_NV = */ 1,
|
||||
-// /* .maxMeshViewCountNV = */ 4,
|
||||
+ /* .maxMeshOutputVerticesNV = */ 256,
|
||||
+ /* .maxMeshOutputPrimitivesNV = */ 512,
|
||||
+ /* .maxMeshWorkGroupSizeX_NV = */ 32,
|
||||
+ /* .maxMeshWorkGroupSizeY_NV = */ 1,
|
||||
+ /* .maxMeshWorkGroupSizeZ_NV = */ 1,
|
||||
+ /* .maxTaskWorkGroupSizeX_NV = */ 32,
|
||||
+ /* .maxTaskWorkGroupSizeY_NV = */ 1,
|
||||
+ /* .maxTaskWorkGroupSizeZ_NV = */ 1,
|
||||
+ /* .maxMeshViewCountNV = */ 4,
|
||||
|
||||
/* .limits = */ {
|
||||
/* .nonInductiveForLoops = */ 1,
|
||||
Index: gzdoom-4.0.0/tools/zipdir/CMakeLists.txt
|
||||
===================================================================
|
||||
--- gzdoom-4.0.0.orig/tools/zipdir/CMakeLists.txt
|
||||
+++ gzdoom-4.0.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()
|
@ -14,6 +14,8 @@ Mon Apr 08 20:31:53 UTC 2019 - Jan Engelhardt <jengelh@inai.de>
|
||||
cheats without affecting the server
|
||||
* "wait" console commands no longer execute inside the level,
|
||||
and can run during intermissions and outside the game.
|
||||
- Folded gzdoom-asmjit.patch into gzdoom-staticlibs.patch.
|
||||
- Rename gzdoom-lzma.patch to gzdoom-systemlibs.patch.
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Wed Jan 23 15:22:45 UTC 2019 - Jan Engelhardt <jengelh@inai.de>
|
||||
|
11
gzdoom.spec
11
gzdoom.spec
@ -30,18 +30,17 @@ Patch1: gzdoom-waddir.patch
|
||||
Patch2: gzdoom-wadsrc-extra.patch
|
||||
Patch3: gzdoom-staticlibs.patch
|
||||
Patch4: fl2.patch
|
||||
Patch5: gzdoom-lzma.patch
|
||||
Patch6: gzdoom-asmjit.patch
|
||||
Patch5: gzdoom-systemlibs.patch
|
||||
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
||||
BuildRequires: cmake >= 2.8.7
|
||||
BuildRequires: gcc-c++
|
||||
#BuildRequires: glslang-devel
|
||||
BuildRequires: glslang-devel
|
||||
BuildRequires: libjpeg-devel
|
||||
BuildRequires: nasm
|
||||
BuildRequires: pkg-config
|
||||
BuildRequires: unzip
|
||||
BuildRequires: xz
|
||||
#BuildRequires: pkgconfig(SPIRV-Tools)
|
||||
BuildRequires: pkgconfig(SPIRV-Tools)
|
||||
BuildRequires: pkgconfig(bzip2)
|
||||
BuildRequires: pkgconfig(flac)
|
||||
BuildRequires: pkgconfig(fluidsynth)
|
||||
@ -52,6 +51,7 @@ BuildRequires: pkgconfig(libmpg123)
|
||||
BuildRequires: pkgconfig(openal)
|
||||
BuildRequires: pkgconfig(sdl2)
|
||||
BuildRequires: pkgconfig(sndfile)
|
||||
BuildRequires: pkgconfig(vulkan)
|
||||
BuildRequires: pkgconfig(zlib)
|
||||
%if 0%{?suse_version} >= 1500
|
||||
BuildRequires: pkgconfig(clzma) >= 17.01
|
||||
@ -85,7 +85,7 @@ GZDoom is a port (a modification) of the original Doom source code, featuring:
|
||||
|
||||
%prep
|
||||
%setup -q
|
||||
%patch -P 1 -P 2 -P 3 -P 4 -P 6 -p1
|
||||
%patch -P 1 -P 2 -P 3 -P 4 -p1
|
||||
|
||||
%if 0%{?suse_version} >= 1500
|
||||
%patch -P 5 -p1
|
||||
@ -93,6 +93,7 @@ GZDoom is a port (a modification) of the original Doom source code, featuring:
|
||||
perl -i -pe 's{__DATE__}{""}g' src/posix/sdl/i_main.cpp
|
||||
perl -i -pe 's{<unknown version>}{%version}g' \
|
||||
tools/updaterevision/updaterevision.c
|
||||
rm -Rfv glslang src/rendering/vulkan/thirdparty/vulkan
|
||||
|
||||
%build
|
||||
# We must not strip - %%debug_package will take care of it
|
||||
|
Loading…
Reference in New Issue
Block a user