From: Vincent Cheng Date: Sun, 13 Nov 2016 06:57:56 +0000 (+0000) Subject: Build with the "read-only relocation" hardening linker flag X-Git-Tag: archive/raspbian/0.0.25b-1.1+rpi1~1^2^2^2^2~2 X-Git-Url: https://dgit.raspbian.org/?a=commitdiff_plain;h=955dcd27ca09d5f9174dc4b36bfa6da549df39e2;p=0ad.git Build with the "read-only relocation" hardening linker flag Forwarded: http://trac.wildfiregames.com/ticket/1416 Last-Update: 2016-11-12 Pass "-Wl,-z,relro" to the linker. This fixes lintian warning "hardening-no-relro". Gbp-Pq: Name enable-hardening-relro.patch --- diff --git a/build/premake/premake4.lua b/build/premake/premake4.lua index 8473679..44af3a5 100644 --- a/build/premake/premake4.lua +++ b/build/premake/premake4.lua @@ -283,7 +283,7 @@ function project_set_build_flags() if os.is("linux") or os.is("bsd") then buildoptions { "-fPIC" } - linkoptions { "-Wl,--no-undefined", "-Wl,--as-needed" } + linkoptions { "-Wl,--no-undefined", "-Wl,--as-needed", "-Wl,-z,relro" } end if arch == "x86" then