target-supports.exp (check_gc_sections_available): Return false if ldflags includes...
authorKazu Hirata <kazu@codesourcery.com>
Sat, 14 Apr 2007 02:05:43 +0000 (02:05 +0000)
committerKazu Hirata <kazu@gcc.gnu.org>
Sat, 14 Apr 2007 02:05:43 +0000 (02:05 +0000)
* lib/target-supports.exp (check_gc_sections_available):
Return false if ldflags includes -elf2flt.

From-SVN: r123810

gcc/testsuite/ChangeLog
gcc/testsuite/lib/target-supports.exp

index 38d12d6bcf2d7cf2c3ac3d5d38b72402e4e623e4..5ab36769d0928b23a559e266ba28a2c192e0ce16 100644 (file)
@@ -2,6 +2,9 @@
 
        * gcc.c-torture/compile/pr27528.c: Require nonpic.
 
+       * lib/target-supports.exp (check_gc_sections_available):
+       Return false if ldflags includes -elf2flt.
+
 2007-04-13  Jason Merrill  <jason@redhat.com>
 
        PR c++/31074
index 180686f69bf06c5e1bca5c327e2cab508fb215d2..9966197c16c157ec5823665c44818a049c810398 100644 (file)
@@ -286,6 +286,14 @@ proc check_gc_sections_available { } {
            return 0
        }
 
+       # elf2flt uses -q (--emit-relocs), which is incompatible with
+       # --gc-sections.
+       if { [board_info target exists ldflags]
+            && [regexp " -elf2flt\[ =\]" " [board_info target ldflags] "] } {
+           set gc_sections_available_saved 0
+           return 0
+       }
+
        # VxWorks kernel modules are relocatable objects linked with -r,
        # while RTP executables are linked with -q (--emit-relocs).
        # Both of these options are incompatible with --gc-sections.