testsuite: extend nopie handling to add -fno-pie to compiler flags
Some older GCC, e.g. 7.5.0 on Ubuntu 18.04 need -fno-pie to be passed to
the compiler in addition to -no-pie to be passed to the linker for non-pie
code generation.
The gdb,nopie_flag is already documented as getting passed to the
compiler, not the linker. Use that for the new -fno-pie compiler flag and
add a new gdb,nopie_ldflag for the existing -no-pie linker flag.
CAUTION: this might break existing board files that specify
gdb,nopie_flag. Affected board files need to rename
gdb,nopie_flag into gdb,nopie_ldflag.
diff --git a/gdb/testsuite/README b/gdb/testsuite/README
index f3c2642..0036753 100644
--- a/gdb/testsuite/README
+++ b/gdb/testsuite/README
@@ -528,6 +528,11 @@
The flag required to force the compiler to produce non-position-independent
executables.
+gdb,nopie_ldflag
+
+ The flag required to force the linker to produce non-position-independent
+ executables.
+
gdb,debug
When set gdb debug is sent to the file gdb.debug in the test output