file-format.exp (gcc_target_object_format): Use ${tool}_target_compile, not gcc_targe...
authorMark Mitchell <mark@codesourcery.com>
Thu, 5 Feb 2004 05:09:38 +0000 (05:09 +0000)
committerMark Mitchell <mmitchel@gcc.gnu.org>
Thu, 5 Feb 2004 05:09:38 +0000 (05:09 +0000)
* lib/file-format.exp (gcc_target_object_format): Use
${tool}_target_compile, not gcc_target_compile.
* lib/target-supports.exp (check_alias_available): Likewise.
(check_gc_sections_available): Likewise.
* g++.dg/ext/attrib10.C: Use dg-require-alias.
* g++.old-deja/g++.ext/attrib5.C: Use dg-require-weak and
dg-require-alias.

From-SVN: r77295

gcc/testsuite/ChangeLog
gcc/testsuite/g++.dg/ext/attrib10.C
gcc/testsuite/g++.old-deja/g++.ext/attrib5.C
gcc/testsuite/lib/file-format.exp
gcc/testsuite/lib/target-supports.exp

index 59badea..6c3db3e 100644 (file)
@@ -5,6 +5,16 @@
 
 2004-02-04  Mark Mitchell  <mark@codesourcery.com>
 
+       * lib/file-format.exp (gcc_target_object_format): Use
+       ${tool}_target_compile, not gcc_target_compile.
+       * lib/target-supports.exp (check_alias_available): Likewise.
+       (check_gc_sections_available): Likewise.
+       * g++.dg/ext/attrib10.C: Use dg-require-alias.
+       * g++.old-deja/g++.ext/attrib5.C: Use dg-require-weak and
+       dg-require-alias.
+
+2004-02-04  Mark Mitchell  <mark@codesourcery.com>
+
        PR c++/13969
        * g++.dg/template/static6.C: New test.
 
index 6d04cb8..99459c7 100644 (file)
@@ -1,4 +1,5 @@
 // PR c++/12795
+// { dg-require-alias "" }
 
 void foo()
 {
index 7a77d61..545f128 100644 (file)
@@ -1,5 +1,7 @@
-// { dg-do run { xfail alpha*-dec-osf* *-*-hms i?86-pc-cygwin *-*-coff hppa2*-hp-hpux11* } }
+// { dg-do run { xfail alpha*-dec-osf* *-*-hms i?86-pc-cygwin *-*-coff } }
 // Test that attributes weak and alias coexist.
+// { dg-require-weak "" }
+// { dg-require-alias "" }
 
 extern "C" {
   void f () __attribute__((weak, alias ("_f")));
index a4168b6..ab69f93 100644 (file)
@@ -24,6 +24,7 @@
 
 proc gcc_target_object_format { } { 
     global gcc_target_object_format_saved
+    global tool
 
     if [info exists gcc_target_object_format_saved] {
         verbose "gcc_target_object_format returning saved $gcc_target_object_format_saved" 2
@@ -33,7 +34,7 @@ proc gcc_target_object_format { } {
         puts $open_file "void foo(void) { }"
         close $open_file
         
-        gcc_target_compile objfmtst.c objfmtst.o object ""
+        ${tool}_target_compile objfmtst.c objfmtst.o object ""
         
        catch {
           set output [exec $objdump_name --file-headers objfmtst.o ]
index bff0a4f..33d72fd 100644 (file)
@@ -99,7 +99,8 @@ proc check_visibility_available { } {
 
 proc check_alias_available { } {
     global alias_available_saved
-    
+    global tool
+
     if [info exists alias_available_saved] {
         verbose "check_alias_available  returning saved $alias_available_saved" 2
     } else {
@@ -110,7 +111,7 @@ proc check_alias_available { } {
        # about the program.
        puts $f "void g() {} void f() __attribute__((alias(\"g\")));"
        close $f
-       set lines [gcc_target_compile "tmp.c" "tmp.o" object ""]
+       set lines [${tool}_target_compile "tmp.c" "tmp.o" object ""]
        file delete "tmp.c"
 
        if [string match "" $lines] then {
@@ -148,10 +149,11 @@ proc check_alias_available { } {
 
 proc check_gc_sections_available { } {
     global gc_sections_available_saved
+    global tool
 
     if {![info exists gc_sections_available_saved]} {
        # Check if the ld used by gcc supports --gc-sections.
-       set gcc_ld [lindex [gcc_target_compile "-print-prog-name=ld" "" "none" ""] 0]
+       set gcc_ld [lindex [${tool}_target_compile "-print-prog-name=ld" "" "none" ""] 0]
        set ld_output [remote_exec host "$gcc_ld" "--help"]
        if { [ string first "--gc-sections" $ld_output ] >= 0 } {
            set gc_sections_available_saved 1