Improve SPIRV-Headers loading behavior

This commit is contained in:
darktux
2024-04-08 00:30:51 +02:00
parent 68ced8ab4f
commit 00dd7295a3
2 changed files with 6 additions and 9 deletions

View File

@@ -12,7 +12,6 @@ endif()
# Sirit project options
option(SIRIT_TESTS "Build tests" OFF)
option(SIRIT_USE_SYSTEM_SPIRV_HEADERS "Use system SPIR-V headers" OFF)
# Default to a Release build
if (NOT CMAKE_BUILD_TYPE)
@@ -84,14 +83,6 @@ endif()
# Enable unit-testing.
enable_testing(true)
# SPIR-V headers
if (SIRIT_USE_SYSTEM_SPIRV_HEADERS)
find_package(SPIRV-Headers REQUIRED)
else()
add_subdirectory(${CMAKE_SOURCE_DIR}/externals/SPIRV-Headers externals/SPIRV-Headers EXCLUDE_FROM_ALL)
add_library(SPIRV-Headers::SPIRV-Headers ALIAS SPIRV-Headers)
endif()
# Sirit project files
add_subdirectory(src)
if (SIRIT_TESTS)