]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
i386: testsuite: Add -no-pie for pr113689-1.c [PR70150]
authorXi Ruoyao <xry111@xry111.site>
Mon, 6 May 2024 03:33:43 +0000 (11:33 +0800)
committerXi Ruoyao <xry111@xry111.site>
Sat, 10 Aug 2024 16:18:25 +0000 (00:18 +0800)
For a --enable-default-pie build, using -fno-pic (for compiler) but
not -no-pie (for linker) triggers some linker warnings counted as
excess errors:

    /usr/bin/ld: /tmp/cc8MgxiR.o: warning: relocation in read-only
    section `.text.startup'
    /usr/bin/ld: warning: creating DT_TEXTREL in a PIE

gcc/testsuite/ChangeLog:

PR testsuite/70150
* gcc.target/i386/pr113689-1.c (dg-options): Add -no-pie.

gcc/testsuite/gcc.target/i386/pr113689-1.c

index 9b8474ed9330cb8298ff105b4008f016fd47cc58..0424db2dfdca03c7c7786114547f9dc8a38cf979 100644 (file)
@@ -1,5 +1,5 @@
 /* { dg-do run { target { lp64 && fpic } } } */
-/* { dg-options "-O2 -fno-pic -fprofile -mcmodel=large" } */
+/* { dg-options "-O2 -fno-pic -no-pie -fprofile -mcmodel=large" } */
 /* { dg-skip-if "PR90698" { *-*-darwin* } } */
 /* { dg-skip-if "PR113909" { *-*-solaris2* } } */