diff --git a/third_party/CMakeLists.txt b/third_party/CMakeLists.txt index 47d6664640..90862eebdb 100644 --- a/third_party/CMakeLists.txt +++ b/third_party/CMakeLists.txt @@ -47,5 +47,7 @@ endif() if(${TINT_BUILD_GLSL_WRITER}) set(SPIRV-Headers_SOURCE_DIR "${TINT_THIRD_PARTY_DIR}/glslang") - add_subdirectory("${TINT_THIRD_PARTY_DIR}/glslang" "${CMAKE_BINARY_DIR}/third_party/glslang" EXCLUDE_FROM_ALL) + if(${TINT_BUILD_SAMPLES}) + add_subdirectory("${TINT_THIRD_PARTY_DIR}/glslang" "${CMAKE_BINARY_DIR}/third_party/glslang" EXCLUDE_FROM_ALL) + endif() endif()