From 89c730dbf3da9bc72884c390fa8c38ff29f54809 Mon Sep 17 00:00:00 2001 From: Stephen White Date: Mon, 7 Feb 2022 16:05:36 +0000 Subject: [PATCH] GLSL: only build glslang if we're building samples. We'll need this to build the GLSL backend in Dawn, since we don't want glslang there. Bug: tint:1217 Change-Id: Ied44ca89286c1d53a2e58a7083f0bfb859976770 Reviewed-on: https://dawn-review.googlesource.com/c/tint/+/79500 Kokoro: Kokoro Reviewed-by: Ben Clayton Commit-Queue: Stephen White --- third_party/CMakeLists.txt | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) 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()