From 0c0b6c3ed0e28a989bd971278672f37ac0d5119d Mon Sep 17 00:00:00 2001 From: Spoike Date: Sun, 16 Aug 2020 04:40:13 +0000 Subject: [PATCH] Try to explicitly opt in/out to windows's ASLR in release/debug builds. git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@5746 fc73d0e0-1445-4013-8a0c-d673dee63da5 --- engine/Makefile | 2 ++ 1 file changed, 2 insertions(+) diff --git a/engine/Makefile b/engine/Makefile index 3201f9bf2..ed7249e02 100644 --- a/engine/Makefile +++ b/engine/Makefile @@ -1335,6 +1335,8 @@ ifeq (win,$(findstring win,$(FTE_TARGET))$(findstring _SDL,$(FTE_TARGET))) endif #Note: for deterministic builds, the following line disables timestamps for import/export tables. This is UNSAFE if there are any PE files bound to the compiled PE file. Our plugin dlls are dynamically loaded so this should not be an issue for us. BASELDFLAGS+=-Wl,--no-insert-timestamp + DEBUG_LDFLAGS=-Wl,--no-dynamicbase #debug builds are useful for catching crashes. the resulting stack traces are not very useful if we don't even know what the base address should be. + RELEASE_LDFLAGS=-Wl,--dynamicbase #release builds should attempt to use aslr BASELDFLAGS+=-lcomctl32 EXEPOSTFIX=.exe