This is the mail archive of the binutils@sourceware.org mailing list for the binutils project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[PATCH] MIPS ld. Fix selective testcases


Hello All,

I applied the appended patch, which fixes the selective{1,2,3}
testcases for MIPS.


Thiemo


2006-07-19  Thiemo Seufer  <ths@mips.com>

	* ld-selective/selective.exp: Fix selective testcases for MIPS.


Index: ld/testsuite/ld-selective/selective.exp
===================================================================
RCS file: /cvs/src/src/ld/testsuite/ld-selective/selective.exp,v
retrieving revision 1.35
diff -u -p -r1.35 selective.exp
--- ld/testsuite/ld-selective/selective.exp	22 May 2005 21:02:19 -0000	1.35
+++ ld/testsuite/ld-selective/selective.exp	18 Jul 2006 15:45:24 -0000
@@ -41,8 +41,8 @@ if {[istarget "alpha*-*-*"] || [istarget
 # FIXME: Instead of table, read settings from each source-file.
 set seltests {
   {selective1 C   1.c  {}       {}    {dropme1 dropme2} {}}
-  {selective2 C   2.c  {}       {}    {foo} {mips*-*}}
-  {selective3 C   2.c  {-u foo} {foo} {{foo 0}} {mips*-*}}
+  {selective2 C   2.c  {}       {}    {foo} {}}
+  {selective3 C   2.c  {-u foo} {foo} {{foo 0}} {}}
   {selective4 C++ 3.cc {}       {start a A::foo() B::foo()} {A::bar()} {mips*-*}}
   {selective5 C++ 4.cc {}       {start a A::bar()} {A::foo() B::foo()} {mips*-*}}
   {selective6 C++ 5.cc {}       {start a A::bar()}
@@ -53,6 +53,13 @@ set cflags "-w -O -ffunction-sections -f
 set cxxflags "-fvtable-gc -fno-exceptions -fno-rtti"
 set ldflags "--gc-sections -Bstatic"
 
+if [istarget mips*-*] {
+    # MIPS16 doesn't support PIC code.
+    set cflags "-mno-abicalls $cflags"
+    # MIPS ELF uses __start by default, we override it.
+    set ldflags "-e _start $ldflags"
+}
+
 if [istarget sh64*-*-elf] {
     # This is what gcc passes to ld by default, plus switch to the
     # "usual" ELF _start (shelf32 normally uses just `start' for COFF


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]