SHA256
1
0
forked from pool/gzdoom
gzdoom/gzdoom-vulkan.patch

68 lines
2.7 KiB
Diff
Raw Normal View History

From: Jan Engelhardt <jengelh@inai.de>
Date: 2019-04-13 15:02:22.799297208 +0200
Use Vulkan system libraries instead of bundled code.
---
CMakeLists.txt | 3 ---
src/CMakeLists.txt | 2 +-
src/common/rendering/vulkan/shaders/vk_shader.cpp | 2 +-
src/common/rendering/vulkan/system/vk_builders.cpp | 4 ++--
4 files changed, 4 insertions(+), 7 deletions(-)
Index: gzdoom-g4.4.0/CMakeLists.txt
===================================================================
--- gzdoom-g4.4.0.orig/CMakeLists.txt
+++ gzdoom-g4.4.0/CMakeLists.txt
@@ -307,9 +307,6 @@ option(FORCE_INTERNAL_ASMJIT "Use intern
mark_as_advanced( FORCE_INTERNAL_ASMJIT )
if (HAVE_VULKAN)
- add_subdirectory( libraries/glslang/glslang)
- add_subdirectory( libraries/glslang/spirv )
- add_subdirectory( libraries/glslang/OGLCompilersDLL )
endif()
if( ZLIB_FOUND AND NOT FORCE_INTERNAL_ZLIB )
Index: gzdoom-g4.4.0/src/CMakeLists.txt
===================================================================
--- gzdoom-g4.4.0.orig/src/CMakeLists.txt
+++ gzdoom-g4.4.0/src/CMakeLists.txt
@@ -435,7 +435,7 @@ add_custom_target( revision_check ALL
set( ZDOOM_LIBS ${ZDOOM_LIBS} "${ZLIB_LIBRARIES}" "${JPEG_LIBRARIES}" "${BZIP2_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_DIRS}" "${JPEG_INCLUDE_DIR}" "${ZMUSIC_INCLUDE_DIR}" )
Index: gzdoom-g4.4.0/src/common/rendering/vulkan/shaders/vk_shader.cpp
===================================================================
--- gzdoom-g4.4.0.orig/src/common/rendering/vulkan/shaders/vk_shader.cpp
+++ gzdoom-g4.4.0/src/common/rendering/vulkan/shaders/vk_shader.cpp
@@ -25,7 +25,7 @@
#include "hw_shaderpatcher.h"
#include "filesystem.h"
#include "engineerrors.h"
-#include <ShaderLang.h>
+#include <glslang/Public/ShaderLang.h>
VkShaderManager::VkShaderManager(VulkanDevice *device) : device(device)
{
Index: gzdoom-g4.4.0/src/common/rendering/vulkan/system/vk_builders.cpp
===================================================================
--- gzdoom-g4.4.0.orig/src/common/rendering/vulkan/system/vk_builders.cpp
+++ gzdoom-g4.4.0/src/common/rendering/vulkan/system/vk_builders.cpp
@@ -23,8 +23,8 @@
#include "vk_builders.h"
#include "engineerrors.h"
#include "renderstyle.h"
-#include <ShaderLang.h>
-#include <GlslangToSpv.h>
+#include <glslang/Public/ShaderLang.h>
+#include <SPIRV/GlslangToSpv.h>
static const TBuiltInResource DefaultTBuiltInResource = {
/* .MaxLights = */ 32,