aboutsummaryrefslogtreecommitdiff
path: root/cmake
diff options
context:
space:
mode:
authorCara Salter <cara@devcara.com>2023-10-07 21:16:07 -0400
committerCara Salter <cara@devcara.com>2023-10-07 21:16:07 -0400
commitbe5e0dd226a29d1d45f94d02bb63c64defbe33fd (patch)
tree4ddf056f951313811215d6fcb8a4a491bf2dab5f /cmake
parent5974e8229e94899840e2cc38787c878a423f68e6 (diff)
download142bot-be5e0dd226a29d1d45f94d02bb63c64defbe33fd.tar.gz
142bot-be5e0dd226a29d1d45f94d02bb63c64defbe33fd.zip
Add findsentry.cmake configuration
Diffstat (limited to 'cmake')
-rw-r--r--cmake/Findsentry.cmake14
1 files changed, 14 insertions, 0 deletions
diff --git a/cmake/Findsentry.cmake b/cmake/Findsentry.cmake
new file mode 100644
index 0000000..3c2b225
--- /dev/null
+++ b/cmake/Findsentry.cmake
@@ -0,0 +1,14 @@
+include(FindPackageHandleStandardArgs)
+
+find_library(SENTRY_LIBRARY NAMES sentry)
+
+find_package_handle_standard_args(sentry REQUIRED_VARS SENTRY_LIBRARY)
+
+if (SENTRY_FOUND)
+ mark_as_advanced(SENTRY_LIBRARY)
+endif()
+
+if(SENTRY_FOUND AND NOT TARGET sentry::sentry)
+ add_library(sentry::sentry IMPORTED UNKNOWN)
+ set_property(TARGET sentry::sentry PROPERTY IMPORTED_LOCATION ${SENTRY_LIBRARY})
+endif() \ No newline at end of file