-
Notifications
You must be signed in to change notification settings - Fork 14
/
QMPConfig.cmake.in
38 lines (30 loc) · 920 Bytes
/
QMPConfig.cmake.in
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
@PACKAGE_INIT@
# Boiler Plate Config file
#
#
# Include our targets
include(CMakeFindDependencyMacro)
# Include the imported targets
include(${CMAKE_CURRENT_LIST_DIR}/QMPTargets.cmake)
# Set the CMakeModule path to include the current (substituted) package
# directory in order so we can find Dmalloc if we need it
list(APPEND CMAKE_MODULE_PATH @PACKAGE_cmakeModulesDir@)
# This will let us check if we need MPI
set(QMP_MPI @QMP_MPI@)
# This will let us check if we need DMalloc
set(QMP_USE_DMALLOC @QMP_USE_DMALLOC@)
# Resolve dependencies if needed
if( QMP_MPI )
find_dependency(MPI)
if( NOT MPI_C_FOUND )
message(ERROR "Could not find MPI_C")
endif()
endif()
# Resolve dependencies if needed
if( QMP_USE_DMALLOC )
find_dependency(Dmalloc REQUIRED)
endif()
# Boiler plate stuff may not be needed now
check_required_components(MPI)
check_required_components(Dmalloc)
check_required_components(QMP)