mirror of
https://github.com/djhackersdev/bemanitools.git
synced 2026-04-06 09:15:12 -05:00
fix(make): Include dwarf symbols and remove stripping
Expecting to improve debugability significantly. Stacktraces can be enhanced with function names, file names and line numbers when symbols are included in all exe and dll files. Furthermore, this also improves debugger usage as symbols can be imported to help navigate disassembly/decompiled code.
This commit is contained in:
parent
3a2ebae869
commit
cbb3d37f11
|
|
@ -27,7 +27,7 @@ toolchain_64 := x86_64-w64-mingw32-
|
|||
|
||||
gitrev := $(shell git rev-parse HEAD)
|
||||
cppflags := -I src -I src/main -I src/test -DGITREV=$(gitrev)
|
||||
cflags := -O2 -pipe -ffunction-sections -fdata-sections \
|
||||
cflags := -g -O2 -pipe -ffunction-sections -fdata-sections \
|
||||
-Wall -std=c99 -DPSAPI_VERSION=1
|
||||
cflags_release := -Werror
|
||||
ldflags := -Wl,--gc-sections -static-libgcc
|
||||
|
|
@ -266,7 +266,6 @@ $$(dll_$1_$2_$3) $$(implib_$1_$2_$3): $$(obj_$1_$2_$3) $$(abslib_$1_$2_$3) \
|
|||
$(V)$$(toolchain_$1)gcc -shared \
|
||||
-o $$(dll_$1_$2_$3) -Wl,--out-implib,$$(implib_$1_$2_$3) \
|
||||
-Wl,--start-group $$^ -Wl,--end-group $$(ldflags_$3)
|
||||
$(V)$$(toolchain_$1)strip $$(dll_$1_$2_$3)
|
||||
$(V)$$(toolchain_$1)ranlib $$(implib_$1_$2_$3)
|
||||
|
||||
endef
|
||||
|
|
@ -283,7 +282,6 @@ $$(exe_$1_$2_$3): $$(obj_$1_$2_$3) $$(abslib_$1_$2_$3) $$(absdpl_$1_$2_$3) \
|
|||
| $$(bindir_$1_$2)
|
||||
$(V)echo ... $$@
|
||||
$(V)$$(toolchain_$1)gcc -o $$@ $$^ $$(ldflags_$3)
|
||||
$(V)$$(toolchain_$1)strip $$@
|
||||
|
||||
endef
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user