BZ 471705 (re)add SH architecture support.

This commit is contained in:
Nicholas Clifton 2008-11-19 11:52:37 +00:00
parent 2de8709d93
commit 48cbdf2e58

View File

@ -135,7 +135,7 @@ echo target is %{binutils_target}
export CFLAGS="$RPM_OPT_FLAGS" export CFLAGS="$RPM_OPT_FLAGS"
CARGS= CARGS=
case %{binutils_target} in i?86*|sparc*|ppc*|s390*) case %{binutils_target} in i?86*|sparc*|ppc*|s390*|sh*)
CARGS="$CARGS --enable-64-bit-bfd" CARGS="$CARGS --enable-64-bit-bfd"
;; ;;
esac esac
@ -224,7 +224,7 @@ rm -f %{buildroot}%{_prefix}/%{_lib}/lib{bfd,opcodes}.la
# Sanity check --enable-64-bit-bfd really works. # Sanity check --enable-64-bit-bfd really works.
grep '^#define BFD_ARCH_SIZE 64$' %{buildroot}%{_prefix}/include/bfd.h grep '^#define BFD_ARCH_SIZE 64$' %{buildroot}%{_prefix}/include/bfd.h
# Fix multilib conflicts of generated values by __WORDSIZE-based expressions. # Fix multilib conflicts of generated values by __WORDSIZE-based expressions.
%ifarch %{ix86} x86_64 ppc ppc64 s390 s390x sparc sparc64 %ifarch %{ix86} x86_64 ppc ppc64 s390 s390x sh3 sh4 sparc sparc64
sed -i -e '/^#include "ansidecl.h"/{p;s~^.*$~#include <bits/wordsize.h>~;}' \ sed -i -e '/^#include "ansidecl.h"/{p;s~^.*$~#include <bits/wordsize.h>~;}' \
-e 's/^#define BFD_DEFAULT_TARGET_SIZE \(32\|64\) *$/#define BFD_DEFAULT_TARGET_SIZE __WORDSIZE/' \ -e 's/^#define BFD_DEFAULT_TARGET_SIZE \(32\|64\) *$/#define BFD_DEFAULT_TARGET_SIZE __WORDSIZE/' \
-e 's/^#define BFD_HOST_64BIT_LONG [01] *$/#define BFD_HOST_64BIT_LONG (__WORDSIZE == 64)/' \ -e 's/^#define BFD_HOST_64BIT_LONG [01] *$/#define BFD_HOST_64BIT_LONG (__WORDSIZE == 64)/' \