[PATCH] SH endian setting

NIIBE Yutaka gniibe@m17n.org
Thu Dec 13 03:12:00 GMT 2001
Here is a bug fix for gas/configure.in.  I've found this when I build
gas for sh3eb-unknown-linux-gnu.

When it comes the line "# assign object format", the variable
${generic_target} has the value sh-unknown-linux-gnu (${cpu_type} is
set generic value 'sh').  So, it doesn't go the case of
"sh*eb-*-linux*".

We should set endian looking the variable ${cpu}.

gas/ChangeLog
2001-12-13  NIIBE Yutaka  <gniibe@m17n.org>

	* configure.in (assign object format): Bug fix for setting
	endian.

Index: gas/configure.in
===================================================================
RCS file: /cvs/redhat-src/src/gas/configure.in,v
retrieving revision 1.85
diff -u -3 -p -r1.85 configure.in
--- gas/configure.in	2001/12/08 03:45:55	1.85
+++ gas/configure.in	2001/12/13 10:30:48
@@ -394,8 +394,13 @@ changequote([,])dnl
       s390x-*-linux-gnu*)   fmt=elf em=linux ;;
       s390-*-linux-gnu*)    fmt=elf em=linux ;;
 
-      sh*eb-*-linux*)	    fmt=elf em=linux endian=big ;;
-      sh*-*-linux*)	    fmt=elf em=linux endian=little ;;
+      sh-*-linux*)	    fmt=elf em=linux
+			    case ${cpu} in
+				sh*eb)
+					endian=big ;;
+				sh*)
+					endian=little ;;
+			    esac ;;
       sh-*-elf*)	    fmt=elf ;;
       sh-*-coff*)           fmt=coff bfd_gas=yes;;
       sh-*-pe*)             fmt=coff em=pe bfd_gas=yes endian=little ;;
-- 



More information about the Binutils mailing list