-
-
Notifications
You must be signed in to change notification settings - Fork 4
Expand file tree
/
Copy pathCMakeLists.txt
More file actions
38 lines (28 loc) · 799 Bytes
/
CMakeLists.txt
File metadata and controls
38 lines (28 loc) · 799 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
cmake_minimum_required(VERSION 3.14...3.25)
project(maptran
LANGUAGES Fortran
VERSION 1.2.0
HOMEPAGE_URL https://github.com/geospace-code/maptran3d
)
enable_testing()
option(BUILD_TESTING "self tests" on)
if(NOT realbits)
set(realbits 32)
endif()
include(cmake/compilers.cmake)
# --- Maptran library
add_library(maptran)
target_include_directories(maptran PUBLIC
$<BUILD_INTERFACE:${CMAKE_CURRENT_BINARY_DIR}/include>
$<INSTALL_INTERFACE:include>
)
set_target_properties(maptran PROPERTIES
Fortran_MODULE_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/include
)
install(FILES ${CMAKE_CURRENT_BINARY_DIR}/include/maptran.mod TYPE INCLUDE)
install(TARGETS maptran EXPORT ${PROJECT_NAME}-targets)
add_subdirectory(src)
if(BUILD_TESTING)
add_subdirectory(test)
endif()
include(cmake/install.cmake)