diff --git a/CMakeLists.txt b/CMakeLists.txt index 66a77fa54..dd72eb902 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -55,7 +55,8 @@ check_c_source_compiles( static inline foo_t static_foo(){return 0;} foo_t foo(){return 0;} int main(int argc, char *argv[]){return 0;} - " ECCODES_HAVE_C_INLINE ) + " ECCODES_HAVE_C_INLINE +) include(eccodes_test_endiness) if( EC_OS_NAME MATCHES "windows" ) diff --git a/bamboo/CMakeLists.txt b/bamboo/CMakeLists.txt index 18b8087af..e11c54f6a 100644 --- a/bamboo/CMakeLists.txt +++ b/bamboo/CMakeLists.txt @@ -1,4 +1,6 @@ file( GLOB_RECURSE bamboo_files RELATIVE ${CMAKE_CURRENT_SOURCE_DIR} "*" ) -ecbuild_add_resources( TARGET ${PROJECT_NAME}_bamboo - SOURCES_DONT_PACK ${bamboo_files} ) +ecbuild_add_resources( + TARGET ${PROJECT_NAME}_bamboo + SOURCES_DONT_PACK ${bamboo_files} +) diff --git a/data/bufr/CMakeLists.txt b/data/bufr/CMakeLists.txt index 35b33c9f1..148500ed9 100644 --- a/data/bufr/CMakeLists.txt +++ b/data/bufr/CMakeLists.txt @@ -2,17 +2,17 @@ # Download all the BUFR data and reference files from website # -FILE(READ "bufr_data_files.txt" bufr_files_to_download) +file(READ "bufr_data_files.txt" bufr_files_to_download) # Convert file contents into a CMake list (where each element in the list # is one line of the file) -STRING(REGEX REPLACE "\n" ";" bufr_files_to_download "${bufr_files_to_download}") +string(REGEX REPLACE "\n" ";" bufr_files_to_download "${bufr_files_to_download}") -FILE(READ "bufr_ref_files.txt" bufr_refs_to_download) -STRING(REGEX REPLACE "\n" ";" bufr_refs_to_download "${bufr_refs_to_download}") +file(READ "bufr_ref_files.txt" bufr_refs_to_download) +string(REGEX REPLACE "\n" ";" bufr_refs_to_download "${bufr_refs_to_download}") # Exceptional case: download bufr files which have to be treated specially -LIST(APPEND bufr_refs_to_download "vos308014_v3_26.bufr") # See test ecc-197 +list(APPEND bufr_refs_to_download "vos308014_v3_26.bufr") # See test ecc-197 if( ENABLE_EXTRA_TESTS ) ecbuild_get_test_multidata( @@ -23,7 +23,7 @@ if( ENABLE_EXTRA_TESTS ) endif() # Copy other files - e.g. text files etc from the source data/bufr dir -LIST(APPEND other_files +list(APPEND other_files bufr_data_files.txt bufr_ref_files.txt ) diff --git a/data/gts/CMakeLists.txt b/data/gts/CMakeLists.txt index ed537fbb4..417684f21 100644 --- a/data/gts/CMakeLists.txt +++ b/data/gts/CMakeLists.txt @@ -1,12 +1,11 @@ # data/gts/CMakeLists.txt # Download all the GTS data and reference files from website # +file(READ "gts_data_files.txt" gts_files_to_download) +string(REGEX REPLACE "\n" ";" gts_files_to_download "${gts_files_to_download}") -FILE(READ "gts_data_files.txt" gts_files_to_download) -STRING(REGEX REPLACE "\n" ";" gts_files_to_download "${gts_files_to_download}") - -FILE(READ "gts_ref_files.txt" gts_refs_to_download) -STRING(REGEX REPLACE "\n" ";" gts_refs_to_download "${gts_refs_to_download}") +file(READ "gts_ref_files.txt" gts_refs_to_download) +string(REGEX REPLACE "\n" ";" gts_refs_to_download "${gts_refs_to_download}") if( ENABLE_EXTRA_TESTS ) ecbuild_get_test_multidata( @@ -17,7 +16,7 @@ if( ENABLE_EXTRA_TESTS ) endif() # Copy other files - e.g. text files etc from the source data/gts dir -LIST(APPEND other_files +list(APPEND other_files gts_data_files.txt gts_ref_files.txt ) diff --git a/data/metar/CMakeLists.txt b/data/metar/CMakeLists.txt index feaa71ef3..9ed771b4a 100644 --- a/data/metar/CMakeLists.txt +++ b/data/metar/CMakeLists.txt @@ -2,15 +2,13 @@ # Download all the METAR data and reference files from website # -FILE(READ "metar_data_files.txt" metar_files_to_download) +file(READ "metar_data_files.txt" metar_files_to_download) # Convert file contents into a CMake list (where each element in the list # is one line of the file) -STRING(REGEX REPLACE "\n" ";" metar_files_to_download "${metar_files_to_download}") - - -FILE(READ "metar_ref_files.txt" metar_refs_to_download) -STRING(REGEX REPLACE "\n" ";" metar_refs_to_download "${metar_refs_to_download}") +string(REGEX REPLACE "\n" ";" metar_files_to_download "${metar_files_to_download}") +file(READ "metar_ref_files.txt" metar_refs_to_download) +string(REGEX REPLACE "\n" ";" metar_refs_to_download "${metar_refs_to_download}") if( ENABLE_EXTRA_TESTS ) ecbuild_get_test_multidata( @@ -21,7 +19,7 @@ if( ENABLE_EXTRA_TESTS ) endif() # Copy other files - e.g. text files etc from the source data/metar dir -LIST(APPEND other_files +list(APPEND other_files metar_data_files.txt metar_ref_files.txt ) diff --git a/data/tigge/CMakeLists.txt b/data/tigge/CMakeLists.txt index 0af0b0715..7e55920b0 100644 --- a/data/tigge/CMakeLists.txt +++ b/data/tigge/CMakeLists.txt @@ -13,9 +13,8 @@ endif() ####### # Copy other files - e.g. reference data, text files etc from the source data dir -LIST(APPEND other_files - tigge_data_files.txt -) +list(APPEND other_files + tigge_data_files.txt) foreach( file ${other_files} ) execute_process( COMMAND ${CMAKE_COMMAND} -E copy_if_different ${CMAKE_CURRENT_SOURCE_DIR}/${file} ${CMAKE_CURRENT_BINARY_DIR} ) endforeach() diff --git a/examples/C/CMakeLists.txt b/examples/C/CMakeLists.txt index 83a97fea4..02d7db43c 100644 --- a/examples/C/CMakeLists.txt +++ b/examples/C/CMakeLists.txt @@ -49,26 +49,24 @@ list( APPEND test_bins bufr_read_synop bufr_read_temp bufr_set_keys - bufr_subset -) + bufr_subset ) foreach( tool ${test_bins} ) ecbuild_add_executable( TARGET c_${tool} NOINSTALL SOURCES ${tool}.c - LIBS eccodes - ) + LIBS eccodes ) endforeach() # Now add each test (shell scripts) ######################################################################## -list( APPEND tests_basic +list(APPEND tests_basic grib_multi grib_set_data large_grib1 grib_sections_copy get_product_kind_samples ) -list( APPEND tests_extra +list(APPEND tests_extra grib_iterator grib_get_keys grib_print_data @@ -105,34 +103,30 @@ list( APPEND tests_extra foreach( test ${tests_basic} ) ecbuild_add_test( TARGET eccodes_c_${test} TYPE SCRIPT - COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/${test}.sh - ) + COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/${test}.sh ) endforeach() foreach( test ${tests_extra} ) ecbuild_add_test( TARGET eccodes_c_${test} TYPE SCRIPT CONDITION ENABLE_EXTRA_TESTS COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/${test}.sh - TEST_DEPENDS eccodes_download_gribs eccodes_download_bufrs - ) + TEST_DEPENDS eccodes_download_gribs eccodes_download_bufrs ) endforeach() ######################################################################## # Tests which are conditional if( ENABLE_EXTRA_TESTS AND HAVE_ECCODES_THREADS ) # For POSIX threads - LIST(APPEND pthread_tests grib_pthreads bufr_pthreads) + list(APPEND pthread_tests grib_pthreads bufr_pthreads) foreach( test ${pthread_tests} ) ecbuild_add_executable( TARGET c_${test} NOINSTALL SOURCES ${test}.c - LIBS eccodes - ) + LIBS eccodes ) ecbuild_add_test( TARGET eccodes_c_${test} TYPE SCRIPT COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/${test}.sh - TEST_DEPENDS eccodes_download_gribs eccodes_download_bufrs - ) + TEST_DEPENDS eccodes_download_gribs eccodes_download_bufrs ) endforeach() endif() diff --git a/examples/F90/CMakeLists.txt b/examples/F90/CMakeLists.txt index 45ebf151c..964a34603 100644 --- a/examples/F90/CMakeLists.txt +++ b/examples/F90/CMakeLists.txt @@ -10,8 +10,7 @@ execute_process( COMMAND ${CMAKE_COMMAND} -E copy_if_different ${CMAKE_CURRENT_S list( APPEND tests_basic grib_set_pv grib_set_data - grib_ecc-671 -) + grib_ecc-671 ) list( APPEND tests_extra grib_index grib_copy_message @@ -52,8 +51,7 @@ list( APPEND tests_extra bufr_set_keys bufr_copy_keys bufr_subset - get_product_kind -) + get_product_kind ) foreach( tool ${tests_basic} ) ecbuild_add_test( TARGET eccodes_f_${tool} @@ -62,8 +60,7 @@ foreach( tool ${tests_basic} ) LIBS eccodes_f90 eccodes CONDITION HAVE_FORTRAN RESOURCES bufr_read_scatterometer_f.ref - COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/${tool}.sh - ) + COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/${tool}.sh ) endforeach() foreach( tool ${tests_extra} ) ecbuild_add_test( TARGET eccodes_f_${tool} @@ -73,8 +70,7 @@ foreach( tool ${tests_extra} ) CONDITION HAVE_FORTRAN AND ENABLE_EXTRA_TESTS RESOURCES bufr_read_scatterometer_f.ref COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/${tool}.sh - TEST_DEPENDS eccodes_download_gribs eccodes_download_bufrs - ) + TEST_DEPENDS eccodes_download_gribs eccodes_download_bufrs ) endforeach() # Executables without a shell script @@ -84,22 +80,19 @@ ecbuild_add_executable( TARGET eccodes_f_new_from_file SOURCES new_from_file.f90 CONDITION HAVE_FORTRAN LINKER_LANGUAGE Fortran - LIBS eccodes_f90 eccodes -) + LIBS eccodes_f90 eccodes ) ecbuild_add_executable( TARGET eccodes_f_grib_set_gvc NOINSTALL SOURCES grib_set_gvc.f90 CONDITION HAVE_FORTRAN LINKER_LANGUAGE Fortran - LIBS eccodes_f90 eccodes -) + LIBS eccodes_f90 eccodes ) ecbuild_add_executable( TARGET eccodes_f_grib_print_data_static NOINSTALL SOURCES grib_print_data_static.f90 CONDITION HAVE_FORTRAN LINKER_LANGUAGE Fortran - LIBS eccodes_f90 eccodes -) + LIBS eccodes_f90 eccodes ) # # Note extra dependency diff --git a/examples/python/CMakeLists.txt b/examples/python/CMakeLists.txt index 0a6b6a0cd..158b0629f 100644 --- a/examples/python/CMakeLists.txt +++ b/examples/python/CMakeLists.txt @@ -7,7 +7,7 @@ execute_process( COMMAND ${CMAKE_COMMAND} -E copy_if_different ${CMAKE_CURRENT_S # Build the executables used by test scripts ################################################ -list( APPEND test_bins +list(APPEND test_bins grib_keys_iterator grib_print_data grib_iterator @@ -19,21 +19,20 @@ foreach( tool ${test_bins} ) NOINSTALL SOURCES ${tool}.c CONDITION HAVE_PYTHON - LIBS eccodes - ) + LIBS eccodes ) list( APPEND ptools p_${tool} ) endforeach() # Now add each test ################################################# -list( APPEND tests_basic +list(APPEND tests_basic grib_set_pv grib_read_sample bufr_read_sample bufr_ecc-869 ) -list( APPEND tests_extra +list(APPEND tests_extra grib_clone grib_count_messages grib_get_message_offset @@ -81,8 +80,7 @@ foreach( test ${tests_basic} ) DEPENDS ${ptools} COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/${test}.sh CONDITION HAVE_PYTHON - ENVIRONMENT PYTHON=${PYTHON_EXECUTABLE} - ) + ENVIRONMENT PYTHON=${PYTHON_EXECUTABLE} ) endforeach() foreach( test ${tests_extra} ) ecbuild_add_test( TARGET eccodes_p_${test}_test @@ -91,8 +89,7 @@ foreach( test ${tests_extra} ) COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/${test}.sh CONDITION HAVE_PYTHON AND ENABLE_EXTRA_TESTS ENVIRONMENT PYTHON=${PYTHON_EXECUTABLE} - TEST_DEPENDS eccodes_download_gribs eccodes_download_tigge_gribs eccodes_download_bufrs - ) + TEST_DEPENDS eccodes_download_gribs eccodes_download_tigge_gribs eccodes_download_bufrs ) endforeach() # Add test which requires input CSV file @@ -103,8 +100,7 @@ ecbuild_add_test( TARGET eccodes_p_bufr_encode_flight_test CONDITION HAVE_PYTHON AND ENABLE_EXTRA_TESTS ENVIRONMENT PYTHON=${PYTHON_EXECUTABLE} RESOURCES flight_data.csv - TEST_DEPENDS eccodes_download_bufrs -) + TEST_DEPENDS eccodes_download_bufrs ) # Conditional tests ecbuild_add_test( TARGET eccodes_p_grib_ccsds_test @@ -113,5 +109,4 @@ ecbuild_add_test( TARGET eccodes_p_grib_ccsds_test COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/grib_ccsds.sh CONDITION HAVE_PYTHON AND HAVE_AEC AND ENABLE_EXTRA_TESTS ENVIRONMENT PYTHON=${PYTHON_EXECUTABLE} - TEST_DEPENDS eccodes_download_gribs -) + TEST_DEPENDS eccodes_download_gribs ) diff --git a/ifs_samples/grib1/CMakeLists.txt b/ifs_samples/grib1/CMakeLists.txt index 42f9ea257..378c2b3f6 100644 --- a/ifs_samples/grib1/CMakeLists.txt +++ b/ifs_samples/grib1/CMakeLists.txt @@ -7,7 +7,6 @@ list( APPEND ifs_samples_${_basedir} ${CMAKE_CURRENT_SOURCE_DIR}/gg_sfc.tmpl ${CMAKE_CURRENT_SOURCE_DIR}/sh_ml.tmpl ${CMAKE_CURRENT_SOURCE_DIR}/sh_sfc.tmpl - ${ECCODES_SAMPLES_FILES} -) + ${ECCODES_SAMPLES_FILES} ) install_samples( ifs_samples_${_basedir} ${_destination_install} ${_destination_build} ) diff --git a/ifs_samples/grib1_mlgrib2/CMakeLists.txt b/ifs_samples/grib1_mlgrib2/CMakeLists.txt index 5b597ce7b..6ec0486a6 100644 --- a/ifs_samples/grib1_mlgrib2/CMakeLists.txt +++ b/ifs_samples/grib1_mlgrib2/CMakeLists.txt @@ -7,7 +7,6 @@ list( APPEND ifs_samples_${_basedir} ${CMAKE_CURRENT_SOURCE_DIR}/gg_sfc.tmpl ${CMAKE_CURRENT_SOURCE_DIR}/sh_ml.tmpl ${CMAKE_CURRENT_SOURCE_DIR}/sh_sfc.tmpl - ${ECCODES_SAMPLES_FILES} -) + ${ECCODES_SAMPLES_FILES} ) install_samples( ifs_samples_${_basedir} ${_destination_install} ${_destination_build} ) diff --git a/ifs_samples/grib1_mlgrib2_ieee32/CMakeLists.txt b/ifs_samples/grib1_mlgrib2_ieee32/CMakeLists.txt index 3b3e3b567..49fd08333 100644 --- a/ifs_samples/grib1_mlgrib2_ieee32/CMakeLists.txt +++ b/ifs_samples/grib1_mlgrib2_ieee32/CMakeLists.txt @@ -7,7 +7,6 @@ list( APPEND ifs_samples_${_basedir} ${CMAKE_CURRENT_SOURCE_DIR}/gg_sfc.tmpl ${CMAKE_CURRENT_SOURCE_DIR}/sh_ml.tmpl ${CMAKE_CURRENT_SOURCE_DIR}/sh_sfc.tmpl - ${ECCODES_SAMPLES_FILES} -) + ${ECCODES_SAMPLES_FILES} ) install_samples( ifs_samples_${_basedir} ${_destination_install} ${_destination_build} ) diff --git a/ifs_samples/grib1_mlgrib2_ieee64/CMakeLists.txt b/ifs_samples/grib1_mlgrib2_ieee64/CMakeLists.txt index efffb7446..16ec73dba 100644 --- a/ifs_samples/grib1_mlgrib2_ieee64/CMakeLists.txt +++ b/ifs_samples/grib1_mlgrib2_ieee64/CMakeLists.txt @@ -7,7 +7,6 @@ list( APPEND ifs_samples_${_basedir} ${CMAKE_CURRENT_SOURCE_DIR}/gg_sfc.tmpl ${CMAKE_CURRENT_SOURCE_DIR}/sh_ml.tmpl ${CMAKE_CURRENT_SOURCE_DIR}/sh_sfc.tmpl - ${ECCODES_SAMPLES_FILES} -) + ${ECCODES_SAMPLES_FILES} ) install_samples( ifs_samples_${_basedir} ${_destination_install} ${_destination_build} ) diff --git a/python/CMakeLists.txt b/python/CMakeLists.txt index 33aa1f0c1..08572574a 100644 --- a/python/CMakeLists.txt +++ b/python/CMakeLists.txt @@ -7,19 +7,19 @@ if( HAVE_PYTHON ) # preparing for generating setup.py if( HAVE_LIBJASPER ) - get_filename_component(JASPER_DIR ${JASPER_INCLUDE_DIR} PATH ) + get_filename_component( JASPER_DIR ${JASPER_INCLUDE_DIR} PATH ) endif() if( HAVE_LIBOPENJPEG ) # Get the name of the OpenJPEG library: version dependent! # E.g. openjpeg (version 1.5) or openjp2 (version 2.x) - get_filename_component(OPENJPEG_LIB_DIR ${OPENJPEG_LIBRARY} PATH ) - get_filename_component(OJ_NAME_WE ${OPENJPEG_LIBRARY} NAME_WE ) - STRING(REGEX REPLACE "^lib" "" OJ_WITHOUT_LIB ${OJ_NAME_WE}) + get_filename_component( OPENJPEG_LIB_DIR ${OPENJPEG_LIBRARY} PATH ) + get_filename_component( OJ_NAME_WE ${OPENJPEG_LIBRARY} NAME_WE ) + string(REGEX REPLACE "^lib" "" OJ_WITHOUT_LIB ${OJ_NAME_WE}) endif() if( HAVE_AEC ) - get_filename_component(AEC_DIR ${AEC_INCLUDE_DIR} PATH ) + get_filename_component( AEC_DIR ${AEC_INCLUDE_DIR} PATH ) endif() configure_file( setup.py.in setup.py ) diff --git a/tests/CMakeLists.txt b/tests/CMakeLists.txt index 942934bbd..9f5606a03 100644 --- a/tests/CMakeLists.txt +++ b/tests/CMakeLists.txt @@ -34,22 +34,20 @@ list( APPEND test_bins ieee grib_sh_imag grib_lam_bf - grib_lam_gp -) + grib_lam_gp ) foreach( tool ${test_bins} ) # here we use the fact that each tool has only one C file that matches its name ecbuild_add_executable( TARGET ${tool} NOINSTALL SOURCES ${tool}.c - LIBS eccodes - ) + LIBS eccodes ) endforeach() # Now add each test (shell scripts) ################################################# # These tests do not require any data downloads -list( APPEND tests_no_data_reqd +list(APPEND tests_no_data_reqd definitions grib_calendar unit_tests @@ -69,10 +67,10 @@ list( APPEND tests_no_data_reqd grib_sh_imag diag grib_lambert_conformal - grib_g1fcperiod -) + grib_g1fcperiod) + # These tests do require data downloads -list( APPEND tests_data_reqd +list(APPEND tests_data_reqd grib_data_quality_checks bpv_limit grib_complex @@ -183,8 +181,8 @@ list( APPEND tests_data_reqd grib_local_MeteoFrance grib_neg_fctime codes_split_file - grib_mars_types -) + grib_mars_types) + if( HAVE_FORTRAN AND ENABLE_EXTRA_TESTS ) list(APPEND tests_data_reqd bufr_dump_encode_fortran) list(APPEND tests_data_reqd bufr_dump_decode_fortran) @@ -201,14 +199,12 @@ endif() foreach( test ${tests_no_data_reqd} ) ecbuild_add_test( TARGET eccodes_t_${test} TYPE SCRIPT - COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/${test}.sh - ) + COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/${test}.sh ) endforeach() ecbuild_add_test( TARGET eccodes_t_grib_check_gaussian_grids TYPE SCRIPT CONDITION ECCODES_INSTALL_EXTRA_TOOLS - COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/grib_check_gaussian_grids.sh -) + COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/grib_check_gaussian_grids.sh ) # Note: making the test dependent on the grib files (with DEPENDS) @@ -221,15 +217,14 @@ foreach( test ${tests_data_reqd} ) COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/${test}.sh RESOURCES asca_139.t1.ref TEST_DEPENDS eccodes_download_gribs eccodes_download_tigge_gribs - eccodes_download_bufrs eccodes_download_metars eccodes_download_gts - ) + eccodes_download_bufrs eccodes_download_metars eccodes_download_gts ) endforeach() if( HAVE_FORTRAN AND ENABLE_EXTRA_TESTS ) - set_tests_properties ( eccodes_t_bufr_dump_encode_fortran PROPERTIES TIMEOUT 2500) + set_tests_properties( eccodes_t_bufr_dump_encode_fortran PROPERTIES TIMEOUT 2500 ) endif() if( ENABLE_EXTRA_TESTS ) - set_tests_properties ( eccodes_t_bufr_dump_encode_C PROPERTIES TIMEOUT 2500) + set_tests_properties( eccodes_t_bufr_dump_encode_C PROPERTIES TIMEOUT 2500 ) endif() @@ -240,8 +235,7 @@ if( HAVE_PYTHON AND ENABLE_EXTRA_TESTS ) TYPE SCRIPT COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/${test}.sh ENVIRONMENT PYTHON=${PYTHON_EXECUTABLE} PYTHONPATH=${PROJECT_BINARY_DIR}/${ECCODES_PYTHON_DIR} - TEST_DEPENDS eccodes_download_bufrs - ) + TEST_DEPENDS eccodes_download_bufrs ) endforeach() endif() @@ -252,8 +246,7 @@ ecbuild_add_test( TARGET eccodes_t_grib_lamb_az_eq_area CONDITION ENABLE_EXTRA_TESTS COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/grib_lamb_az_eq_area.sh RESOURCES grib_lamb_az_eq_area.ref - TEST_DEPENDS eccodes_download_gribs -) + TEST_DEPENDS eccodes_download_gribs ) # These ones are conditional ########################################### @@ -261,91 +254,77 @@ ecbuild_add_test( TARGET eccodes_t_tools_data_from_stdin TYPE SCRIPT CONDITION NOT ECCODES_ON_WINDOWS AND ENABLE_EXTRA_TESTS COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/tools_data_from_stdin.sh - TEST_DEPENDS eccodes_download_bufrs -) + TEST_DEPENDS eccodes_download_bufrs ) ecbuild_add_test( TARGET eccodes_t_bufr_ecc-197 TYPE SCRIPT CONDITION NOT ECCODES_ON_WINDOWS AND ENABLE_EXTRA_TESTS COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/bufr_ecc-197.sh - TEST_DEPENDS eccodes_download_bufrs -) + TEST_DEPENDS eccodes_download_bufrs ) if( ENABLE_EXTRA_TESTS AND HAVE_ECCODES_THREADS ) ecbuild_add_executable( TARGET grib_encode_pthreads NOINSTALL SOURCES grib_encode_pthreads.c - LIBS eccodes - ) + LIBS eccodes ) ecbuild_add_test( TARGET eccodes_t_grib_encode_pthreads TYPE SCRIPT - COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/grib_encode_pthreads.sh - ) + COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/grib_encode_pthreads.sh ) foreach( test grib_ecc-604 grib_ecc-604-encode bufr_ecc-604 ) ecbuild_add_executable( TARGET ${test} NOINSTALL SOURCES ${test}.c - LIBS eccodes - ) + LIBS eccodes ) endforeach() ecbuild_add_test( TARGET eccodes_t_grib_ecc-604 TYPE SCRIPT TEST_DEPENDS eccodes_download_gribs - COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/grib_ecc-604.sh - ) + COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/grib_ecc-604.sh ) ecbuild_add_test( TARGET eccodes_t_bufr_ecc-604 TYPE SCRIPT TEST_DEPENDS eccodes_download_bufrs - COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/bufr_ecc-604.sh - ) + COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/bufr_ecc-604.sh ) endif() ecbuild_add_test( TARGET eccodes_t_grib_to_netcdf TYPE SCRIPT CONDITION HAVE_NETCDF AND ENABLE_EXTRA_TESTS COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/grib_to_netcdf.sh - TEST_DEPENDS eccodes_download_gribs -) + TEST_DEPENDS eccodes_download_gribs ) ecbuild_add_test( TARGET eccodes_t_grib_jpeg TYPE SCRIPT CONDITION HAVE_JPEG AND ENABLE_EXTRA_TESTS COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/grib_jpeg.sh - TEST_DEPENDS eccodes_download_gribs -) + TEST_DEPENDS eccodes_download_gribs ) ecbuild_add_test( TARGET eccodes_t_grib_png TYPE SCRIPT CONDITION HAVE_PNG AND ENABLE_EXTRA_TESTS COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/grib_png.sh - TEST_DEPENDS eccodes_download_gribs -) + TEST_DEPENDS eccodes_download_gribs ) ecbuild_add_test( TARGET eccodes_t_grib_ccsds TYPE SCRIPT CONDITION HAVE_AEC AND ENABLE_EXTRA_TESTS COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/grib_ccsds.sh - TEST_DEPENDS eccodes_download_gribs -) + TEST_DEPENDS eccodes_download_gribs ) ecbuild_add_test( TARGET eccodes_t_grib_check_param_concepts TYPE SCRIPT CONDITION ENABLE_EXTRA_TESTS - COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/grib_check_param_concepts.sh -) + COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/grib_check_param_concepts.sh ) ecbuild_add_test( TARGET eccodes_t_bufr_split_by_rdbSubtype TYPE SCRIPT CONDITION ENABLE_EXTRA_TESTS AND ECCODES_INSTALL_EXTRA_TOOLS COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/bufr_split_by_rdbSubtype.sh - TEST_DEPENDS eccodes_download_bufrs -) + TEST_DEPENDS eccodes_download_bufrs ) # Performance test. Must have -DENABLE_GRIB_TIMER=ON ecbuild_add_test( TARGET eccodes_t_grib_ecc-386 TYPE SCRIPT CONDITION ENABLE_EXTRA_TESTS AND ENABLE_GRIB_TIMER COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/grib_ecc-386.sh - TEST_DEPENDS eccodes_download_gribs -) + TEST_DEPENDS eccodes_download_gribs ) diff --git a/tigge/CMakeLists.txt b/tigge/CMakeLists.txt index dbc9a093e..10c4aaec8 100644 --- a/tigge/CMakeLists.txt +++ b/tigge/CMakeLists.txt @@ -10,26 +10,22 @@ ecbuild_add_library(TARGET tigge_tools ecbuild_add_executable(TARGET tigge_check SOURCES tigge_check.c INCLUDES ${ECCODES_EXTRA_INCLUDE_DIRS} - LIBS eccodes tigge_tools - ) + LIBS eccodes tigge_tools) -ecbuild_add_executable(TARGET tigge_name +ecbuild_add_executable(TARGET tigge_name SOURCES tigge_name.c INCLUDES ${ECCODES_EXTRA_INCLUDE_DIRS} CONDITION ECCODES_INSTALL_EXTRA_TOOLS - LIBS eccodes tigge_tools - ) + LIBS eccodes tigge_tools) ecbuild_add_executable(TARGET tigge_accumulations SOURCES tigge_accumulations.c INCLUDES ${ECCODES_EXTRA_INCLUDE_DIRS} CONDITION ECCODES_INSTALL_EXTRA_TOOLS - LIBS eccodes tigge_tools - ) + LIBS eccodes tigge_tools) ecbuild_add_executable(TARGET tigge_split SOURCES tigge_split.c INCLUDES ${ECCODES_EXTRA_INCLUDE_DIRS} CONDITION ECCODES_INSTALL_EXTRA_TOOLS - LIBS eccodes tigge_tools - ) + LIBS eccodes tigge_tools)