eccodes/tools/CMakeLists.txt

46 lines
1.7 KiB
CMake
Raw Normal View History

2013-03-25 12:04:10 +00:00
# tools library
ecbuild_add_library( TARGET grib_tools
2014-06-18 16:14:01 +00:00
TYPE STATIC
2013-04-10 15:46:41 +00:00
NOINSTALL
2014-06-18 16:14:01 +00:00
SOURCES grib_tools.c grib_options.c grib_tools.h
LIBS grib_api )
2013-03-25 12:04:10 +00:00
# tools binaries
list( APPEND grib_tools_bins
grib_keys grib_histogram grib_error grib_add big2gribex
2014-11-17 14:53:05 +00:00
grib_debug grib_info grib_filter grib_ls grib_dump grib_merge
2013-03-25 12:04:10 +00:00
grib2ppm grib_set grib_get grib_get_data grib_copy grib_repair
grib_packing grib_distance grib_corruption_check
2013-03-25 12:04:10 +00:00
grib_compare parser grib_count grib_index_build
2014-08-05 16:16:30 +00:00
gg_sub_area_check grib_moments grib_to_netcdf grib_to_json
bufr_filter bufr_ls bufr_dump bufr_set bufr_get
bufr_copy bufr_compare bufr_index_build
taf_dump taf_ls taf_get taf_filter
metar_dump metar_ls metar_get metar_filter
)
2013-03-25 12:04:10 +00:00
foreach( tool ${grib_tools_bins} )
# here we use the fact that each tool has only one C file that matches its name
ecbuild_add_executable( TARGET ${tool}
2014-06-18 16:14:01 +00:00
SOURCES ${tool}.c
LIBS grib_tools )
2013-03-25 12:04:10 +00:00
endforeach()
ecbuild_add_executable( TARGET grib_list_keys
2014-06-18 16:14:01 +00:00
SOURCES list_keys.c
LIBS grib_tools )
2013-03-25 12:04:10 +00:00
# missing noinst_PROGRAMS
2014-10-21 16:32:01 +00:00
# grib1to2 script
configure_file( grib1to2.in grib1to2 )
install( FILES ${CMAKE_CURRENT_BINARY_DIR}/grib1to2
DESTINATION ${INSTALL_BIN_DIR}
PERMISSIONS OWNER_EXECUTE OWNER_WRITE OWNER_READ
GROUP_EXECUTE GROUP_READ
WORLD_EXECUTE WORLD_READ )