aboutsummaryrefslogtreecommitdiff
path: root/src/tools
diff options
context:
space:
mode:
authorShauren <shauren.trinity@gmail.com>2024-09-15 12:13:54 +0200
committerShauren <shauren.trinity@gmail.com>2024-09-15 12:13:54 +0200
commitfd0a7ba871060c895fdf701799dbf649ee697078 (patch)
tree88c6d64fce3df94b545b2c13b3c7178d465b3f03 /src/tools
parent6a5b24cacc4ea2eb55c481c400621a97d940b905 (diff)
Core/CrashHandler: Compile WheatyExceptionReport only once and moved its global variable initializer to all projects using it
Diffstat (limited to 'src/tools')
-rw-r--r--src/tools/map_extractor/System.cpp6
-rw-r--r--src/tools/mmaps_generator/PathGenerator.cpp6
-rw-r--r--src/tools/vmap4_assembler/VMapAssembler.cpp6
-rw-r--r--src/tools/vmap4_extractor/vmapexport.cpp6
4 files changed, 24 insertions, 0 deletions
diff --git a/src/tools/map_extractor/System.cpp b/src/tools/map_extractor/System.cpp
index ca91068a234..698adff25c1 100644
--- a/src/tools/map_extractor/System.cpp
+++ b/src/tools/map_extractor/System.cpp
@@ -1567,3 +1567,9 @@ int main(int argc, char * arg[])
return 0;
}
+
+#if TRINITY_PLATFORM == TRINITY_PLATFORM_WINDOWS
+#include "WheatyExceptionReport.h"
+// must be at end of file because of init_seg pragma
+INIT_CRASH_HANDLER();
+#endif
diff --git a/src/tools/mmaps_generator/PathGenerator.cpp b/src/tools/mmaps_generator/PathGenerator.cpp
index 4b9620bff1f..f3ba4ab48b6 100644
--- a/src/tools/mmaps_generator/PathGenerator.cpp
+++ b/src/tools/mmaps_generator/PathGenerator.cpp
@@ -458,3 +458,9 @@ int main(int argc, char** argv)
printf("Finished. MMAPS were built in %s\n", secsToTimeString(GetMSTimeDiffToNow(start) / 1000).c_str());
return 0;
}
+
+#if TRINITY_PLATFORM == TRINITY_PLATFORM_WINDOWS
+#include "WheatyExceptionReport.h"
+// must be at end of file because of init_seg pragma
+INIT_CRASH_HANDLER();
+#endif
diff --git a/src/tools/vmap4_assembler/VMapAssembler.cpp b/src/tools/vmap4_assembler/VMapAssembler.cpp
index 444f748753c..5cdc214665e 100644
--- a/src/tools/vmap4_assembler/VMapAssembler.cpp
+++ b/src/tools/vmap4_assembler/VMapAssembler.cpp
@@ -111,3 +111,9 @@ Optional<int> HandleArgs(int argc, char* argv[], std::string* src, std::string*
return {};
}
+
+#if TRINITY_PLATFORM == TRINITY_PLATFORM_WINDOWS
+#include "WheatyExceptionReport.h"
+// must be at end of file because of init_seg pragma
+INIT_CRASH_HANDLER();
+#endif
diff --git a/src/tools/vmap4_extractor/vmapexport.cpp b/src/tools/vmap4_extractor/vmapexport.cpp
index 9ab9ccfac19..cc518cfab50 100644
--- a/src/tools/vmap4_extractor/vmapexport.cpp
+++ b/src/tools/vmap4_extractor/vmapexport.cpp
@@ -604,3 +604,9 @@ int main(int argc, char ** argv)
printf("Extract %s. Work complete. No errors.\n", VMAP::VMAP_MAGIC);
return 0;
}
+
+#if TRINITY_PLATFORM == TRINITY_PLATFORM_WINDOWS
+#include "WheatyExceptionReport.h"
+// must be at end of file because of init_seg pragma
+INIT_CRASH_HANDLER();
+#endif