-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathespressoConfig.cmake
More file actions
30 lines (24 loc) · 1.05 KB
/
Copy pathespressoConfig.cmake
File metadata and controls
30 lines (24 loc) · 1.05 KB
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
# espressoConfig.cmake - CMake package configuration file for espresso
# Use relative paths for in-source builds
get_filename_component(_prefix "${CMAKE_CURRENT_LIST_DIR}/../../.." ABSOLUTE)
set(espresso_INCLUDE_DIR "${_prefix}/include")
set(espresso_LIBRARY_DIR "${_prefix}/lib")
# Set the library file (Release by default)
set(espresso_LIBRARIES "${espresso_LIBRARY_DIR}/libespresso.a")
# Optionally, set the debug library
if(EXISTS "${espresso_LIBRARY_DIR}/libespressod.a")
set(espresso_LIBRARIES_DEBUG "${espresso_LIBRARY_DIR}/libespressod.a")
endif()
# Provide an imported target for easy linking
if(NOT TARGET espresso::espresso)
add_library(espresso::espresso STATIC IMPORTED)
set_target_properties(espresso::espresso PROPERTIES
IMPORTED_LOCATION "${espresso_LIBRARIES}"
INTERFACE_INCLUDE_DIRECTORIES "${espresso_INCLUDE_DIR}"
)
if(DEFINED espresso_LIBRARIES_DEBUG)
set_target_properties(espresso::espresso PROPERTIES
IMPORTED_LOCATION_DEBUG "${espresso_LIBRARIES_DEBUG}"
)
endif()
endif()