forked from JCSDA/crtm
-
Notifications
You must be signed in to change notification settings - Fork 0
/
crtm-import.cmake.in
14 lines (13 loc) · 893 Bytes
/
crtm-import.cmake.in
1
2
3
4
5
6
7
8
9
10
11
12
13
14
# crtm-import.cmake
include(CMakeFindDependencyMacro)
find_dependency(NetCDF REQUIRED)
find_package( OpenMP COMPONENTS Fortran )
#Export Fortran compiler version for checking module compatibility
set(@PROJECT_NAME@_MODULES_Fortran_COMPILER_ID @CMAKE_Fortran_COMPILER_ID@)
set(@PROJECT_NAME@_MODULES_Fortran_COMPILER_VERSION @CMAKE_Fortran_COMPILER_VERSION@)
if(NOT @PROJECT_NAME@_MODULES_Fortran_COMPILER_ID STREQUAL CMAKE_Fortran_COMPILER_ID
OR NOT @PROJECT_NAME@_MODULES_Fortran_COMPILER_VERSION VERSION_EQUAL CMAKE_Fortran_COMPILER_VERSION)
message(SEND_ERROR "Package @PROJECT_NAME@ provides Fortran modules built with "
"${@PROJECT_NAME@_MODULES_Fortran_COMPILER_ID}-${@PROJECT_NAME@_MODULES_Fortran_COMPILER_VERSION} "
"but this build for ${PROJECT_NAME} uses incompatible compiler ${CMAKE_Fortran_COMPILER_ID}-${CMAKE_Fortran_COMPILER_VERSION}")
endif()