Skip to content

Commit

Permalink
Merge pull request #62 from backtrace-labs/feature/integrated-crash-h…
Browse files Browse the repository at this point in the history
…andler

Allow to use crash handler code from the crashpad library
  • Loading branch information
konraddysput committed May 31, 2024
2 parents 7c798c0 + 17b128c commit d3f854b
Showing 1 changed file with 9 additions and 1 deletion.
10 changes: 9 additions & 1 deletion handler/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,14 @@ if (ANDROID)
)
endif (ANDROID)

# Used to implement a work-around for launching the Crashpad handler stored in an APK.
if (CRASHPAD_HANDLER_GENERATE_STATIC_LIB)
add_library(handlerlib STATIC ${CRASHPAD_HANDLER_LIBRARY_FILES})
target_compile_features(handlerlib PUBLIC cxx_std_17)
target_link_libraries(handlerlib PRIVATE client tools compat snapshot minidump)
target_include_directories(handlerlib PUBLIC ..)
endif(CRASHPAD_HANDLER_GENERATE_STATIC_LIB)

add_executable(handler main.cc)
target_sources(handler PRIVATE ${CRASHPAD_HANDLER_LIBRARY_FILES})
target_compile_features(handler PUBLIC cxx_std_17)
Expand Down Expand Up @@ -73,4 +81,4 @@ if (ANDROID)
${CUSTOM_CRASHPAD_HANDLER_DESTINATION}
)
endif (CUSTOM_CRASHPAD_HANDLER_DESTINATION)
endif (ANDROID)
endif (ANDROID)

0 comments on commit d3f854b

Please sign in to comment.