test: ensure that we dead-strip in the linker

`/OPT:REF` is needed for link to dead strip functions, `/Gy` by itself
is not sufficient.
This commit is contained in:
Saleem Abdulrasool 2019-12-24 10:18:13 -08:00
parent a21beccea2
commit 64c6bb3783
1 changed files with 1 additions and 0 deletions

View File

@ -8,6 +8,7 @@ ifeq "$(OS)" "Darwin"
LD_EXTRAS = -Xlinker -dead_strip
else ifeq "$(OS)" "Windows_NT"
CFLAGS_EXTRAS += /Gw /Gy
LD_EXTRAS = -Xlinker /OPT:REF
else
CFLAGS_EXTRAS += -fdata-sections -ffunction-sections
LD_EXTRAS = -Wl,--gc-sections