mirror of https://github.com/godotengine/godot
Windows: Configure MinGW LTO with `-fno-use-linker-plugin -fwhole-program`
- Works around and closes #102867. - Works around and closes #102982. Co-authored-by: Hein-Pieter van Braam-Stewart <hp@tmm.cx>
This commit is contained in:
parent
fe799deee0
commit
26fd3458f9
|
|
@ -781,6 +781,10 @@ def configure_mingw(env: "SConsEnvironment"):
|
|||
else:
|
||||
env.Append(CCFLAGS=["-flto"])
|
||||
env.Append(LINKFLAGS=["-flto"])
|
||||
if not env["use_llvm"]:
|
||||
# For mingw-gcc LTO, disable linker plugin and enable whole program to work around GH-102867.
|
||||
env.Append(CCFLAGS=["-fno-use-linker-plugin", "-fwhole-program"])
|
||||
env.Append(LINKFLAGS=["-fno-use-linker-plugin", "-fwhole-program"])
|
||||
|
||||
if env["use_asan"]:
|
||||
env.Append(LINKFLAGS=["-Wl,--stack," + str(STACK_SIZE_SANITIZERS)])
|
||||
|
|
|
|||
Loading…
Reference in New Issue