* SFEbinutils.spec: Add patch1 http://sourceware.org/bugzilla/show_bug.cgi?id=2495
Add patch2 http://www.cygwin.com/ml/binutils/2006-06/msg00299.html
Add patch3 http://sourceware.org/ml/binutils/2007-03/msg00175.html
* SFEgcc.spec: Change from /usr/ccs/bin/ld to /usr/gnu/bin/ld, this change
requires SFEbinutils built with binutils-01-bug-2495.diff,
binutils-02-ld-m-elf_i386.diff and binutils-03-lib-amd64-ld-so-1.diff.
Add objc to --enable-languages, add --enable-decimal-float.
--- a/ChangeLog Mon Aug 13 08:09:53 2007 +0000
+++ b/ChangeLog Tue Aug 14 15:41:47 2007 +0000
@@ -1,3 +1,13 @@
+2007-08-15 Mark Wright <[email protected]>
+
+ * SFEbinutils.spec: Add patch1 http://sourceware.org/bugzilla/show_bug.cgi?id=2495
+ Add patch2 http://www.cygwin.com/ml/binutils/2006-06/msg00299.html
+ Add patch3 http://sourceware.org/ml/binutils/2007-03/msg00175.html
+ * SFEgcc.spec: Change from /usr/ccs/bin/ld to /usr/gnu/bin/ld, this change
+ requires SFEbinutils built with binutils-01-bug-2495.diff,
+ binutils-02-ld-m-elf_i386.diff and binutils-03-lib-amd64-ld-so-1.diff.
+ Add objc to --enable-languages, add --enable-decimal-float.
+
2007-08-13 Doug Scott <[email protected]>
* SFEjack.spec: Added 64bit build
--- a/SFEbinutils.spec Mon Aug 13 08:09:53 2007 +0000
+++ b/SFEbinutils.spec Tue Aug 14 15:41:47 2007 +0000
@@ -10,6 +10,9 @@
Summary: GNU binutils
Version: 2.17
Source: http://ftp.gnu.org/gnu/binutils/binutils-%{version}.tar.bz2
+Patch1: binutils-01-bug-2495.diff
+Patch2: binutils-02-ld-m-elf_i386.diff
+Patch3: binutils-03-lib-amd64-ld-so-1.diff
SUNW_BaseDir: %{_basedir}
BuildRoot: %{_tmppath}/%{name}-%{version}-build
%include default-depend.inc
@@ -31,6 +34,17 @@
%prep
%setup -q -c -n %name-%version
+%ifarch amd64
+cd binutils-%{version}
+%patch1 -p1 -b .patch01
+cd ..
+%endif
+%ifarch i386 amd64
+cd binutils-%{version}
+%patch2 -p1 -b .patch02
+%patch3 -p1 -b .patch03
+cd ..
+%endif
%ifarch amd64 sparcv9
cp -pr binutils-%{version} binutils-%{version}-64
%endif
@@ -178,6 +192,10 @@
%endif
%changelog
+* Wed Aug 15 2007 - Mark Wright <[email protected]>
+- Add patch1 http://sourceware.org/bugzilla/show_bug.cgi?id=2495
+- Add patch2 http://www.cygwin.com/ml/binutils/2006-06/msg00299.html
+- Add patch3 http://sourceware.org/ml/binutils/2007-03/msg00175.html
* Mon Mar 18 2007 - Doug Scott <[email protected]>
- Removed standards.info
* Tue Feb 7 2007 - Doug Scott <[email protected]>
--- a/SFEgcc.spec Mon Aug 13 08:09:53 2007 +0000
+++ b/SFEgcc.spec Tue Aug 14 15:41:47 2007 +0000
@@ -61,11 +61,17 @@
export CONFIG_SHELL=/usr/bin/bash
export CFLAGS=""
+export CPP="cc -E -Xs"
export STAGE1_CFLAGS="$(CFLAGS)"
export CFLAGS_FOR_TARGET="-g -O3"
export LDFLAGS="%_ldflags %gnu_lib_path"
export LD_OPTIONS="%ld_options %gnu_lib_path"
+%define build_gcc_with_gnu_ld 1
+%if %build_gcc_with_gnu_ld
+export LD="/usr/gnu/bin/ld"
+%endif
+
../gcc-%{version}/configure \
--prefix=%{_prefix} \
--libdir=%{_libdir} \
@@ -74,11 +80,17 @@
--infodir=%{_infodir} \
--with-as=/usr/gnu/bin/as \
--with-gnu-as \
+%if %build_gcc_with_gnu_ld
+ --with-ld=/usr/gnu/bin/ld \
+ --with-gnu-ld \
+%else
--with-ld=/usr/ccs/bin/ld \
--without-gnu-ld \
- --enable-languages=c,c++,fortran \
+%endif
+ --enable-languages=c,c++,fortran,objc \
--enable-shared \
--disable-static \
+ --enable-decimal-float \
$nlsopt
make -j$CPUS bootstrap
@@ -88,7 +100,6 @@
export CONFIG_SHELL=/usr/bin/bash
export CFLAGS="%optflags"
-export CFLAGS="%optflags"
export STAGE1_CFLAGS="$(CFLAGS)"
export CFLAGS_FOR_TARGET="-g -O3"
export LDFLAGS="%_ldflags %gnu_lib_path"
@@ -174,6 +185,11 @@
%endif
%changelog
+* Wed Aug 15 2007 - Mark Wright <[email protected]>
+- Change from /usr/ccs/bin/ld to /usr/gnu/bin/ld, this change
+ requires SFEbinutils built with binutils-01-bug-2495.diff,
+ binutils-02-ld-m-elf_i386.diff and binutils-03-lib-amd64-ld-so-1.diff.
+ Add objc to --enable-languages, add --enable-decimal-float.
* Wed Jul 24 2007 - Mark Wright <[email protected]>
- Bump to 4.2.1, add patch for gcc bug 32787.
* Wed May 16 2007 - Doug Scott <[email protected]>
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/patches/binutils-01-bug-2495.diff Tue Aug 14 15:41:47 2007 +0000
@@ -0,0 +1,21 @@
+--- binutils-2.17-orig/bfd/elf64-x86-64.c 2006-03-23 09:23:09.000000000 +0100
++++ binutils-2.17/bfd/elf64-x86-64.c 2006-06-30 06:42:19.000000000 +0200
+@@ -3439,13 +3439,11 @@
+ const char *name,
+ int shindex)
+ {
+- if (hdr->sh_type != SHT_X86_64_UNWIND)
+- return FALSE;
+-
+- if (! _bfd_elf_make_section_from_shdr (abfd, hdr, name, shindex))
+- return FALSE;
+-
+- return TRUE;
++ if (hdr->sh_type == SHT_X86_64_UNWIND ||
++ (hdr->sh_type >= SHT_LOOS && hdr->sh_type <= SHT_HIOS)) {
++ return _bfd_elf_make_section_from_shdr (abfd, hdr, name, shindex);
++ }
++ return FALSE;
+ }
+
+ /* Hook called by the linker routine which adds symbols from an object
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/patches/binutils-02-ld-m-elf_i386.diff Tue Aug 14 15:41:47 2007 +0000
@@ -0,0 +1,15 @@
+--- binutils-2.17-orig/ld/configure.tgt 2006-04-05 12:41:57.000000000 +0000
++++ binutils-2.17/ld/configure.tgt 2007-08-14 13:03:25.258610734 +0000
+@@ -163,10 +163,12 @@
+ i[3-7]86-*-sysv[45]*) targ_emul=elf_i386 ;;
+ i[3-7]86-*-solaris2*) targ_emul=elf_i386_ldso
+ targ_extra_emuls="elf_i386 elf_x86_64"
++ targ_extra_libpath=$targ_extra_emuls
+ ;;
+ i[3-7]86-*-unixware) targ_emul=elf_i386 ;;
+ i[3-7]86-*-solaris*) targ_emul=elf_i386_ldso
+ targ_extra_emuls="elf_i386"
++ targ_extra_libpath=$targ_extra_emuls
+ ;;
+ i[3-7]86-*-netbsdelf* | \
+ i[3-7]86-*-netbsd*-gnu* | \
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/patches/binutils-03-lib-amd64-ld-so-1.diff Tue Aug 14 15:41:47 2007 +0000
@@ -0,0 +1,11 @@
+--- binutils-2.17-orig/bfd/elf64-x86-64.c 2007-08-14 13:23:07.461245000 +0000
++++ binutils-2.17/bfd/elf64-x86-64.c 2007-08-14 14:42:46.325761891 +0000
+@@ -327,7 +327,7 @@
+ /* The name of the dynamic interpreter. This is put in the .interp
+ section. */
+
+-#define ELF_DYNAMIC_INTERPRETER "/lib/ld64.so.1"
++#define ELF_DYNAMIC_INTERPRETER "/lib/amd64/ld.so.1"
+
+ /* If ELIMINATE_COPY_RELOCS is non-zero, the linker will try to avoid
+ copying dynamic variables from a shared lib into an app's dynbss