From e013d20dc73b40d4b70c4a366c9adc619503e66b Mon Sep 17 00:00:00 2001 From: "H.J. Lu" Date: Thu, 17 Jun 2021 10:32:27 -0700 Subject: x86-64: Use $NOPIE_LDFLAGS/$NOPIE_CFLAGS on protected-func-1 PR ld/27973 * testsuite/ld-x86-64/x86-64.exp: Pass $NOPIE_LDFLAGS and $NOPIE_CFLAGS to protected-func-1 without PIE. --- ld/ChangeLog | 6 ++++++ ld/testsuite/ld-x86-64/x86-64.exp | 3 ++- 2 files changed, 8 insertions(+), 1 deletion(-) (limited to 'ld') diff --git a/ld/ChangeLog b/ld/ChangeLog index 2b46bb92b6a..37a373b5db1 100644 --- a/ld/ChangeLog +++ b/ld/ChangeLog @@ -1,3 +1,9 @@ +2021-06-17 H.J. Lu + + PR ld/27973 + * testsuite/ld-x86-64/x86-64.exp: Pass $NOPIE_LDFLAGS and + $NOPIE_CFLAGS to protected-func-1 without PIE. + 2021-06-17 H.J. Lu PR ld/27973 diff --git a/ld/testsuite/ld-x86-64/x86-64.exp b/ld/testsuite/ld-x86-64/x86-64.exp index 5dc9a1c218e..21a4824e3d1 100644 --- a/ld/testsuite/ld-x86-64/x86-64.exp +++ b/ld/testsuite/ld-x86-64/x86-64.exp @@ -1740,11 +1740,12 @@ if { [isnative] && [check_compiler_available] } { ] \ [list \ "Run protected-func-1 without PIE" \ - "-Wl,--no-as-needed tmpdir/libprotected-func-1.so" \ + "$NOPIE_LDFLAGS -Wl,--no-as-needed tmpdir/libprotected-func-1.so" \ "-Wa,-mx86-used-note=yes" \ { protected-func-1b.c } \ "protected-func-1a" \ "pass.out" \ + "$NOPIE_CFLAGS" \ ] \ [list \ "Run protected-func-1 with PIE" \ -- cgit v1.2.1