mirror of
https://github.com/cirosantilli/linux-kernel-module-cheat.git
synced 2026-01-28 12:34:26 +01:00
userland: disable PIE explicitly on command line for all executables
This commit is contained in:
@@ -17,6 +17,15 @@ class PathProperties:
|
|||||||
'-Wno-unused-function', LF,
|
'-Wno-unused-function', LF,
|
||||||
'-fopenmp', LF,
|
'-fopenmp', LF,
|
||||||
'-ggdb3', 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_flags_after': [],
|
||||||
'cc_pedantic': True,
|
'cc_pedantic': True,
|
||||||
@@ -266,10 +275,6 @@ path_properties_tuples = (
|
|||||||
{
|
{
|
||||||
'arch': (
|
'arch': (
|
||||||
{
|
{
|
||||||
'cc_flags': [
|
|
||||||
'-fno-pie', LF,
|
|
||||||
'-no-pie', LF,
|
|
||||||
],
|
|
||||||
'extra_objs_userland_asm': True,
|
'extra_objs_userland_asm': True,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|||||||
Reference in New Issue
Block a user