28 lines
877 B
Diff
28 lines
877 B
Diff
|
diff --git a/sentry-config.cmake.in b/sentry-config.cmake.in
|
||
|
index 89ea345..c14b31c 100644
|
||
|
--- a/sentry-config.cmake.in
|
||
|
+++ b/sentry-config.cmake.in
|
||
|
@@ -3,9 +3,11 @@
|
||
|
set(SENTRY_BACKEND @SENTRY_BACKEND@)
|
||
|
set(SENTRY_TRANSPORT @SENTRY_TRANSPORT@)
|
||
|
|
||
|
+include(CMakeFindDependencyMacro)
|
||
|
+
|
||
|
if(SENTRY_BACKEND STREQUAL "crashpad")
|
||
|
if(@SENTRY_CRASHPAD_SYSTEM@)
|
||
|
- find_package(crashpad REQUIRED)
|
||
|
+ find_dependency(crashpad)
|
||
|
else()
|
||
|
include("${CMAKE_CURRENT_LIST_DIR}/sentry_crashpad-targets.cmake")
|
||
|
endif()
|
||
|
@@ -14,7 +16,7 @@ endif()
|
||
|
include("${CMAKE_CURRENT_LIST_DIR}/sentry-targets.cmake")
|
||
|
|
||
|
if(SENTRY_TRANSPORT STREQUAL "curl" AND NOT @BUILD_SHARED_LIBS@)
|
||
|
- find_package(CURL REQUIRED)
|
||
|
+ find_dependency(CURL)
|
||
|
set_property(TARGET sentry::sentry APPEND
|
||
|
- PROPERTY INTERFACE_LINK_LIBRARIES ${CURL_LIBRARIES})
|
||
|
+ PROPERTY INTERFACE_LINK_LIBRARIES CURL::libcurl)
|
||
|
endif()
|