Merge pull request #14031 from TellowKrinkle/GlslangFix

CMake: Fix bundled glslang
This commit is contained in:
Jordan Woyak 2025-10-26 15:42:36 -05:00 committed by GitHub
commit c22a483431
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
5 changed files with 4 additions and 14 deletions

View File

@ -653,14 +653,8 @@ dolphin_find_optional_system_library_pkgconfig(FMT
add_subdirectory(Externals/imgui)
add_subdirectory(Externals/implot)
# A few distributions (mainly Debian-based ones) distribute glslang without linking it against SPIRV-Tools
find_package(SPIRV-Tools)
if(SPIRV-Tools_FOUND)
dolphin_find_optional_system_library(glslang Externals/glslang 15.0)
target_link_libraries(glslang::glslang INTERFACE SPIRV-Tools)
else()
dolphin_add_bundled_library(glslang OFF Externals/glslang)
endif()
dolphin_find_optional_system_library(glslang Externals/glslang 15.0)
# SPIRV-Cross is used on Windows for GLSL to HLSL conversion for the Direct3D 11 and Direct3D 12
# video backends, and on Apple devices for the Metal video backend.
if(WIN32 OR APPLE)

View File

@ -12,8 +12,6 @@ PUBLIC
common
videocommon
spirv_cross
PRIVATE
glslang::glslang
)
if(MSVC)

View File

@ -35,7 +35,6 @@ PUBLIC
videocommon
PRIVATE
spirv_cross
glslang::glslang
${FOUNDATION_LIBRARY}
${METAL_LIBRARY}
${QUARTZCORE_LIBRARY}

View File

@ -43,8 +43,6 @@ PUBLIC
videocommon
PRIVATE
# Link against glslang, the other necessary libraries are referenced by the executable.
glslang::glslang
xxhash::xxhash
)

View File

@ -218,13 +218,14 @@ add_library(videocommon
target_link_libraries(videocommon
PUBLIC
core
glslang::glslang
PRIVATE
fmt::fmt
spng::spng
xxhash::xxhash
imgui
implot
glslang::glslang
glslang::SPIRV
tinygltf
)