Add option ENABLE_CTEST to skip testing
This commit is contained in:
parent
b131630e7c
commit
3b8d94f422
1 changed files with 8 additions and 3 deletions
|
|
@ -41,6 +41,7 @@ CMAKE_DEPENDENT_OPTION(ENABLE_HLSL "Enables HLSL input support" ON "NOT ENABLE_G
|
||||||
|
|
||||||
option(ENABLE_OPT "Enables spirv-opt capability if present" ON)
|
option(ENABLE_OPT "Enables spirv-opt capability if present" ON)
|
||||||
option(ENABLE_PCH "Enables Precompiled header" ON)
|
option(ENABLE_PCH "Enables Precompiled header" ON)
|
||||||
|
option(ENABLE_CTEST "Enables testing" ON)
|
||||||
|
|
||||||
if(CMAKE_INSTALL_PREFIX_INITIALIZED_TO_DEFAULT AND WIN32)
|
if(CMAKE_INSTALL_PREFIX_INITIALIZED_TO_DEFAULT AND WIN32)
|
||||||
set(CMAKE_INSTALL_PREFIX "install" CACHE STRING "..." FORCE)
|
set(CMAKE_INSTALL_PREFIX "install" CACHE STRING "..." FORCE)
|
||||||
|
|
@ -67,8 +68,10 @@ macro(glslang_pch SRCS PCHCPP)
|
||||||
endmacro(glslang_pch)
|
endmacro(glslang_pch)
|
||||||
|
|
||||||
project(glslang)
|
project(glslang)
|
||||||
# make testing optional
|
|
||||||
|
if(ENABLE_CTEST)
|
||||||
include(CTest)
|
include(CTest)
|
||||||
|
endif()
|
||||||
|
|
||||||
if(ENABLE_HLSL)
|
if(ENABLE_HLSL)
|
||||||
add_definitions(-DENABLE_HLSL)
|
add_definitions(-DENABLE_HLSL)
|
||||||
|
|
@ -183,7 +186,9 @@ add_subdirectory(SPIRV)
|
||||||
if(ENABLE_HLSL)
|
if(ENABLE_HLSL)
|
||||||
add_subdirectory(hlsl)
|
add_subdirectory(hlsl)
|
||||||
endif(ENABLE_HLSL)
|
endif(ENABLE_HLSL)
|
||||||
|
if(ENABLE_CTEST)
|
||||||
add_subdirectory(gtests)
|
add_subdirectory(gtests)
|
||||||
|
endif()
|
||||||
|
|
||||||
if(BUILD_TESTING)
|
if(BUILD_TESTING)
|
||||||
# glslang-testsuite runs a bash script on Windows.
|
# glslang-testsuite runs a bash script on Windows.
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue