From ded0e7fe226e064c43604d82abe4f2e1174f1e02 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sl=C3=A1vek=20Banko?= Date: Mon, 25 Jan 2021 22:08:40 +0100 Subject: Generate kweather station information files during the build phase instead of the configuration phase. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Slávek Banko (cherry picked from commit 07d616b7e20de3282bad26ac303503bf86955ffe) --- kweather/CMakeLists.txt | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/kweather/CMakeLists.txt b/kweather/CMakeLists.txt index 075266b..6b28670 100644 --- a/kweather/CMakeLists.txt +++ b/kweather/CMakeLists.txt @@ -51,11 +51,14 @@ if( NOT PERL_EXECUTABLE ) include( FindPerl ) endif( ) -execute_process( +add_custom_command( + OUTPUT stations.dat weather_stations.desktop COMMAND ${PERL_EXECUTABLE} ${CMAKE_CURRENT_SOURCE_DIR}/genstations.pl ${CMAKE_CURRENT_SOURCE_DIR}/data/nsd_cccc.txt ${CMAKE_CURRENT_SOURCE_DIR}/data/station_names.txt ${CMAKE_CURRENT_SOURCE_DIR}/weather_stations.desktop.in + DEPENDS + data/nsd_cccc.txt data/station_names.txt weather_stations.desktop.in WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} ) -- cgit v1.2.3