[host] windows/crash: do not report absolute paths on build machines

This commit makes the crash handler show relative paths instead of absolute
ones, which makes the stack traces generated easier to read.

On the other hand, absolute paths makes sense on Linux, since the user is
expected to build the binaries themselves, and gdb will be able to find the
source code.
This commit is contained in:
Quantum 2021-08-13 02:09:54 -04:00 committed by Geoffrey McRae
parent acd5ce51db
commit 074341e421

View File

@ -27,6 +27,10 @@ add_compile_options(
)
set(CMAKE_C_STANDARD 11)
if(WIN32)
add_compile_options("-fdebug-prefix-map=${PROJECT_TOP}/=")
endif()
add_custom_command(
OUTPUT ${CMAKE_BINARY_DIR}/version.c
${CMAKE_BINARY_DIR}/include/version.h