userland: disable PIE explicitly on command line for all executables

This commit is contained in:
Ciro Santilli 六四事件 法轮功
2019-05-14 00:00:01 +00:00
parent 91986fb295
commit c17ee0bdce

View File

@@ -17,6 +17,15 @@ class PathProperties:
'-Wno-unused-function', LF,
'-fopenmp', LF,
'-ggdb3', LF,
# PIE causes the following problems:
# * QEMU GDB step debug does not find breakpoints:
# https://stackoverflow.com/questions/51310756/how-to-gdb-step-debug-a-dynamically-linked-executable-in-qemu-user-mode/51343326#51343326
# * when writing assembly code, we have to constantly think about it:
# https://stackoverflow.com/questions/2463150/what-is-the-fpie-option-for-position-independent-executables-in-gcc-and-ld/51308031#51308031
# As of 91986fb2955f96e06d1c5ffcc5536ba9f0af1fd9, our Buildroot toolchain
# does not have it enabled by default, but the Ubuntu 18.04 host toolchain does.
'-fno-pie', LF,
'-no-pie', LF,
],
'cc_flags_after': [],
'cc_pedantic': True,
@@ -266,10 +275,6 @@ path_properties_tuples = (
{
'arch': (
{
'cc_flags': [
'-fno-pie', LF,
'-no-pie', LF,
],
'extra_objs_userland_asm': True,
},
{