From ae537310dc836485ce4e730239ad2828224d52d4 Mon Sep 17 00:00:00 2001 From: Ilya Lavrenov Date: Mon, 16 Jan 2023 10:50:17 +0400 Subject: [PATCH] Don't add samples subdirectory when both samples and tests are disabled (#14817) (#15122) --- CMakeLists.txt | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 37f336697f0..962ba046e90 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -107,7 +107,10 @@ endif() add_subdirectory(thirdparty) add_subdirectory(src) -add_subdirectory(samples) + +if(ENABLE_SAMPLES OR ENABLE_TESTS OR ENABLE_COMPILE_TOOL) + add_subdirectory(samples) +endif() # Enable interpreter backend for tests if (ENABLE_TESTS OR ENABLE_TEMPLATE)