From efc626235eaebbb92cbd53a6519cb3949e622010 Mon Sep 17 00:00:00 2001 From: Jakub Domagala Date: Wed, 10 Feb 2021 19:55:50 +0100 Subject: [PATCH 1/2] #1256: cmake: Create vt_trace_only option before creating trace-only CMake target --- CMakeLists.txt | 5 +++++ cmake/define_build_types.cmake | 5 ----- src/CMakeLists.txt | 3 +-- 3 files changed, 6 insertions(+), 7 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index a9ce7358b1..8f267c17a3 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -110,6 +110,11 @@ include(cmake/load_bundled_libraries.cmake) include(cmake/nvcc_no_deprecated_gpu_targets.cmake) +option(vt_trace_only "Build VT with trace-only mode enabled" ON) +if (vt_trace_only) + message(STATUS "Building additional target for VT in trace-only mode") +endif() + # Primary VT build add_subdirectory(src) diff --git a/cmake/define_build_types.cmake b/cmake/define_build_types.cmake index db7d76011c..94dac0363b 100644 --- a/cmake/define_build_types.cmake +++ b/cmake/define_build_types.cmake @@ -104,11 +104,6 @@ else() set(vt_feature_cmake_trace_enabled "0") endif() -option(vt_trace_only "Build VT with trace-only mode enabled" ON) -if (vt_trace_only) - message(STATUS "Building additional target for VT in trace-only mode") -endif() - # This will be set to 1 during generation of cmake config for vt-trace target set(vt_feature_cmake_trace_only "0") diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index 007b724788..ca03f50e05 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -252,13 +252,12 @@ link_target_with_vt( DEFAULT_LINK_SET ) -# Define and set up the different build types of VT - include(../cmake/trace_only_functions.cmake) if (vt_trace_only) create_trace_only_target() endif() +# Define and set up the different build types of VT include(../cmake/define_build_types.cmake) target_include_directories( From 37d5db2d45011ae139b41a3f79174cabdb5b5ef7 Mon Sep 17 00:00:00 2001 From: Jakub Domagala Date: Tue, 16 Feb 2021 17:06:23 +0100 Subject: [PATCH 2/2] #1256: vt-trace: Set the option to build vt-trace target to OFF by default --- CMakeLists.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 8f267c17a3..f8b7d48c3f 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -110,7 +110,7 @@ include(cmake/load_bundled_libraries.cmake) include(cmake/nvcc_no_deprecated_gpu_targets.cmake) -option(vt_trace_only "Build VT with trace-only mode enabled" ON) +option(vt_trace_only "Build VT with trace-only mode enabled" OFF) if (vt_trace_only) message(STATUS "Building additional target for VT in trace-only mode") endif()