Fix building on Fedora, by adding the Position Independant Code flag when building with gcc. This flag is not supposed to break anything and did not cause troubles when testing it on some other platforms than Fedora.

Based on patch by bb, fixes #3869

This was SVN commit r18729.
This commit is contained in:
Nicolas Auvray 2016-09-18 08:54:27 +00:00
parent eb09c2a8c5
commit 184d64cdc8

View File

@ -282,6 +282,7 @@ function project_set_build_flags()
end
if os.is("linux") or os.is("bsd") then
buildoptions { "-fPIC" }
linkoptions { "-Wl,--no-undefined", "-Wl,--as-needed" }
end