forked from getsentry/sentry-native
-
Notifications
You must be signed in to change notification settings - Fork 0
/
sentry-config.cmake.in
33 lines (27 loc) · 1.08 KB
/
sentry-config.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
@PACKAGE_INIT@
set(SENTRY_BACKEND @SENTRY_BACKEND@)
set(SENTRY_TRANSPORT @SENTRY_TRANSPORT@)
set(SENTRY_BUILD_SHARED_LIBS @SENTRY_BUILD_SHARED_LIBS@)
set(SENTRY_LINK_PTHREAD @SENTRY_LINK_PTHREAD@)
if(SENTRY_BACKEND STREQUAL "crashpad" AND NOT SENTRY_BUILD_SHARED_LIBS)
include("${CMAKE_CURRENT_LIST_DIR}/sentry_crashpad-targets.cmake")
if(NOT MSVC AND NOT SENTRY_BUILD_SHARED_LIBS)
find_package(ZLIB REQUIRED)
endif()
endif()
if(SENTRY_BACKEND STREQUAL "breakpad" AND NOT SENTRY_BUILD_SHARED_LIBS)
set(SENTRY_BREAKPAD_SYSTEM @SENTRY_BREAKPAD_SYSTEM@)
if(SENTRY_BREAKPAD_SYSTEM)
find_package(PkgConfig REQUIRED)
pkg_check_modules(BREAKPAD REQUIRED IMPORTED_TARGET breakpad-client)
endif()
endif()
include("${CMAKE_CURRENT_LIST_DIR}/sentry-targets.cmake")
if(SENTRY_TRANSPORT STREQUAL "curl" AND (NOT @BUILD_SHARED_LIBS@ OR NOT SENTRY_BUILD_SHARED_LIBS))
find_package(CURL REQUIRED)
set_property(TARGET sentry::sentry APPEND
PROPERTY INTERFACE_LINK_LIBRARIES ${CURL_LIBRARIES})
endif()
if(SENTRY_LINK_PTHREAD AND NOT SENTRY_BUILD_SHARED_LIBS)
find_package(Threads REQUIRED)
endif()