Skip to content

Commit 183de5b

Browse files
External crash reporter : Extend implementation, but leave it disabled for now (o3de#18631)
* Re-enable external crash handler on windows Signed-off-by: guillaume-haerinck <guillaume.haerinck@outlook.com> * Include crash handler to most standalone tools Signed-off-by: guillaume-haerinck <guillaume.haerinck@outlook.com> * Allow to manually report an issue Signed-off-by: guillaume-haerinck <guillaume.haerinck@outlook.com> * Disable crash handler for now as need more than just dump Signed-off-by: guillaume-haerinck <guillaume.haerinck@outlook.com> * Conditionally add external crash reporter as dependency Signed-off-by: guillaume-haerinck <guillaume.haerinck@outlook.com> * Remove old pal annotations Signed-off-by: guillaume-haerinck <guillaume.haerinck@outlook.com> --------- Signed-off-by: guillaume-haerinck <guillaume.haerinck@outlook.com>
1 parent 585bb27 commit 183de5b

File tree

31 files changed

+168
-21
lines changed

31 files changed

+168
-21
lines changed

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,3 +23,4 @@ _savebackup/
2323
*.swatches
2424
/imgui.ini
2525
.command_settings
26+
CrashDB/

Code/Editor/CMakeLists.txt

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -122,6 +122,11 @@ ly_add_target(
122122
RUNTIME_DEPENDENCIES
123123
Legacy::EditorCommon
124124
)
125+
126+
if(PAL_TRAIT_BUILD_EXTERNAL_CRASH_HANDLER_SUPPORTED)
127+
ly_target_link_libraries(EditorLib PRIVATE AZ::ToolsCrashHandler)
128+
endif()
129+
125130
ly_add_source_properties(
126131
SOURCES CryEdit.cpp
127132
PROPERTY COMPILE_DEFINITIONS

Code/Legacy/CrySystem/DebugCallStack.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -604,7 +604,7 @@ void DebugCallStack::SaveExceptionInfoAndShowUserReportDialogs(EXCEPTION_POINTER
604604
else if (auto nativeUI = AZ::Interface<AZ::NativeUI::NativeUIRequests>::Get(); nativeUI != nullptr)
605605
{
606606
AZStd::string msg = AZStd::string::format(
607-
"O3DE has encountered an unexpected error.\n\nDo you want to manually report the issue on Github ?\nInformation about the "
607+
"O3DE has encountered an unexpected error.\n\nDo you want to manually report the issue ?\nInformation about the "
608608
"crash are located in %s via error.log and error.dmp",
609609
path.c_str());
610610
constexpr bool showCancel = false;

Code/Tools/AssetProcessor/CMakeLists.txt

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -78,6 +78,10 @@ ly_add_target(
7878
AZ::AssetBuilder
7979
)
8080

81+
if(PAL_TRAIT_BUILD_EXTERNAL_CRASH_HANDLER_SUPPORTED)
82+
ly_target_link_libraries(AssetProcessor PRIVATE AZ::ToolsCrashHandler)
83+
endif()
84+
8185
# Adds the AssetProcessor target as a C preprocessor define so that it can be used as a Settings Registry
8286
# specialization in order to look up the generated .setreg which contains the dependencies
8387
# specified for the target.

Code/Tools/CrashHandler/CMakeLists.txt

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ o3de_pal_dir(pal_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/${PAL_PLATFORM_NAME} ${O
1010

1111
include(${pal_dir}/PAL_${PAL_PLATFORM_NAME_LOWERCASE}.cmake)
1212

13-
if(NOT PAL_TRAIT_BUILD_CRASH_HANDLER_SUPPORTED)
13+
if(NOT PAL_TRAIT_BUILD_EXTERNAL_CRASH_HANDLER_SUPPORTED)
1414
return()
1515
endif()
1616

@@ -28,6 +28,9 @@ ly_add_target(
2828
Shared
2929
PRIVATE
3030
${pal_dir}
31+
COMPILE_DEFINITIONS
32+
PUBLIC
33+
EXTERNAL_CRASH_REPORTING
3134
BUILD_DEPENDENCIES
3235
PUBLIC
3336
AZ::CrashSupport

Code/Tools/CrashHandler/Platform/Android/PAL_android.cmake

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,4 +6,3 @@
66
#
77
#
88

9-
set(PAL_TRAIT_BUILD_CRASH_HANDLER_SUPPORTED FALSE)

Code/Tools/CrashHandler/Platform/Linux/PAL_linux.cmake

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,4 +6,3 @@
66
#
77
#
88

9-
set(PAL_TRAIT_BUILD_CRASH_HANDLER_SUPPORTED FALSE)

Code/Tools/CrashHandler/Platform/Mac/PAL_mac.cmake

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,4 +6,3 @@
66
#
77
#
88

9-
set(PAL_TRAIT_BUILD_CRASH_HANDLER_SUPPORTED FALSE)

Code/Tools/CrashHandler/Platform/Windows/PAL_windows.cmake

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,4 +6,3 @@
66
#
77
#
88

9-
set(PAL_TRAIT_BUILD_CRASH_HANDLER_SUPPORTED TRUE)

Code/Tools/CrashHandler/Platform/iOS/PAL_ios.cmake

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,4 +6,3 @@
66
#
77
#
88

9-
set(PAL_TRAIT_BUILD_CRASH_HANDLER_SUPPORTED FALSE)

0 commit comments

Comments
 (0)