From eb98ca17ce5ac5faafd5132e9008c9c1e66a52ce Mon Sep 17 00:00:00 2001 From: Alexander Shlemov Date: Wed, 24 May 2017 00:42:25 +0300 Subject: [PATCH] Copy config only if it's absent --- configs/CMakeLists.txt | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/configs/CMakeLists.txt b/configs/CMakeLists.txt index 39dd8c9c..067e28be 100644 --- a/configs/CMakeLists.txt +++ b/configs/CMakeLists.txt @@ -5,7 +5,9 @@ file(GLOB config_templates "*/*.template") foreach(config_template ${config_templates}) # Remove extention STRING(REGEX REPLACE "\\.template$" "" config ${config_template}) - configure_file("${config_template}" - "${config}" - @ONLY) + if(NOT EXISTS "${config}") + configure_file("${config_template}" + "${config}" + @ONLY) + endif() endforeach()