From e8daed1482f924ec3d39235a1aeb37cf7fe90603 Mon Sep 17 00:00:00 2001 From: Jarrod Norwell Date: Wed, 6 Mar 2024 03:27:06 +0800 Subject: [PATCH] Updated CMakeLists.txt --- CMakeLists.txt | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index ca7e3b6..dd6d0fd 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -88,8 +88,10 @@ enable_testing(true) if (SIRIT_USE_SYSTEM_SPIRV_HEADERS) find_package(SPIRV-Headers REQUIRED) else() - add_subdirectory(externals/SPIRV-Headers EXCLUDE_FROM_ALL) - add_library(SPIRV-Headers::SPIRV-Headers ALIAS SPIRV-Headers) + if (NOT TARGET SPIRV-Headers::SPIRV::Headers) + add_subdirectory(externals/SPIRV-Headers EXCLUDE_FROM_ALL) + add_library(SPIRV-Headers::SPIRV-Headers ALIAS SPIRV-Headers) + endif() endif() # Sirit project files