cmake: Cleanup usage of option
By default option is OFF
This commit is contained in:
parent
4efde4c4c1
commit
5fcac839ca
1 changed files with 7 additions and 8 deletions
|
|
@ -42,7 +42,7 @@ include(CMakePackageConfigHelpers)
|
|||
# Needed for CMAKE_DEPENDENT_OPTION macro
|
||||
include(CMakeDependentOption)
|
||||
|
||||
option(BUILD_SHARED_LIBS "Build Shared Libraries" OFF)
|
||||
option(BUILD_SHARED_LIBS "Build Shared Libraries")
|
||||
option(BUILD_EXTERNAL "Build external dependencies in /External" ON)
|
||||
|
||||
set(LIB_TYPE STATIC)
|
||||
|
|
@ -59,7 +59,7 @@ if ("${CMAKE_BUILD_TYPE}" STREQUAL "")
|
|||
set(CMAKE_BUILD_TYPE "Debug")
|
||||
endif()
|
||||
|
||||
option(SKIP_GLSLANG_INSTALL "Skip installation" ${SKIP_GLSLANG_INSTALL})
|
||||
option(SKIP_GLSLANG_INSTALL "Skip installation")
|
||||
if(NOT ${SKIP_GLSLANG_INSTALL})
|
||||
set(ENABLE_GLSLANG_INSTALL ON)
|
||||
endif()
|
||||
|
|
@ -67,8 +67,7 @@ option(ENABLE_SPVREMAPPER "Enables building of SPVRemapper" ON)
|
|||
|
||||
option(ENABLE_GLSLANG_BINARIES "Builds glslang and spirv-remap" ON)
|
||||
|
||||
option(ENABLE_GLSLANG_JS
|
||||
"If using Emscripten, build glslang.js. Otherwise, builds a sample executable for binary-size testing." OFF)
|
||||
option(ENABLE_GLSLANG_JS "If using Emscripten, build glslang.js. Otherwise, builds a sample executable for binary-size testing.")
|
||||
CMAKE_DEPENDENT_OPTION(ENABLE_EMSCRIPTEN_SINGLE_FILE
|
||||
"If using Emscripten, enables SINGLE_FILE build"
|
||||
OFF "ENABLE_GLSLANG_JS AND EMSCRIPTEN"
|
||||
|
|
@ -79,14 +78,14 @@ CMAKE_DEPENDENT_OPTION(ENABLE_EMSCRIPTEN_ENVIRONMENT_NODE
|
|||
OFF)
|
||||
|
||||
option(ENABLE_HLSL "Enables HLSL input support" ON)
|
||||
option(ENABLE_RTTI "Enables RTTI" OFF)
|
||||
option(ENABLE_EXCEPTIONS "Enables Exceptions" OFF)
|
||||
option(ENABLE_RTTI "Enables RTTI")
|
||||
option(ENABLE_EXCEPTIONS "Enables Exceptions")
|
||||
option(ENABLE_OPT "Enables spirv-opt capability if present" ON)
|
||||
|
||||
if(MINGW OR (CMAKE_SYSTEM_NAME STREQUAL "Darwin" AND ${CMAKE_CXX_COMPILER_ID} MATCHES "GNU"))
|
||||
# Workaround for CMake behavior on Mac OS with gcc, cmake generates -Xarch_* arguments
|
||||
# which gcc rejects
|
||||
option(ENABLE_PCH "Enables Precompiled header" OFF)
|
||||
option(ENABLE_PCH "Enables Precompiled header")
|
||||
else()
|
||||
option(ENABLE_PCH "Enables Precompiled header" ON)
|
||||
endif()
|
||||
|
|
@ -263,7 +262,7 @@ if(BUILD_EXTERNAL AND IS_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/External)
|
|||
add_subdirectory(External)
|
||||
endif()
|
||||
|
||||
option(ALLOW_EXTERNAL_SPIRV_TOOLS "Allows to build against installed SPIRV-Tools-opt" OFF)
|
||||
option(ALLOW_EXTERNAL_SPIRV_TOOLS "Allows to build against installed SPIRV-Tools-opt")
|
||||
if(NOT TARGET SPIRV-Tools-opt)
|
||||
if(ALLOW_EXTERNAL_SPIRV_TOOLS)
|
||||
# Look for external SPIR-V Tools build, if not building in-tree
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue