1 add_library( util_common STATIC )
2 # todo - Find how to compile this with NCAR Graphics, will need to write a find_package() module
3 # add_executable( plotgrids )
4 add_executable( rd_intermediate )
5 add_executable( avg_tsfc )
6 # Find out if this needs compiling, ./compile suggests no
7 # add_executable( elev_angle )
8 add_executable( calc_ecmwf_p )
9 # Same thing as plotgrids
10 # add_executable( plotfmt )
11 add_executable( mod_levs )
12 if ( DEFINED WRF_DIR )
13 add_executable( int2nc )
15 add_executable( height_ukmo )
29 if ( DEFINED WRF_DIR )
30 list( APPEND ALL_UTIL_TARGETS int2nc )
33 add_subdirectory( src )
36 # target_link_libraries(
41 # target_include_directories(
44 # ${netCDF_INCLUDE_DIRS}
47 if ( DEFINED WRF_DIR )
48 target_link_libraries(
54 target_include_directories(
57 ${netCDF_INCLUDE_DIRS}
62 foreach( TARGET ${ALL_UTIL_TARGETS} util_common )
65 set_target_properties(
68 # Just dump everything in here
69 Fortran_MODULE_DIRECTORY ${CMAKE_INSTALL_PREFIX}/modules/util/
73 # Everything except util_common
74 if ( NOT "${TARGET}" STREQUAL util_common )
75 target_link_libraries(
82 # Add these to the export targets
85 EXPORT ${EXPORT_NAME}Targets
86 RUNTIME DESTINATION bin/
87 ARCHIVE DESTINATION lib/
88 LIBRARY DESTINATION lib/