summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRalf Corsepius <ralf.corsepius@rtems.org>2008-09-03 09:30:34 +0000
committerRalf Corsepius <ralf.corsepius@rtems.org>2008-09-03 09:30:34 +0000
commit86837601681bfed80f6003341e3be3f3a7b4590f (patch)
tree2a2bca9757c7ae798efb5c80547f04b1bb107c5f
parent63d797186ea0bbcbf043fdd0d10469af7f493c51 (diff)
Regenerate.
-rw-r--r--contrib/crossrpms/rtems4.8/arm/Makefile.am6
-rw-r--r--contrib/crossrpms/rtems4.8/arm/gcc-sources.add2
-rw-r--r--contrib/crossrpms/rtems4.8/arm/rtems-4.8-arm-rtems4.8-binutils.spec33
-rw-r--r--contrib/crossrpms/rtems4.8/arm/rtems-4.8-arm-rtems4.8-gcc.spec82
-rw-r--r--contrib/crossrpms/rtems4.8/arm/rtems-4.8-arm-rtems4.8-gdb.spec6
-rw-r--r--contrib/crossrpms/rtems4.8/bfin/Makefile.am6
-rw-r--r--contrib/crossrpms/rtems4.8/bfin/gcc-sources.add2
-rw-r--r--contrib/crossrpms/rtems4.8/bfin/rtems-4.8-bfin-rtems4.8-binutils.spec33
-rw-r--r--contrib/crossrpms/rtems4.8/bfin/rtems-4.8-bfin-rtems4.8-gcc.spec79
-rw-r--r--contrib/crossrpms/rtems4.8/bfin/rtems-4.8-bfin-rtems4.8-gdb.spec6
-rw-r--r--contrib/crossrpms/rtems4.8/h8300/Makefile.am6
-rw-r--r--contrib/crossrpms/rtems4.8/h8300/gcc-sources.add2
-rw-r--r--contrib/crossrpms/rtems4.8/h8300/rtems-4.8-h8300-rtems4.8-binutils.spec33
-rw-r--r--contrib/crossrpms/rtems4.8/h8300/rtems-4.8-h8300-rtems4.8-gcc.spec82
-rw-r--r--contrib/crossrpms/rtems4.8/h8300/rtems-4.8-h8300-rtems4.8-gdb.spec6
-rw-r--r--contrib/crossrpms/rtems4.8/i386/Makefile.am6
-rw-r--r--contrib/crossrpms/rtems4.8/i386/gcc-sources.add2
-rw-r--r--contrib/crossrpms/rtems4.8/i386/rtems-4.8-i386-rtems4.8-binutils.spec33
-rw-r--r--contrib/crossrpms/rtems4.8/i386/rtems-4.8-i386-rtems4.8-gcc.spec82
-rw-r--r--contrib/crossrpms/rtems4.8/i386/rtems-4.8-i386-rtems4.8-gdb.spec6
-rw-r--r--contrib/crossrpms/rtems4.8/m68k/Makefile.am6
-rw-r--r--contrib/crossrpms/rtems4.8/m68k/gcc-sources.add2
-rw-r--r--contrib/crossrpms/rtems4.8/m68k/rtems-4.8-m68k-rtems4.8-binutils.spec33
-rw-r--r--contrib/crossrpms/rtems4.8/m68k/rtems-4.8-m68k-rtems4.8-gcc.spec82
-rw-r--r--contrib/crossrpms/rtems4.8/m68k/rtems-4.8-m68k-rtems4.8-gdb.spec6
-rw-r--r--contrib/crossrpms/rtems4.8/mips/Makefile.am6
-rw-r--r--contrib/crossrpms/rtems4.8/mips/gcc-sources.add2
-rw-r--r--contrib/crossrpms/rtems4.8/mips/rtems-4.8-mips-rtems4.8-binutils.spec33
-rw-r--r--contrib/crossrpms/rtems4.8/mips/rtems-4.8-mips-rtems4.8-gcc.spec82
-rw-r--r--contrib/crossrpms/rtems4.8/mips/rtems-4.8-mips-rtems4.8-gdb.spec6
-rw-r--r--contrib/crossrpms/rtems4.8/mipstx39/Makefile.am2
-rw-r--r--contrib/crossrpms/rtems4.8/mipstx39/rtems-4.8-mipstx39-rtems4.8-gdb.spec6
-rw-r--r--contrib/crossrpms/rtems4.8/powerpc/Makefile.am6
-rw-r--r--contrib/crossrpms/rtems4.8/powerpc/gcc-sources.add2
-rw-r--r--contrib/crossrpms/rtems4.8/powerpc/rtems-4.8-powerpc-rtems4.8-binutils.spec33
-rw-r--r--contrib/crossrpms/rtems4.8/powerpc/rtems-4.8-powerpc-rtems4.8-gcc.spec82
-rw-r--r--contrib/crossrpms/rtems4.8/powerpc/rtems-4.8-powerpc-rtems4.8-gdb.spec6
-rw-r--r--contrib/crossrpms/rtems4.8/sh/Makefile.am6
-rw-r--r--contrib/crossrpms/rtems4.8/sh/gcc-sources.add2
-rw-r--r--contrib/crossrpms/rtems4.8/sh/rtems-4.8-sh-rtems4.8-binutils.spec33
-rw-r--r--contrib/crossrpms/rtems4.8/sh/rtems-4.8-sh-rtems4.8-gcc.spec82
-rw-r--r--contrib/crossrpms/rtems4.8/sh/rtems-4.8-sh-rtems4.8-gdb.spec6
-rw-r--r--contrib/crossrpms/rtems4.8/sparc/Makefile.am6
-rw-r--r--contrib/crossrpms/rtems4.8/sparc/gcc-sources.add2
-rw-r--r--contrib/crossrpms/rtems4.8/sparc/rtems-4.8-sparc-rtems4.8-binutils.spec33
-rw-r--r--contrib/crossrpms/rtems4.8/sparc/rtems-4.8-sparc-rtems4.8-gcc.spec82
-rw-r--r--contrib/crossrpms/rtems4.8/sparc/rtems-4.8-sparc-rtems4.8-gdb.spec6
47 files changed, 956 insertions, 210 deletions
diff --git a/contrib/crossrpms/rtems4.8/arm/Makefile.am b/contrib/crossrpms/rtems4.8/arm/Makefile.am
index f96bf3ff05..c5e2566d64 100644
--- a/contrib/crossrpms/rtems4.8/arm/Makefile.am
+++ b/contrib/crossrpms/rtems4.8/arm/Makefile.am
@@ -6,19 +6,19 @@ include $(top_srcdir)/mkspec.am
BINUTILS_VERS = 2.18
BINUTILS_PKGVERS = $(BINUTILS_VERS)
-BINUTILS_RPMREL = 3%{?dist}
+BINUTILS_RPMREL = 4%{?dist}
include ../binutils.am
BINUTILS_OPTS +=
GCC_VERS = 4.2.4
GCC_PKGVERS = $(GCC_VERS)
-GCC_RPMREL = 30%{?dist}
+GCC_RPMREL = 31%{?dist}
NEWLIB_VERS = 1.15.0
include ../gcc.am
GCC_OPTS += --languages=cxx
GDB_VERS = 6.6
GDB_PKGVERS = $(GDB_VERS)
-GDB_RPMREL = 12%{?dist}
+GDB_RPMREL = 13%{?dist}
include ../gdb.am
GDB_OPTS +=
diff --git a/contrib/crossrpms/rtems4.8/arm/gcc-sources.add b/contrib/crossrpms/rtems4.8/arm/gcc-sources.add
index ab22a92a6c..fb41d05b07 100644
--- a/contrib/crossrpms/rtems4.8/arm/gcc-sources.add
+++ b/contrib/crossrpms/rtems4.8/arm/gcc-sources.add
@@ -44,7 +44,7 @@ Source5: ftp://ftp.gnu.org/gnu/gcc/gcc-%{gcc_version}/gcc-objc-%{gcc_pkgvers}.ta
%if %build_newlib
Source50: ftp://sources.redhat.com/pub/newlib/newlib-%{newlib_version}.tar.gz
%if "%{newlib_version}" == "1.15.0"
-Patch50: newlib-1.15.0-rtems4.8-20080508.diff
+Patch50: newlib-1.15.0-rtems4.8-20080903.diff
%endif
%{?_without_sources:NoSource: 50}
%endif
diff --git a/contrib/crossrpms/rtems4.8/arm/rtems-4.8-arm-rtems4.8-binutils.spec b/contrib/crossrpms/rtems4.8/arm/rtems-4.8-arm-rtems4.8-binutils.spec
index 3f88ef1c4c..a43c2f1718 100644
--- a/contrib/crossrpms/rtems4.8/arm/rtems-4.8-arm-rtems4.8-binutils.spec
+++ b/contrib/crossrpms/rtems4.8/arm/rtems-4.8-arm-rtems4.8-binutils.spec
@@ -13,6 +13,18 @@
%define _exeext %{nil}
%endif
+%ifos cygwin cygwin32
+%define optflags -O3 -pipe -march=i486 -funroll-loops
+%define _libdir %{_exec_prefix}/lib
+%define debug_package %{nil}
+%endif
+
+%if "%{_build}" != "%{_host}"
+%define _host_rpmprefix rtems-4.8-%{_host}-
+%else
+%define _host_rpmprefix %{nil}
+%endif
+
%define binutils_pkgvers 2.18
%define binutils_version 2.18
%define binutils_rpmvers %{expand:%(echo "2.18" | tr - _ )}
@@ -21,11 +33,15 @@ Name: rtems-4.8-arm-rtems4.8-binutils
Summary: Binutils for target arm-rtems4.8
Group: Development/Tools
Version: %{binutils_rpmvers}
-Release: 3%{?dist}
+Release: 4%{?dist}
License: GPL/LGPL
URL: http://sources.redhat.com/binutils
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
+%if "%{_build}" != "%{_host}"
+BuildRequires: rtems-4.8-%{_host}-gcc
+%endif
+
%if "%{binutils_version}" >= "2.18"
# Bug in bfd: Doesn't build without texinfo installed
BuildRequires: texinfo >= 4.2
@@ -56,12 +72,16 @@ cd binutils-%{binutils_pkgvers}
cd ..
%build
+ export PATH="%{_bindir}:${PATH}"
%if "arm-rtems4.8" == "i686-pc-cygwin"
# The cygwin sources are leaking memory
RPM_OPT_FLAGS="$(echo "$RPM_OPT_FLAGS"|sed -e 's; -Wp,-D_FORTIFY_SOURCE=2;;')"
%endif
mkdir -p build
cd build
+%if "%{_build}" != "%{_host}"
+ CFLAGS_FOR_BUILD="-g -O2 -Wall" \
+%endif
CFLAGS="$RPM_OPT_FLAGS" \
../binutils-%{binutils_pkgvers}/configure \
--build=%_build --host=%_host \
@@ -80,17 +100,11 @@ cd ..
cd ..
%install
+ export PATH="%{_bindir}:${PATH}"
rm -rf $RPM_BUILD_ROOT
cd build
- make prefix=$RPM_BUILD_ROOT%{_prefix} \
- bindir=$RPM_BUILD_ROOT%{_bindir} \
- includedir=$RPM_BUILD_ROOT%{_includedir} \
- libdir=$RPM_BUILD_ROOT%{_libdir} \
- infodir=$RPM_BUILD_ROOT%{_infodir} \
- mandir=$RPM_BUILD_ROOT%{_mandir} \
- exec_prefix=$RPM_BUILD_ROOT%{_exec_prefix} \
- install
+ make DESTDIR=$RPM_BUILD_ROOT install
make prefix=$RPM_BUILD_ROOT%{_prefix} \
bindir=$RPM_BUILD_ROOT%{_bindir} \
@@ -168,7 +182,6 @@ sed -e 's,^[ ]*/usr/lib/rpm.*/brp-strip,./brp-strip,' \
# %endif
%description -n rtems-4.8-arm-rtems4.8-binutils
-
GNU binutils targetting arm-rtems4.8.
%files -n rtems-4.8-arm-rtems4.8-binutils
diff --git a/contrib/crossrpms/rtems4.8/arm/rtems-4.8-arm-rtems4.8-gcc.spec b/contrib/crossrpms/rtems4.8/arm/rtems-4.8-arm-rtems4.8-gcc.spec
index f4a7d92c5e..c52ec35f07 100644
--- a/contrib/crossrpms/rtems4.8/arm/rtems-4.8-arm-rtems4.8-gcc.spec
+++ b/contrib/crossrpms/rtems4.8/arm/rtems-4.8-arm-rtems4.8-gcc.spec
@@ -13,30 +13,69 @@
%define _exeext %{nil}
%endif
+%ifos cygwin cygwin32
+%define optflags -O3 -pipe -march=i486 -funroll-loops
+%define _libdir %{_exec_prefix}/lib
+%define debug_package %{nil}
+%endif
+
+%if "%{_build}" != "%{_host}"
+%define _host_rpmprefix rtems-4.8-%{_host}-
+%else
+%define _host_rpmprefix %{nil}
+%endif
-%define gcc_pkgvers 4.2.2
-%define gcc_version 4.2.2
-%define gcc_rpmvers %{expand:%(echo "4.2.2" | tr - _ )}
+
+%define gcc_pkgvers 4.2.4
+%define gcc_version 4.2.4
+%define gcc_rpmvers %{expand:%(echo "4.2.4" | tr - _ )}
%define newlib_version 1.15.0
%define gccnewlib_version gcc%{gcc_version}newlib%{newlib_version}
+%define mpfr_version 2.3.1
+
Name: rtems-4.8-arm-rtems4.8-gcc
Summary: arm-rtems4.8 gcc
Group: Development/Tools
Version: %{gcc_rpmvers}
-Release: 28%{?dist}
+Release: 31%{?dist}
License: GPL
URL: http://gcc.gnu.org
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
%define _use_internal_dependency_generator 0
+BuildRequires: %{_host_rpmprefix}gcc
+
+%if "%{gcc_version}" >= "4.3.0"
+BuildRequires: gmp-devel >= 4.1
+%if "%{_build}" != "%{_host}"
+BuildRequires: %{_host_rpmprefix}gmp-devel
+BuildRequires: %{_host_rpmprefix}mpfr-devel
+%endif
+%if "%{?fedora}" >= "8"
+BuildRequires: mpfr-devel >= 2.3.0
+%endif
+%if "%{?suse}" > "10.3"
+BuildRequires: mpfr-devel >= 2.3.0
+%endif
+# These distros ship an insufficient mpfr
+%{?el4:%define _build_mpfr 1}
+%{?suse10_2:%define _build_mpfr 1}
+%{?suse10_3:%define _build_mpfr 1}
+%endif
+
+%if "%{_build}" != "%{_host}"
+BuildRequires: rtems-4.8-arm-rtems4.8-gcc
+%endif
+
%if "%{gcc_version}" >= "4.2.0"
BuildRequires: flex bison
%endif
+
BuildRequires: texinfo >= 4.2
BuildRequires: rtems-4.8-arm-rtems4.8-binutils
@@ -53,10 +92,22 @@ Requires: rtems-4.8-arm-rtems4.8-newlib = %{newlib_version}-%{release}
%define gccexec %{_libdir}/gcc-lib
%endif
+%if "%{gcc_version}" == "4.3.0"
+Source0: ftp://ftp.gnu.org/pub/gnu/gcc/%{gcc_pkgvers}/gcc-core-%{gcc_pkgvers}.tar.bz2
+Patch0: gcc-core-%{gcc_pkgvers}-rtems4.8-20080417.diff
+%endif
%if "%{gcc_version}" == "4.2.2"
Source0: ftp://gcc.gnu.org/pub/gcc/%{gcc_pkgvers}/gcc-core-%{gcc_pkgvers}.tar.bz2
Patch0: gcc-core-4.2.2-rtems4.8-20071127.diff
%endif
+%if "%{gcc_version}" == "4.2.3"
+Source0: ftp://gcc.gnu.org/pub/gcc/%{gcc_pkgvers}/gcc-core-%{gcc_pkgvers}.tar.bz2
+Patch0: gcc-core-4.2.3-rtems4.8-20080508.diff
+%endif
+%if "%{gcc_version}" == "4.2.4"
+Source0: ftp://gcc.gnu.org/pub/gcc/%{gcc_pkgvers}/gcc-core-%{gcc_pkgvers}.tar.bz2
+Patch0: gcc-core-4.2.4-rtems4.8-20080526.diff
+%endif
%{?_without_sources:NoSource: 0}
Source1: ftp://ftp.gnu.org/gnu/gcc/gcc-%{gcc_version}/gcc-g++-%{gcc_pkgvers}.tar.bz2
@@ -64,10 +115,14 @@ Source1: ftp://ftp.gnu.org/gnu/gcc/gcc-%{gcc_version}/gcc-g++-%{gcc_pkgvers}.ta
Source50: ftp://sources.redhat.com/pub/newlib/newlib-%{newlib_version}.tar.gz
%if "%{newlib_version}" == "1.15.0"
-Patch50: newlib-1.15.0-rtems4.8-20071221.diff
+Patch50: newlib-1.15.0-rtems4.8-20080903.diff
%endif
%{?_without_sources:NoSource: 50}
+%if "%{gcc_version}" >= "4.3.0"
+Source60: http://www.mpfr.org/mpfr-current/mpfr-%{mpfr_version}.tar.bz2
+%endif
+
%description
Cross gcc for arm-rtems4.8.
@@ -91,6 +146,13 @@ cd ..
# Copy the C library into gcc's source tree
ln -s ../newlib-%{newlib_version}/newlib gcc-%{gcc_pkgvers}
+%if 0%{?_build_mpfr}
+%setup -q -T -D -n %{name}-%{version} -a60
+%{?PATCH60:%patch60 -p1}
+ # Build mpfr one-tree style
+ ln -s ../mpfr-%{mpfr_version} gcc-%{gcc_pkgvers}/mpfr
+%endif
+
%if "%{gcc_version}" < "4.1.0"
sed -e 's/\(version_string.* = \"[^\"]*\)/\1 (RTEMS gcc-%{gcc_version}\/newlib-%{newlib_version}-%release)/' \
gcc-%{gcc_pkgvers}/gcc/version.c > gcc-%{gcc_pkgvers}/gcc/version.c~
@@ -113,8 +175,12 @@ cd ..
languages="c"
languages="$languages,c++"
export PATH="%{_bindir}:${PATH}"
-
+%if "%{_build}" != "%{_host}"
+ CFLAGS_FOR_BUILD="-g -O2 -Wall" \
+ CC="%{_host}-gcc ${RPM_OPT_FLAGS}" \
+%else
CC="%{__cc} ${RPM_OPT_FLAGS}" \
+%endif
../gcc-%{gcc_pkgvers}/configure \
--prefix=%{_prefix} \
--bindir=%{_bindir} \
@@ -385,7 +451,6 @@ Requires(post): /sbin/install-info
Requires(preun): /sbin/install-info
%description -n rtems-4.8-gcc-common
-
GCC files that are shared by all targets.
%files -n rtems-4.8-gcc-common
@@ -440,6 +505,9 @@ Group: Development/Tools
Version: %{gcc_rpmvers}
License: GPL
+%if "%{_build}" != "%{_host}"
+BuildRequires: rtems-4.8-arm-rtems4.8-gcc-c++
+%endif
Provides: rtems-4.8-arm-rtems4.8-c++ = %{gcc_rpmvers}-%{release}
Obsoletes: rtems-4.8-arm-rtems4.8-c++ < %{gcc_rpmvers}-%{release}
diff --git a/contrib/crossrpms/rtems4.8/arm/rtems-4.8-arm-rtems4.8-gdb.spec b/contrib/crossrpms/rtems4.8/arm/rtems-4.8-arm-rtems4.8-gdb.spec
index 0ee8038694..2c97f9f62f 100644
--- a/contrib/crossrpms/rtems4.8/arm/rtems-4.8-arm-rtems4.8-gdb.spec
+++ b/contrib/crossrpms/rtems4.8/arm/rtems-4.8-arm-rtems4.8-gdb.spec
@@ -32,7 +32,7 @@ Name: rtems-4.8-arm-rtems4.8-gdb
Summary: Gdb for target arm-rtems4.8
Group: Development/Tools
Version: %{gdb_rpmvers}
-Release: 12%{?dist}
+Release: 13%{?dist}
License: GPL/LGPL
URL: http://sources.redhat.com/gdb
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
@@ -104,8 +104,10 @@ rm -f gdb-%{gdb_version}/readline/configure
--disable-win32-registry \
--disable-werror \
--enable-sim \
-%if "%{gdb_version}" >= "6.6"
+%if "%{gdb_version}" >= "6.7"
--with-system-readline \
+%endif
+%if "%{gdb_version}" >= "6.6"
--with-expat \
%endif
--prefix=%{_prefix} --bindir=%{_bindir} \
diff --git a/contrib/crossrpms/rtems4.8/bfin/Makefile.am b/contrib/crossrpms/rtems4.8/bfin/Makefile.am
index c4023a1902..1bd1de62b0 100644
--- a/contrib/crossrpms/rtems4.8/bfin/Makefile.am
+++ b/contrib/crossrpms/rtems4.8/bfin/Makefile.am
@@ -6,18 +6,18 @@ include $(top_srcdir)/mkspec.am
BINUTILS_VERS = 2.18
BINUTILS_PKGVERS = $(BINUTILS_VERS)
-BINUTILS_RPMREL = 3%{?dist}
+BINUTILS_RPMREL = 4%{?dist}
include ../binutils.am
BINUTILS_OPTS +=
GCC_VERS = 4.2.4
GCC_PKGVERS = $(GCC_VERS)
-GCC_RPMREL = 30%{?dist}
+GCC_RPMREL = 31%{?dist}
NEWLIB_VERS = 1.15.0
include ../gcc.am
GDB_VERS = 6.5
GDB_PKGVERS = $(GDB_VERS)
-GDB_RPMREL = 4%{?dist}
+GDB_RPMREL = 5%{?dist}
include ../gdb.am
GDB_OPTS +=
diff --git a/contrib/crossrpms/rtems4.8/bfin/gcc-sources.add b/contrib/crossrpms/rtems4.8/bfin/gcc-sources.add
index ab22a92a6c..fb41d05b07 100644
--- a/contrib/crossrpms/rtems4.8/bfin/gcc-sources.add
+++ b/contrib/crossrpms/rtems4.8/bfin/gcc-sources.add
@@ -44,7 +44,7 @@ Source5: ftp://ftp.gnu.org/gnu/gcc/gcc-%{gcc_version}/gcc-objc-%{gcc_pkgvers}.ta
%if %build_newlib
Source50: ftp://sources.redhat.com/pub/newlib/newlib-%{newlib_version}.tar.gz
%if "%{newlib_version}" == "1.15.0"
-Patch50: newlib-1.15.0-rtems4.8-20080508.diff
+Patch50: newlib-1.15.0-rtems4.8-20080903.diff
%endif
%{?_without_sources:NoSource: 50}
%endif
diff --git a/contrib/crossrpms/rtems4.8/bfin/rtems-4.8-bfin-rtems4.8-binutils.spec b/contrib/crossrpms/rtems4.8/bfin/rtems-4.8-bfin-rtems4.8-binutils.spec
index 712fd90099..91125ee9eb 100644
--- a/contrib/crossrpms/rtems4.8/bfin/rtems-4.8-bfin-rtems4.8-binutils.spec
+++ b/contrib/crossrpms/rtems4.8/bfin/rtems-4.8-bfin-rtems4.8-binutils.spec
@@ -13,6 +13,18 @@
%define _exeext %{nil}
%endif
+%ifos cygwin cygwin32
+%define optflags -O3 -pipe -march=i486 -funroll-loops
+%define _libdir %{_exec_prefix}/lib
+%define debug_package %{nil}
+%endif
+
+%if "%{_build}" != "%{_host}"
+%define _host_rpmprefix rtems-4.8-%{_host}-
+%else
+%define _host_rpmprefix %{nil}
+%endif
+
%define binutils_pkgvers 2.18
%define binutils_version 2.18
%define binutils_rpmvers %{expand:%(echo "2.18" | tr - _ )}
@@ -21,11 +33,15 @@ Name: rtems-4.8-bfin-rtems4.8-binutils
Summary: Binutils for target bfin-rtems4.8
Group: Development/Tools
Version: %{binutils_rpmvers}
-Release: 3%{?dist}
+Release: 4%{?dist}
License: GPL/LGPL
URL: http://sources.redhat.com/binutils
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
+%if "%{_build}" != "%{_host}"
+BuildRequires: rtems-4.8-%{_host}-gcc
+%endif
+
%if "%{binutils_version}" >= "2.18"
# Bug in bfd: Doesn't build without texinfo installed
BuildRequires: texinfo >= 4.2
@@ -56,12 +72,16 @@ cd binutils-%{binutils_pkgvers}
cd ..
%build
+ export PATH="%{_bindir}:${PATH}"
%if "bfin-rtems4.8" == "i686-pc-cygwin"
# The cygwin sources are leaking memory
RPM_OPT_FLAGS="$(echo "$RPM_OPT_FLAGS"|sed -e 's; -Wp,-D_FORTIFY_SOURCE=2;;')"
%endif
mkdir -p build
cd build
+%if "%{_build}" != "%{_host}"
+ CFLAGS_FOR_BUILD="-g -O2 -Wall" \
+%endif
CFLAGS="$RPM_OPT_FLAGS" \
../binutils-%{binutils_pkgvers}/configure \
--build=%_build --host=%_host \
@@ -80,17 +100,11 @@ cd ..
cd ..
%install
+ export PATH="%{_bindir}:${PATH}"
rm -rf $RPM_BUILD_ROOT
cd build
- make prefix=$RPM_BUILD_ROOT%{_prefix} \
- bindir=$RPM_BUILD_ROOT%{_bindir} \
- includedir=$RPM_BUILD_ROOT%{_includedir} \
- libdir=$RPM_BUILD_ROOT%{_libdir} \
- infodir=$RPM_BUILD_ROOT%{_infodir} \
- mandir=$RPM_BUILD_ROOT%{_mandir} \
- exec_prefix=$RPM_BUILD_ROOT%{_exec_prefix} \
- install
+ make DESTDIR=$RPM_BUILD_ROOT install
make prefix=$RPM_BUILD_ROOT%{_prefix} \
bindir=$RPM_BUILD_ROOT%{_bindir} \
@@ -168,7 +182,6 @@ sed -e 's,^[ ]*/usr/lib/rpm.*/brp-strip,./brp-strip,' \
# %endif
%description -n rtems-4.8-bfin-rtems4.8-binutils
-
GNU binutils targetting bfin-rtems4.8.
%files -n rtems-4.8-bfin-rtems4.8-binutils
diff --git a/contrib/crossrpms/rtems4.8/bfin/rtems-4.8-bfin-rtems4.8-gcc.spec b/contrib/crossrpms/rtems4.8/bfin/rtems-4.8-bfin-rtems4.8-gcc.spec
index 426f6b8ab8..32d3907980 100644
--- a/contrib/crossrpms/rtems4.8/bfin/rtems-4.8-bfin-rtems4.8-gcc.spec
+++ b/contrib/crossrpms/rtems4.8/bfin/rtems-4.8-bfin-rtems4.8-gcc.spec
@@ -13,30 +13,69 @@
%define _exeext %{nil}
%endif
+%ifos cygwin cygwin32
+%define optflags -O3 -pipe -march=i486 -funroll-loops
+%define _libdir %{_exec_prefix}/lib
+%define debug_package %{nil}
+%endif
+
+%if "%{_build}" != "%{_host}"
+%define _host_rpmprefix rtems-4.8-%{_host}-
+%else
+%define _host_rpmprefix %{nil}
+%endif
-%define gcc_pkgvers 4.2.2
-%define gcc_version 4.2.2
-%define gcc_rpmvers %{expand:%(echo "4.2.2" | tr - _ )}
+
+%define gcc_pkgvers 4.2.4
+%define gcc_version 4.2.4
+%define gcc_rpmvers %{expand:%(echo "4.2.4" | tr - _ )}
%define newlib_version 1.15.0
%define gccnewlib_version gcc%{gcc_version}newlib%{newlib_version}
+%define mpfr_version 2.3.1
+
Name: rtems-4.8-bfin-rtems4.8-gcc
Summary: bfin-rtems4.8 gcc
Group: Development/Tools
Version: %{gcc_rpmvers}
-Release: 28%{?dist}
+Release: 31%{?dist}
License: GPL
URL: http://gcc.gnu.org
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
%define _use_internal_dependency_generator 0
+BuildRequires: %{_host_rpmprefix}gcc
+
+%if "%{gcc_version}" >= "4.3.0"
+BuildRequires: gmp-devel >= 4.1
+%if "%{_build}" != "%{_host}"
+BuildRequires: %{_host_rpmprefix}gmp-devel
+BuildRequires: %{_host_rpmprefix}mpfr-devel
+%endif
+%if "%{?fedora}" >= "8"
+BuildRequires: mpfr-devel >= 2.3.0
+%endif
+%if "%{?suse}" > "10.3"
+BuildRequires: mpfr-devel >= 2.3.0
+%endif
+# These distros ship an insufficient mpfr
+%{?el4:%define _build_mpfr 1}
+%{?suse10_2:%define _build_mpfr 1}
+%{?suse10_3:%define _build_mpfr 1}
+%endif
+
+%if "%{_build}" != "%{_host}"
+BuildRequires: rtems-4.8-bfin-rtems4.8-gcc
+%endif
+
%if "%{gcc_version}" >= "4.2.0"
BuildRequires: flex bison
%endif
+
BuildRequires: texinfo >= 4.2
BuildRequires: rtems-4.8-bfin-rtems4.8-binutils
@@ -53,18 +92,34 @@ Requires: rtems-4.8-bfin-rtems4.8-newlib = %{newlib_version}-%{release}
%define gccexec %{_libdir}/gcc-lib
%endif
+%if "%{gcc_version}" == "4.3.0"
+Source0: ftp://ftp.gnu.org/pub/gnu/gcc/%{gcc_pkgvers}/gcc-core-%{gcc_pkgvers}.tar.bz2
+Patch0: gcc-core-%{gcc_pkgvers}-rtems4.8-20080417.diff
+%endif
%if "%{gcc_version}" == "4.2.2"
Source0: ftp://gcc.gnu.org/pub/gcc/%{gcc_pkgvers}/gcc-core-%{gcc_pkgvers}.tar.bz2
Patch0: gcc-core-4.2.2-rtems4.8-20071127.diff
%endif
+%if "%{gcc_version}" == "4.2.3"
+Source0: ftp://gcc.gnu.org/pub/gcc/%{gcc_pkgvers}/gcc-core-%{gcc_pkgvers}.tar.bz2
+Patch0: gcc-core-4.2.3-rtems4.8-20080508.diff
+%endif
+%if "%{gcc_version}" == "4.2.4"
+Source0: ftp://gcc.gnu.org/pub/gcc/%{gcc_pkgvers}/gcc-core-%{gcc_pkgvers}.tar.bz2
+Patch0: gcc-core-4.2.4-rtems4.8-20080526.diff
+%endif
%{?_without_sources:NoSource: 0}
Source50: ftp://sources.redhat.com/pub/newlib/newlib-%{newlib_version}.tar.gz
%if "%{newlib_version}" == "1.15.0"
-Patch50: newlib-1.15.0-rtems4.8-20071221.diff
+Patch50: newlib-1.15.0-rtems4.8-20080903.diff
%endif
%{?_without_sources:NoSource: 50}
+%if "%{gcc_version}" >= "4.3.0"
+Source60: http://www.mpfr.org/mpfr-current/mpfr-%{mpfr_version}.tar.bz2
+%endif
+
%description
Cross gcc for bfin-rtems4.8.
@@ -86,6 +141,13 @@ cd ..
# Copy the C library into gcc's source tree
ln -s ../newlib-%{newlib_version}/newlib gcc-%{gcc_pkgvers}
+%if 0%{?_build_mpfr}
+%setup -q -T -D -n %{name}-%{version} -a60
+%{?PATCH60:%patch60 -p1}
+ # Build mpfr one-tree style
+ ln -s ../mpfr-%{mpfr_version} gcc-%{gcc_pkgvers}/mpfr
+%endif
+
%if "%{gcc_version}" < "4.1.0"
sed -e 's/\(version_string.* = \"[^\"]*\)/\1 (RTEMS gcc-%{gcc_version}\/newlib-%{newlib_version}-%release)/' \
gcc-%{gcc_pkgvers}/gcc/version.c > gcc-%{gcc_pkgvers}/gcc/version.c~
@@ -107,8 +169,12 @@ cd ..
languages="c"
export PATH="%{_bindir}:${PATH}"
-
+%if "%{_build}" != "%{_host}"
+ CFLAGS_FOR_BUILD="-g -O2 -Wall" \
+ CC="%{_host}-gcc ${RPM_OPT_FLAGS}" \
+%else
CC="%{__cc} ${RPM_OPT_FLAGS}" \
+%endif
../gcc-%{gcc_pkgvers}/configure \
--prefix=%{_prefix} \
--bindir=%{_bindir} \
@@ -379,7 +445,6 @@ Requires(post): /sbin/install-info
Requires(preun): /sbin/install-info
%description -n rtems-4.8-gcc-common
-
GCC files that are shared by all targets.
%files -n rtems-4.8-gcc-common
diff --git a/contrib/crossrpms/rtems4.8/bfin/rtems-4.8-bfin-rtems4.8-gdb.spec b/contrib/crossrpms/rtems4.8/bfin/rtems-4.8-bfin-rtems4.8-gdb.spec
index f17cec6fed..355ad98e87 100644
--- a/contrib/crossrpms/rtems4.8/bfin/rtems-4.8-bfin-rtems4.8-gdb.spec
+++ b/contrib/crossrpms/rtems4.8/bfin/rtems-4.8-bfin-rtems4.8-gdb.spec
@@ -32,7 +32,7 @@ Name: rtems-4.8-bfin-rtems4.8-gdb
Summary: Gdb for target bfin-rtems4.8
Group: Development/Tools
Version: %{gdb_rpmvers}
-Release: 4%{?dist}
+Release: 5%{?dist}
License: GPL/LGPL
URL: http://sources.redhat.com/gdb
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
@@ -102,8 +102,10 @@ rm -f gdb-%{gdb_version}/readline/configure
--disable-win32-registry \
--disable-werror \
--enable-sim \
-%if "%{gdb_version}" >= "6.6"
+%if "%{gdb_version}" >= "6.7"
--with-system-readline \
+%endif
+%if "%{gdb_version}" >= "6.6"
--with-expat \
%endif
--prefix=%{_prefix} --bindir=%{_bindir} \
diff --git a/contrib/crossrpms/rtems4.8/h8300/Makefile.am b/contrib/crossrpms/rtems4.8/h8300/Makefile.am
index 8c5de4c909..2313e50f96 100644
--- a/contrib/crossrpms/rtems4.8/h8300/Makefile.am
+++ b/contrib/crossrpms/rtems4.8/h8300/Makefile.am
@@ -6,19 +6,19 @@ include $(top_srcdir)/mkspec.am
BINUTILS_VERS = 2.18
BINUTILS_PKGVERS = $(BINUTILS_VERS)
-BINUTILS_RPMREL = 3%{?dist}
+BINUTILS_RPMREL = 4%{?dist}
include ../binutils.am
BINUTILS_OPTS +=
GCC_VERS = 4.2.4
GCC_PKGVERS = $(GCC_VERS)
-GCC_RPMREL = 30%{?dist}
+GCC_RPMREL = 31%{?dist}
NEWLIB_VERS = 1.15.0
include ../gcc.am
GCC_OPTS += --languages=cxx
GDB_VERS = 6.6
GDB_PKGVERS = $(GDB_VERS)
-GDB_RPMREL = 12%{?dist}
+GDB_RPMREL = 13%{?dist}
include ../gdb.am
GDB_OPTS +=
diff --git a/contrib/crossrpms/rtems4.8/h8300/gcc-sources.add b/contrib/crossrpms/rtems4.8/h8300/gcc-sources.add
index ab22a92a6c..fb41d05b07 100644
--- a/contrib/crossrpms/rtems4.8/h8300/gcc-sources.add
+++ b/contrib/crossrpms/rtems4.8/h8300/gcc-sources.add
@@ -44,7 +44,7 @@ Source5: ftp://ftp.gnu.org/gnu/gcc/gcc-%{gcc_version}/gcc-objc-%{gcc_pkgvers}.ta
%if %build_newlib
Source50: ftp://sources.redhat.com/pub/newlib/newlib-%{newlib_version}.tar.gz
%if "%{newlib_version}" == "1.15.0"
-Patch50: newlib-1.15.0-rtems4.8-20080508.diff
+Patch50: newlib-1.15.0-rtems4.8-20080903.diff
%endif
%{?_without_sources:NoSource: 50}
%endif
diff --git a/contrib/crossrpms/rtems4.8/h8300/rtems-4.8-h8300-rtems4.8-binutils.spec b/contrib/crossrpms/rtems4.8/h8300/rtems-4.8-h8300-rtems4.8-binutils.spec
index 5568532fba..668785feca 100644
--- a/contrib/crossrpms/rtems4.8/h8300/rtems-4.8-h8300-rtems4.8-binutils.spec
+++ b/contrib/crossrpms/rtems4.8/h8300/rtems-4.8-h8300-rtems4.8-binutils.spec
@@ -13,6 +13,18 @@
%define _exeext %{nil}
%endif
+%ifos cygwin cygwin32
+%define optflags -O3 -pipe -march=i486 -funroll-loops
+%define _libdir %{_exec_prefix}/lib
+%define debug_package %{nil}
+%endif
+
+%if "%{_build}" != "%{_host}"
+%define _host_rpmprefix rtems-4.8-%{_host}-
+%else
+%define _host_rpmprefix %{nil}
+%endif
+
%define binutils_pkgvers 2.18
%define binutils_version 2.18
%define binutils_rpmvers %{expand:%(echo "2.18" | tr - _ )}
@@ -21,11 +33,15 @@ Name: rtems-4.8-h8300-rtems4.8-binutils
Summary: Binutils for target h8300-rtems4.8
Group: Development/Tools
Version: %{binutils_rpmvers}
-Release: 3%{?dist}
+Release: 4%{?dist}
License: GPL/LGPL
URL: http://sources.redhat.com/binutils
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
+%if "%{_build}" != "%{_host}"
+BuildRequires: rtems-4.8-%{_host}-gcc
+%endif
+
%if "%{binutils_version}" >= "2.18"
# Bug in bfd: Doesn't build without texinfo installed
BuildRequires: texinfo >= 4.2
@@ -56,12 +72,16 @@ cd binutils-%{binutils_pkgvers}
cd ..
%build
+ export PATH="%{_bindir}:${PATH}"
%if "h8300-rtems4.8" == "i686-pc-cygwin"
# The cygwin sources are leaking memory
RPM_OPT_FLAGS="$(echo "$RPM_OPT_FLAGS"|sed -e 's; -Wp,-D_FORTIFY_SOURCE=2;;')"
%endif
mkdir -p build
cd build
+%if "%{_build}" != "%{_host}"
+ CFLAGS_FOR_BUILD="-g -O2 -Wall" \
+%endif
CFLAGS="$RPM_OPT_FLAGS" \
../binutils-%{binutils_pkgvers}/configure \
--build=%_build --host=%_host \
@@ -80,17 +100,11 @@ cd ..
cd ..
%install
+ export PATH="%{_bindir}:${PATH}"
rm -rf $RPM_BUILD_ROOT
cd build
- make prefix=$RPM_BUILD_ROOT%{_prefix} \
- bindir=$RPM_BUILD_ROOT%{_bindir} \
- includedir=$RPM_BUILD_ROOT%{_includedir} \
- libdir=$RPM_BUILD_ROOT%{_libdir} \
- infodir=$RPM_BUILD_ROOT%{_infodir} \
- mandir=$RPM_BUILD_ROOT%{_mandir} \
- exec_prefix=$RPM_BUILD_ROOT%{_exec_prefix} \
- install
+ make DESTDIR=$RPM_BUILD_ROOT install
make prefix=$RPM_BUILD_ROOT%{_prefix} \
bindir=$RPM_BUILD_ROOT%{_bindir} \
@@ -168,7 +182,6 @@ sed -e 's,^[ ]*/usr/lib/rpm.*/brp-strip,./brp-strip,' \
# %endif
%description -n rtems-4.8-h8300-rtems4.8-binutils
-
GNU binutils targetting h8300-rtems4.8.
%files -n rtems-4.8-h8300-rtems4.8-binutils
diff --git a/contrib/crossrpms/rtems4.8/h8300/rtems-4.8-h8300-rtems4.8-gcc.spec b/contrib/crossrpms/rtems4.8/h8300/rtems-4.8-h8300-rtems4.8-gcc.spec
index fbeef83d3e..bce11a50d9 100644
--- a/contrib/crossrpms/rtems4.8/h8300/rtems-4.8-h8300-rtems4.8-gcc.spec
+++ b/contrib/crossrpms/rtems4.8/h8300/rtems-4.8-h8300-rtems4.8-gcc.spec
@@ -13,30 +13,69 @@
%define _exeext %{nil}
%endif
+%ifos cygwin cygwin32
+%define optflags -O3 -pipe -march=i486 -funroll-loops
+%define _libdir %{_exec_prefix}/lib
+%define debug_package %{nil}
+%endif
+
+%if "%{_build}" != "%{_host}"
+%define _host_rpmprefix rtems-4.8-%{_host}-
+%else
+%define _host_rpmprefix %{nil}
+%endif
-%define gcc_pkgvers 4.2.2
-%define gcc_version 4.2.2
-%define gcc_rpmvers %{expand:%(echo "4.2.2" | tr - _ )}
+
+%define gcc_pkgvers 4.2.4
+%define gcc_version 4.2.4
+%define gcc_rpmvers %{expand:%(echo "4.2.4" | tr - _ )}
%define newlib_version 1.15.0
%define gccnewlib_version gcc%{gcc_version}newlib%{newlib_version}
+%define mpfr_version 2.3.1
+
Name: rtems-4.8-h8300-rtems4.8-gcc
Summary: h8300-rtems4.8 gcc
Group: Development/Tools
Version: %{gcc_rpmvers}
-Release: 28%{?dist}
+Release: 31%{?dist}
License: GPL
URL: http://gcc.gnu.org
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
%define _use_internal_dependency_generator 0
+BuildRequires: %{_host_rpmprefix}gcc
+
+%if "%{gcc_version}" >= "4.3.0"
+BuildRequires: gmp-devel >= 4.1
+%if "%{_build}" != "%{_host}"
+BuildRequires: %{_host_rpmprefix}gmp-devel
+BuildRequires: %{_host_rpmprefix}mpfr-devel
+%endif
+%if "%{?fedora}" >= "8"
+BuildRequires: mpfr-devel >= 2.3.0
+%endif
+%if "%{?suse}" > "10.3"
+BuildRequires: mpfr-devel >= 2.3.0
+%endif
+# These distros ship an insufficient mpfr
+%{?el4:%define _build_mpfr 1}
+%{?suse10_2:%define _build_mpfr 1}
+%{?suse10_3:%define _build_mpfr 1}
+%endif
+
+%if "%{_build}" != "%{_host}"
+BuildRequires: rtems-4.8-h8300-rtems4.8-gcc
+%endif
+
%if "%{gcc_version}" >= "4.2.0"
BuildRequires: flex bison
%endif
+
BuildRequires: texinfo >= 4.2
BuildRequires: rtems-4.8-h8300-rtems4.8-binutils
@@ -53,10 +92,22 @@ Requires: rtems-4.8-h8300-rtems4.8-newlib = %{newlib_version}-%{release}
%define gccexec %{_libdir}/gcc-lib
%endif
+%if "%{gcc_version}" == "4.3.0"
+Source0: ftp://ftp.gnu.org/pub/gnu/gcc/%{gcc_pkgvers}/gcc-core-%{gcc_pkgvers}.tar.bz2
+Patch0: gcc-core-%{gcc_pkgvers}-rtems4.8-20080417.diff
+%endif
%if "%{gcc_version}" == "4.2.2"
Source0: ftp://gcc.gnu.org/pub/gcc/%{gcc_pkgvers}/gcc-core-%{gcc_pkgvers}.tar.bz2
Patch0: gcc-core-4.2.2-rtems4.8-20071127.diff
%endif
+%if "%{gcc_version}" == "4.2.3"
+Source0: ftp://gcc.gnu.org/pub/gcc/%{gcc_pkgvers}/gcc-core-%{gcc_pkgvers}.tar.bz2
+Patch0: gcc-core-4.2.3-rtems4.8-20080508.diff
+%endif
+%if "%{gcc_version}" == "4.2.4"
+Source0: ftp://gcc.gnu.org/pub/gcc/%{gcc_pkgvers}/gcc-core-%{gcc_pkgvers}.tar.bz2
+Patch0: gcc-core-4.2.4-rtems4.8-20080526.diff
+%endif
%{?_without_sources:NoSource: 0}
Source1: ftp://ftp.gnu.org/gnu/gcc/gcc-%{gcc_version}/gcc-g++-%{gcc_pkgvers}.tar.bz2
@@ -64,10 +115,14 @@ Source1: ftp://ftp.gnu.org/gnu/gcc/gcc-%{gcc_version}/gcc-g++-%{gcc_pkgvers}.ta
Source50: ftp://sources.redhat.com/pub/newlib/newlib-%{newlib_version}.tar.gz
%if "%{newlib_version}" == "1.15.0"
-Patch50: newlib-1.15.0-rtems4.8-20071221.diff
+Patch50: newlib-1.15.0-rtems4.8-20080903.diff
%endif
%{?_without_sources:NoSource: 50}
+%if "%{gcc_version}" >= "4.3.0"
+Source60: http://www.mpfr.org/mpfr-current/mpfr-%{mpfr_version}.tar.bz2
+%endif
+
%description
Cross gcc for h8300-rtems4.8.
@@ -91,6 +146,13 @@ cd ..
# Copy the C library into gcc's source tree
ln -s ../newlib-%{newlib_version}/newlib gcc-%{gcc_pkgvers}
+%if 0%{?_build_mpfr}
+%setup -q -T -D -n %{name}-%{version} -a60
+%{?PATCH60:%patch60 -p1}
+ # Build mpfr one-tree style
+ ln -s ../mpfr-%{mpfr_version} gcc-%{gcc_pkgvers}/mpfr
+%endif
+
%if "%{gcc_version}" < "4.1.0"
sed -e 's/\(version_string.* = \"[^\"]*\)/\1 (RTEMS gcc-%{gcc_version}\/newlib-%{newlib_version}-%release)/' \
gcc-%{gcc_pkgvers}/gcc/version.c > gcc-%{gcc_pkgvers}/gcc/version.c~
@@ -113,8 +175,12 @@ cd ..
languages="c"
languages="$languages,c++"
export PATH="%{_bindir}:${PATH}"
-
+%if "%{_build}" != "%{_host}"
+ CFLAGS_FOR_BUILD="-g -O2 -Wall" \
+ CC="%{_host}-gcc ${RPM_OPT_FLAGS}" \
+%else
CC="%{__cc} ${RPM_OPT_FLAGS}" \
+%endif
../gcc-%{gcc_pkgvers}/configure \
--prefix=%{_prefix} \
--bindir=%{_bindir} \
@@ -385,7 +451,6 @@ Requires(post): /sbin/install-info
Requires(preun): /sbin/install-info
%description -n rtems-4.8-gcc-common
-
GCC files that are shared by all targets.
%files -n rtems-4.8-gcc-common
@@ -440,6 +505,9 @@ Group: Development/Tools
Version: %{gcc_rpmvers}
License: GPL
+%if "%{_build}" != "%{_host}"
+BuildRequires: rtems-4.8-h8300-rtems4.8-gcc-c++
+%endif
Provides: rtems-4.8-h8300-rtems4.8-c++ = %{gcc_rpmvers}-%{release}
Obsoletes: rtems-4.8-h8300-rtems4.8-c++ < %{gcc_rpmvers}-%{release}
diff --git a/contrib/crossrpms/rtems4.8/h8300/rtems-4.8-h8300-rtems4.8-gdb.spec b/contrib/crossrpms/rtems4.8/h8300/rtems-4.8-h8300-rtems4.8-gdb.spec
index 6b5da515d8..fec7d4d93b 100644
--- a/contrib/crossrpms/rtems4.8/h8300/rtems-4.8-h8300-rtems4.8-gdb.spec
+++ b/contrib/crossrpms/rtems4.8/h8300/rtems-4.8-h8300-rtems4.8-gdb.spec
@@ -32,7 +32,7 @@ Name: rtems-4.8-h8300-rtems4.8-gdb
Summary: Gdb for target h8300-rtems4.8
Group: Development/Tools
Version: %{gdb_rpmvers}
-Release: 12%{?dist}
+Release: 13%{?dist}
License: GPL/LGPL
URL: http://sources.redhat.com/gdb
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
@@ -104,8 +104,10 @@ rm -f gdb-%{gdb_version}/readline/configure
--disable-win32-registry \
--disable-werror \
--enable-sim \
-%if "%{gdb_version}" >= "6.6"
+%if "%{gdb_version}" >= "6.7"
--with-system-readline \
+%endif
+%if "%{gdb_version}" >= "6.6"
--with-expat \
%endif
--prefix=%{_prefix} --bindir=%{_bindir} \
diff --git a/contrib/crossrpms/rtems4.8/i386/Makefile.am b/contrib/crossrpms/rtems4.8/i386/Makefile.am
index 035f93aca9..f9bd82f597 100644
--- a/contrib/crossrpms/rtems4.8/i386/Makefile.am
+++ b/contrib/crossrpms/rtems4.8/i386/Makefile.am
@@ -6,19 +6,19 @@ include $(top_srcdir)/mkspec.am
BINUTILS_VERS = 2.18
BINUTILS_PKGVERS = $(BINUTILS_VERS)
-BINUTILS_RPMREL = 3%{?dist}
+BINUTILS_RPMREL = 4%{?dist}
include ../binutils.am
BINUTILS_OPTS +=
GCC_VERS = 4.2.4
GCC_PKGVERS = $(GCC_VERS)
-GCC_RPMREL = 30%{?dist}
+GCC_RPMREL = 31%{?dist}
NEWLIB_VERS = 1.15.0
include ../gcc.am
GCC_OPTS += --languages=cxx
GDB_VERS = 6.6
GDB_PKGVERS = $(GDB_VERS)
-GDB_RPMREL = 12%{?dist}
+GDB_RPMREL = 13%{?dist}
include ../gdb.am
GDB_OPTS +=
diff --git a/contrib/crossrpms/rtems4.8/i386/gcc-sources.add b/contrib/crossrpms/rtems4.8/i386/gcc-sources.add
index ab22a92a6c..fb41d05b07 100644
--- a/contrib/crossrpms/rtems4.8/i386/gcc-sources.add
+++ b/contrib/crossrpms/rtems4.8/i386/gcc-sources.add
@@ -44,7 +44,7 @@ Source5: ftp://ftp.gnu.org/gnu/gcc/gcc-%{gcc_version}/gcc-objc-%{gcc_pkgvers}.ta
%if %build_newlib
Source50: ftp://sources.redhat.com/pub/newlib/newlib-%{newlib_version}.tar.gz
%if "%{newlib_version}" == "1.15.0"
-Patch50: newlib-1.15.0-rtems4.8-20080508.diff
+Patch50: newlib-1.15.0-rtems4.8-20080903.diff
%endif
%{?_without_sources:NoSource: 50}
%endif
diff --git a/contrib/crossrpms/rtems4.8/i386/rtems-4.8-i386-rtems4.8-binutils.spec b/contrib/crossrpms/rtems4.8/i386/rtems-4.8-i386-rtems4.8-binutils.spec
index d5d66df8c1..617cef0336 100644
--- a/contrib/crossrpms/rtems4.8/i386/rtems-4.8-i386-rtems4.8-binutils.spec
+++ b/contrib/crossrpms/rtems4.8/i386/rtems-4.8-i386-rtems4.8-binutils.spec
@@ -13,6 +13,18 @@
%define _exeext %{nil}
%endif
+%ifos cygwin cygwin32
+%define optflags -O3 -pipe -march=i486 -funroll-loops
+%define _libdir %{_exec_prefix}/lib
+%define debug_package %{nil}
+%endif
+
+%if "%{_build}" != "%{_host}"
+%define _host_rpmprefix rtems-4.8-%{_host}-
+%else
+%define _host_rpmprefix %{nil}
+%endif
+
%define binutils_pkgvers 2.18
%define binutils_version 2.18
%define binutils_rpmvers %{expand:%(echo "2.18" | tr - _ )}
@@ -21,11 +33,15 @@ Name: rtems-4.8-i386-rtems4.8-binutils
Summary: Binutils for target i386-rtems4.8
Group: Development/Tools
Version: %{binutils_rpmvers}
-Release: 3%{?dist}
+Release: 4%{?dist}
License: GPL/LGPL
URL: http://sources.redhat.com/binutils
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
+%if "%{_build}" != "%{_host}"
+BuildRequires: rtems-4.8-%{_host}-gcc
+%endif
+
%if "%{binutils_version}" >= "2.18"
# Bug in bfd: Doesn't build without texinfo installed
BuildRequires: texinfo >= 4.2
@@ -56,12 +72,16 @@ cd binutils-%{binutils_pkgvers}
cd ..
%build
+ export PATH="%{_bindir}:${PATH}"
%if "i386-rtems4.8" == "i686-pc-cygwin"
# The cygwin sources are leaking memory
RPM_OPT_FLAGS="$(echo "$RPM_OPT_FLAGS"|sed -e 's; -Wp,-D_FORTIFY_SOURCE=2;;')"
%endif
mkdir -p build
cd build
+%if "%{_build}" != "%{_host}"
+ CFLAGS_FOR_BUILD="-g -O2 -Wall" \
+%endif
CFLAGS="$RPM_OPT_FLAGS" \
../binutils-%{binutils_pkgvers}/configure \
--build=%_build --host=%_host \
@@ -80,17 +100,11 @@ cd ..
cd ..
%install
+ export PATH="%{_bindir}:${PATH}"
rm -rf $RPM_BUILD_ROOT
cd build
- make prefix=$RPM_BUILD_ROOT%{_prefix} \
- bindir=$RPM_BUILD_ROOT%{_bindir} \
- includedir=$RPM_BUILD_ROOT%{_includedir} \
- libdir=$RPM_BUILD_ROOT%{_libdir} \
- infodir=$RPM_BUILD_ROOT%{_infodir} \
- mandir=$RPM_BUILD_ROOT%{_mandir} \
- exec_prefix=$RPM_BUILD_ROOT%{_exec_prefix} \
- install
+ make DESTDIR=$RPM_BUILD_ROOT install
make prefix=$RPM_BUILD_ROOT%{_prefix} \
bindir=$RPM_BUILD_ROOT%{_bindir} \
@@ -168,7 +182,6 @@ sed -e 's,^[ ]*/usr/lib/rpm.*/brp-strip,./brp-strip,' \
# %endif
%description -n rtems-4.8-i386-rtems4.8-binutils
-
GNU binutils targetting i386-rtems4.8.
%files -n rtems-4.8-i386-rtems4.8-binutils
diff --git a/contrib/crossrpms/rtems4.8/i386/rtems-4.8-i386-rtems4.8-gcc.spec b/contrib/crossrpms/rtems4.8/i386/rtems-4.8-i386-rtems4.8-gcc.spec
index 4451b1aeb3..5428f06c6d 100644
--- a/contrib/crossrpms/rtems4.8/i386/rtems-4.8-i386-rtems4.8-gcc.spec
+++ b/contrib/crossrpms/rtems4.8/i386/rtems-4.8-i386-rtems4.8-gcc.spec
@@ -13,30 +13,69 @@
%define _exeext %{nil}
%endif
+%ifos cygwin cygwin32
+%define optflags -O3 -pipe -march=i486 -funroll-loops
+%define _libdir %{_exec_prefix}/lib
+%define debug_package %{nil}
+%endif
+
+%if "%{_build}" != "%{_host}"
+%define _host_rpmprefix rtems-4.8-%{_host}-
+%else
+%define _host_rpmprefix %{nil}
+%endif
-%define gcc_pkgvers 4.2.2
-%define gcc_version 4.2.2
-%define gcc_rpmvers %{expand:%(echo "4.2.2" | tr - _ )}
+
+%define gcc_pkgvers 4.2.4
+%define gcc_version 4.2.4
+%define gcc_rpmvers %{expand:%(echo "4.2.4" | tr - _ )}
%define newlib_version 1.15.0
%define gccnewlib_version gcc%{gcc_version}newlib%{newlib_version}
+%define mpfr_version 2.3.1
+
Name: rtems-4.8-i386-rtems4.8-gcc
Summary: i386-rtems4.8 gcc
Group: Development/Tools
Version: %{gcc_rpmvers}
-Release: 28%{?dist}
+Release: 31%{?dist}
License: GPL
URL: http://gcc.gnu.org
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
%define _use_internal_dependency_generator 0
+BuildRequires: %{_host_rpmprefix}gcc
+
+%if "%{gcc_version}" >= "4.3.0"
+BuildRequires: gmp-devel >= 4.1
+%if "%{_build}" != "%{_host}"
+BuildRequires: %{_host_rpmprefix}gmp-devel
+BuildRequires: %{_host_rpmprefix}mpfr-devel
+%endif
+%if "%{?fedora}" >= "8"
+BuildRequires: mpfr-devel >= 2.3.0
+%endif
+%if "%{?suse}" > "10.3"
+BuildRequires: mpfr-devel >= 2.3.0
+%endif
+# These distros ship an insufficient mpfr
+%{?el4:%define _build_mpfr 1}
+%{?suse10_2:%define _build_mpfr 1}
+%{?suse10_3:%define _build_mpfr 1}
+%endif
+
+%if "%{_build}" != "%{_host}"
+BuildRequires: rtems-4.8-i386-rtems4.8-gcc
+%endif
+
%if "%{gcc_version}" >= "4.2.0"
BuildRequires: flex bison
%endif
+
BuildRequires: texinfo >= 4.2
BuildRequires: rtems-4.8-i386-rtems4.8-binutils
@@ -53,10 +92,22 @@ Requires: rtems-4.8-i386-rtems4.8-newlib = %{newlib_version}-%{release}
%define gccexec %{_libdir}/gcc-lib
%endif
+%if "%{gcc_version}" == "4.3.0"
+Source0: ftp://ftp.gnu.org/pub/gnu/gcc/%{gcc_pkgvers}/gcc-core-%{gcc_pkgvers}.tar.bz2
+Patch0: gcc-core-%{gcc_pkgvers}-rtems4.8-20080417.diff
+%endif
%if "%{gcc_version}" == "4.2.2"
Source0: ftp://gcc.gnu.org/pub/gcc/%{gcc_pkgvers}/gcc-core-%{gcc_pkgvers}.tar.bz2
Patch0: gcc-core-4.2.2-rtems4.8-20071127.diff
%endif
+%if "%{gcc_version}" == "4.2.3"
+Source0: ftp://gcc.gnu.org/pub/gcc/%{gcc_pkgvers}/gcc-core-%{gcc_pkgvers}.tar.bz2
+Patch0: gcc-core-4.2.3-rtems4.8-20080508.diff
+%endif
+%if "%{gcc_version}" == "4.2.4"
+Source0: ftp://gcc.gnu.org/pub/gcc/%{gcc_pkgvers}/gcc-core-%{gcc_pkgvers}.tar.bz2
+Patch0: gcc-core-4.2.4-rtems4.8-20080526.diff
+%endif
%{?_without_sources:NoSource: 0}
Source1: ftp://ftp.gnu.org/gnu/gcc/gcc-%{gcc_version}/gcc-g++-%{gcc_pkgvers}.tar.bz2
@@ -64,10 +115,14 @@ Source1: ftp://ftp.gnu.org/gnu/gcc/gcc-%{gcc_version}/gcc-g++-%{gcc_pkgvers}.ta
Source50: ftp://sources.redhat.com/pub/newlib/newlib-%{newlib_version}.tar.gz
%if "%{newlib_version}" == "1.15.0"
-Patch50: newlib-1.15.0-rtems4.8-20071221.diff
+Patch50: newlib-1.15.0-rtems4.8-20080903.diff
%endif
%{?_without_sources:NoSource: 50}
+%if "%{gcc_version}" >= "4.3.0"
+Source60: http://www.mpfr.org/mpfr-current/mpfr-%{mpfr_version}.tar.bz2
+%endif
+
%description
Cross gcc for i386-rtems4.8.
@@ -91,6 +146,13 @@ cd ..
# Copy the C library into gcc's source tree
ln -s ../newlib-%{newlib_version}/newlib gcc-%{gcc_pkgvers}
+%if 0%{?_build_mpfr}
+%setup -q -T -D -n %{name}-%{version} -a60
+%{?PATCH60:%patch60 -p1}
+ # Build mpfr one-tree style
+ ln -s ../mpfr-%{mpfr_version} gcc-%{gcc_pkgvers}/mpfr
+%endif
+
%if "%{gcc_version}" < "4.1.0"
sed -e 's/\(version_string.* = \"[^\"]*\)/\1 (RTEMS gcc-%{gcc_version}\/newlib-%{newlib_version}-%release)/' \
gcc-%{gcc_pkgvers}/gcc/version.c > gcc-%{gcc_pkgvers}/gcc/version.c~
@@ -113,8 +175,12 @@ cd ..
languages="c"
languages="$languages,c++"
export PATH="%{_bindir}:${PATH}"
-
+%if "%{_build}" != "%{_host}"
+ CFLAGS_FOR_BUILD="-g -O2 -Wall" \
+ CC="%{_host}-gcc ${RPM_OPT_FLAGS}" \
+%else
CC="%{__cc} ${RPM_OPT_FLAGS}" \
+%endif
../gcc-%{gcc_pkgvers}/configure \
--prefix=%{_prefix} \
--bindir=%{_bindir} \
@@ -385,7 +451,6 @@ Requires(post): /sbin/install-info
Requires(preun): /sbin/install-info
%description -n rtems-4.8-gcc-common
-
GCC files that are shared by all targets.
%files -n rtems-4.8-gcc-common
@@ -440,6 +505,9 @@ Group: Development/Tools
Version: %{gcc_rpmvers}
License: GPL
+%if "%{_build}" != "%{_host}"
+BuildRequires: rtems-4.8-i386-rtems4.8-gcc-c++
+%endif
Provides: rtems-4.8-i386-rtems4.8-c++ = %{gcc_rpmvers}-%{release}
Obsoletes: rtems-4.8-i386-rtems4.8-c++ < %{gcc_rpmvers}-%{release}
diff --git a/contrib/crossrpms/rtems4.8/i386/rtems-4.8-i386-rtems4.8-gdb.spec b/contrib/crossrpms/rtems4.8/i386/rtems-4.8-i386-rtems4.8-gdb.spec
index 7dfe8c1212..d8b097ae5a 100644
--- a/contrib/crossrpms/rtems4.8/i386/rtems-4.8-i386-rtems4.8-gdb.spec
+++ b/contrib/crossrpms/rtems4.8/i386/rtems-4.8-i386-rtems4.8-gdb.spec
@@ -32,7 +32,7 @@ Name: rtems-4.8-i386-rtems4.8-gdb
Summary: Gdb for target i386-rtems4.8
Group: Development/Tools
Version: %{gdb_rpmvers}
-Release: 12%{?dist}
+Release: 13%{?dist}
License: GPL/LGPL
URL: http://sources.redhat.com/gdb
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
@@ -104,8 +104,10 @@ rm -f gdb-%{gdb_version}/readline/configure
--disable-win32-registry \
--disable-werror \
--enable-sim \
-%if "%{gdb_version}" >= "6.6"
+%if "%{gdb_version}" >= "6.7"
--with-system-readline \
+%endif
+%if "%{gdb_version}" >= "6.6"
--with-expat \
%endif
--prefix=%{_prefix} --bindir=%{_bindir} \
diff --git a/contrib/crossrpms/rtems4.8/m68k/Makefile.am b/contrib/crossrpms/rtems4.8/m68k/Makefile.am
index 840c45ac2e..081860c171 100644
--- a/contrib/crossrpms/rtems4.8/m68k/Makefile.am
+++ b/contrib/crossrpms/rtems4.8/m68k/Makefile.am
@@ -6,19 +6,19 @@ include $(top_srcdir)/mkspec.am
BINUTILS_VERS = 2.18
BINUTILS_PKGVERS = $(BINUTILS_VERS)
-BINUTILS_RPMREL = 3%{?dist}
+BINUTILS_RPMREL = 4%{?dist}
include ../binutils.am
BINUTILS_OPTS +=
GCC_VERS = 4.2.4
GCC_PKGVERS = $(GCC_VERS)
-GCC_RPMREL = 30%{?dist}
+GCC_RPMREL = 31%{?dist}
NEWLIB_VERS = 1.15.0
include ../gcc.am
GCC_OPTS += --languages=cxx
GDB_VERS = 6.6
GDB_PKGVERS = $(GDB_VERS)
-GDB_RPMREL = 12%{?dist}
+GDB_RPMREL = 13%{?dist}
include ../gdb.am
GDB_OPTS +=
diff --git a/contrib/crossrpms/rtems4.8/m68k/gcc-sources.add b/contrib/crossrpms/rtems4.8/m68k/gcc-sources.add
index ab22a92a6c..fb41d05b07 100644
--- a/contrib/crossrpms/rtems4.8/m68k/gcc-sources.add
+++ b/contrib/crossrpms/rtems4.8/m68k/gcc-sources.add
@@ -44,7 +44,7 @@ Source5: ftp://ftp.gnu.org/gnu/gcc/gcc-%{gcc_version}/gcc-objc-%{gcc_pkgvers}.ta
%if %build_newlib
Source50: ftp://sources.redhat.com/pub/newlib/newlib-%{newlib_version}.tar.gz
%if "%{newlib_version}" == "1.15.0"
-Patch50: newlib-1.15.0-rtems4.8-20080508.diff
+Patch50: newlib-1.15.0-rtems4.8-20080903.diff
%endif
%{?_without_sources:NoSource: 50}
%endif
diff --git a/contrib/crossrpms/rtems4.8/m68k/rtems-4.8-m68k-rtems4.8-binutils.spec b/contrib/crossrpms/rtems4.8/m68k/rtems-4.8-m68k-rtems4.8-binutils.spec
index ef968f08da..88d4c021f8 100644
--- a/contrib/crossrpms/rtems4.8/m68k/rtems-4.8-m68k-rtems4.8-binutils.spec
+++ b/contrib/crossrpms/rtems4.8/m68k/rtems-4.8-m68k-rtems4.8-binutils.spec
@@ -13,6 +13,18 @@
%define _exeext %{nil}
%endif
+%ifos cygwin cygwin32
+%define optflags -O3 -pipe -march=i486 -funroll-loops
+%define _libdir %{_exec_prefix}/lib
+%define debug_package %{nil}
+%endif
+
+%if "%{_build}" != "%{_host}"
+%define _host_rpmprefix rtems-4.8-%{_host}-
+%else
+%define _host_rpmprefix %{nil}
+%endif
+
%define binutils_pkgvers 2.18
%define binutils_version 2.18
%define binutils_rpmvers %{expand:%(echo "2.18" | tr - _ )}
@@ -21,11 +33,15 @@ Name: rtems-4.8-m68k-rtems4.8-binutils
Summary: Binutils for target m68k-rtems4.8
Group: Development/Tools
Version: %{binutils_rpmvers}
-Release: 3%{?dist}
+Release: 4%{?dist}
License: GPL/LGPL
URL: http://sources.redhat.com/binutils
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
+%if "%{_build}" != "%{_host}"
+BuildRequires: rtems-4.8-%{_host}-gcc
+%endif
+
%if "%{binutils_version}" >= "2.18"
# Bug in bfd: Doesn't build without texinfo installed
BuildRequires: texinfo >= 4.2
@@ -56,12 +72,16 @@ cd binutils-%{binutils_pkgvers}
cd ..
%build
+ export PATH="%{_bindir}:${PATH}"
%if "m68k-rtems4.8" == "i686-pc-cygwin"
# The cygwin sources are leaking memory
RPM_OPT_FLAGS="$(echo "$RPM_OPT_FLAGS"|sed -e 's; -Wp,-D_FORTIFY_SOURCE=2;;')"
%endif
mkdir -p build
cd build
+%if "%{_build}" != "%{_host}"
+ CFLAGS_FOR_BUILD="-g -O2 -Wall" \
+%endif
CFLAGS="$RPM_OPT_FLAGS" \
../binutils-%{binutils_pkgvers}/configure \
--build=%_build --host=%_host \
@@ -80,17 +100,11 @@ cd ..
cd ..
%install
+ export PATH="%{_bindir}:${PATH}"
rm -rf $RPM_BUILD_ROOT
cd build
- make prefix=$RPM_BUILD_ROOT%{_prefix} \
- bindir=$RPM_BUILD_ROOT%{_bindir} \
- includedir=$RPM_BUILD_ROOT%{_includedir} \
- libdir=$RPM_BUILD_ROOT%{_libdir} \
- infodir=$RPM_BUILD_ROOT%{_infodir} \
- mandir=$RPM_BUILD_ROOT%{_mandir} \
- exec_prefix=$RPM_BUILD_ROOT%{_exec_prefix} \
- install
+ make DESTDIR=$RPM_BUILD_ROOT install
make prefix=$RPM_BUILD_ROOT%{_prefix} \
bindir=$RPM_BUILD_ROOT%{_bindir} \
@@ -168,7 +182,6 @@ sed -e 's,^[ ]*/usr/lib/rpm.*/brp-strip,./brp-strip,' \
# %endif
%description -n rtems-4.8-m68k-rtems4.8-binutils
-
GNU binutils targetting m68k-rtems4.8.
%files -n rtems-4.8-m68k-rtems4.8-binutils
diff --git a/contrib/crossrpms/rtems4.8/m68k/rtems-4.8-m68k-rtems4.8-gcc.spec b/contrib/crossrpms/rtems4.8/m68k/rtems-4.8-m68k-rtems4.8-gcc.spec
index 86a870d5ad..d5d8bb21ef 100644
--- a/contrib/crossrpms/rtems4.8/m68k/rtems-4.8-m68k-rtems4.8-gcc.spec
+++ b/contrib/crossrpms/rtems4.8/m68k/rtems-4.8-m68k-rtems4.8-gcc.spec
@@ -13,30 +13,69 @@
%define _exeext %{nil}
%endif
+%ifos cygwin cygwin32
+%define optflags -O3 -pipe -march=i486 -funroll-loops
+%define _libdir %{_exec_prefix}/lib
+%define debug_package %{nil}
+%endif
+
+%if "%{_build}" != "%{_host}"
+%define _host_rpmprefix rtems-4.8-%{_host}-
+%else
+%define _host_rpmprefix %{nil}
+%endif
-%define gcc_pkgvers 4.2.2
-%define gcc_version 4.2.2
-%define gcc_rpmvers %{expand:%(echo "4.2.2" | tr - _ )}
+
+%define gcc_pkgvers 4.2.4
+%define gcc_version 4.2.4
+%define gcc_rpmvers %{expand:%(echo "4.2.4" | tr - _ )}
%define newlib_version 1.15.0
%define gccnewlib_version gcc%{gcc_version}newlib%{newlib_version}
+%define mpfr_version 2.3.1
+
Name: rtems-4.8-m68k-rtems4.8-gcc
Summary: m68k-rtems4.8 gcc
Group: Development/Tools
Version: %{gcc_rpmvers}
-Release: 28%{?dist}
+Release: 31%{?dist}
License: GPL
URL: http://gcc.gnu.org
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
%define _use_internal_dependency_generator 0
+BuildRequires: %{_host_rpmprefix}gcc
+
+%if "%{gcc_version}" >= "4.3.0"
+BuildRequires: gmp-devel >= 4.1
+%if "%{_build}" != "%{_host}"
+BuildRequires: %{_host_rpmprefix}gmp-devel
+BuildRequires: %{_host_rpmprefix}mpfr-devel
+%endif
+%if "%{?fedora}" >= "8"
+BuildRequires: mpfr-devel >= 2.3.0
+%endif
+%if "%{?suse}" > "10.3"
+BuildRequires: mpfr-devel >= 2.3.0
+%endif
+# These distros ship an insufficient mpfr
+%{?el4:%define _build_mpfr 1}
+%{?suse10_2:%define _build_mpfr 1}
+%{?suse10_3:%define _build_mpfr 1}
+%endif
+
+%if "%{_build}" != "%{_host}"
+BuildRequires: rtems-4.8-m68k-rtems4.8-gcc
+%endif
+
%if "%{gcc_version}" >= "4.2.0"
BuildRequires: flex bison
%endif
+
BuildRequires: texinfo >= 4.2
BuildRequires: rtems-4.8-m68k-rtems4.8-binutils
@@ -53,10 +92,22 @@ Requires: rtems-4.8-m68k-rtems4.8-newlib = %{newlib_version}-%{release}
%define gccexec %{_libdir}/gcc-lib
%endif
+%if "%{gcc_version}" == "4.3.0"
+Source0: ftp://ftp.gnu.org/pub/gnu/gcc/%{gcc_pkgvers}/gcc-core-%{gcc_pkgvers}.tar.bz2
+Patch0: gcc-core-%{gcc_pkgvers}-rtems4.8-20080417.diff
+%endif
%if "%{gcc_version}" == "4.2.2"
Source0: ftp://gcc.gnu.org/pub/gcc/%{gcc_pkgvers}/gcc-core-%{gcc_pkgvers}.tar.bz2
Patch0: gcc-core-4.2.2-rtems4.8-20071127.diff
%endif
+%if "%{gcc_version}" == "4.2.3"
+Source0: ftp://gcc.gnu.org/pub/gcc/%{gcc_pkgvers}/gcc-core-%{gcc_pkgvers}.tar.bz2
+Patch0: gcc-core-4.2.3-rtems4.8-20080508.diff
+%endif
+%if "%{gcc_version}" == "4.2.4"
+Source0: ftp://gcc.gnu.org/pub/gcc/%{gcc_pkgvers}/gcc-core-%{gcc_pkgvers}.tar.bz2
+Patch0: gcc-core-4.2.4-rtems4.8-20080526.diff
+%endif
%{?_without_sources:NoSource: 0}
Source1: ftp://ftp.gnu.org/gnu/gcc/gcc-%{gcc_version}/gcc-g++-%{gcc_pkgvers}.tar.bz2
@@ -64,10 +115,14 @@ Source1: ftp://ftp.gnu.org/gnu/gcc/gcc-%{gcc_version}/gcc-g++-%{gcc_pkgvers}.ta
Source50: ftp://sources.redhat.com/pub/newlib/newlib-%{newlib_version}.tar.gz
%if "%{newlib_version}" == "1.15.0"
-Patch50: newlib-1.15.0-rtems4.8-20071221.diff
+Patch50: newlib-1.15.0-rtems4.8-20080903.diff
%endif
%{?_without_sources:NoSource: 50}
+%if "%{gcc_version}" >= "4.3.0"
+Source60: http://www.mpfr.org/mpfr-current/mpfr-%{mpfr_version}.tar.bz2
+%endif
+
%description
Cross gcc for m68k-rtems4.8.
@@ -91,6 +146,13 @@ cd ..
# Copy the C library into gcc's source tree
ln -s ../newlib-%{newlib_version}/newlib gcc-%{gcc_pkgvers}
+%if 0%{?_build_mpfr}
+%setup -q -T -D -n %{name}-%{version} -a60
+%{?PATCH60:%patch60 -p1}
+ # Build mpfr one-tree style
+ ln -s ../mpfr-%{mpfr_version} gcc-%{gcc_pkgvers}/mpfr
+%endif
+
%if "%{gcc_version}" < "4.1.0"
sed -e 's/\(version_string.* = \"[^\"]*\)/\1 (RTEMS gcc-%{gcc_version}\/newlib-%{newlib_version}-%release)/' \
gcc-%{gcc_pkgvers}/gcc/version.c > gcc-%{gcc_pkgvers}/gcc/version.c~
@@ -113,8 +175,12 @@ cd ..
languages="c"
languages="$languages,c++"
export PATH="%{_bindir}:${PATH}"
-
+%if "%{_build}" != "%{_host}"
+ CFLAGS_FOR_BUILD="-g -O2 -Wall" \
+ CC="%{_host}-gcc ${RPM_OPT_FLAGS}" \
+%else
CC="%{__cc} ${RPM_OPT_FLAGS}" \
+%endif
../gcc-%{gcc_pkgvers}/configure \
--prefix=%{_prefix} \
--bindir=%{_bindir} \
@@ -385,7 +451,6 @@ Requires(post): /sbin/install-info
Requires(preun): /sbin/install-info
%description -n rtems-4.8-gcc-common
-
GCC files that are shared by all targets.
%files -n rtems-4.8-gcc-common
@@ -440,6 +505,9 @@ Group: Development/Tools
Version: %{gcc_rpmvers}
License: GPL
+%if "%{_build}" != "%{_host}"
+BuildRequires: rtems-4.8-m68k-rtems4.8-gcc-c++
+%endif
Provides: rtems-4.8-m68k-rtems4.8-c++ = %{gcc_rpmvers}-%{release}
Obsoletes: rtems-4.8-m68k-rtems4.8-c++ < %{gcc_rpmvers}-%{release}
diff --git a/contrib/crossrpms/rtems4.8/m68k/rtems-4.8-m68k-rtems4.8-gdb.spec b/contrib/crossrpms/rtems4.8/m68k/rtems-4.8-m68k-rtems4.8-gdb.spec
index f56771a701..8128ea40f2 100644
--- a/contrib/crossrpms/rtems4.8/m68k/rtems-4.8-m68k-rtems4.8-gdb.spec
+++ b/contrib/crossrpms/rtems4.8/m68k/rtems-4.8-m68k-rtems4.8-gdb.spec
@@ -32,7 +32,7 @@ Name: rtems-4.8-m68k-rtems4.8-gdb
Summary: Gdb for target m68k-rtems4.8
Group: Development/Tools
Version: %{gdb_rpmvers}
-Release: 12%{?dist}
+Release: 13%{?dist}
License: GPL/LGPL
URL: http://sources.redhat.com/gdb
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
@@ -104,8 +104,10 @@ rm -f gdb-%{gdb_version}/readline/configure
--disable-win32-registry \
--disable-werror \
--enable-sim \
-%if "%{gdb_version}" >= "6.6"
+%if "%{gdb_version}" >= "6.7"
--with-system-readline \
+%endif
+%if "%{gdb_version}" >= "6.6"
--with-expat \
%endif
--prefix=%{_prefix} --bindir=%{_bindir} \
diff --git a/contrib/crossrpms/rtems4.8/mips/Makefile.am b/contrib/crossrpms/rtems4.8/mips/Makefile.am
index 2f22bf72e8..bb07c3ca2a 100644
--- a/contrib/crossrpms/rtems4.8/mips/Makefile.am
+++ b/contrib/crossrpms/rtems4.8/mips/Makefile.am
@@ -6,19 +6,19 @@ include $(top_srcdir)/mkspec.am
BINUTILS_VERS = 2.18
BINUTILS_PKGVERS = $(BINUTILS_VERS)
-BINUTILS_RPMREL = 3%{?dist}
+BINUTILS_RPMREL = 4%{?dist}
include ../binutils.am
BINUTILS_OPTS +=
GCC_VERS = 4.2.4
GCC_PKGVERS = $(GCC_VERS)
-GCC_RPMREL = 30%{?dist}
+GCC_RPMREL = 31%{?dist}
NEWLIB_VERS = 1.15.0
include ../gcc.am
GCC_OPTS += --languages=cxx
GDB_VERS = 6.6
GDB_PKGVERS = $(GDB_VERS)
-GDB_RPMREL = 12%{?dist}
+GDB_RPMREL = 13%{?dist}
include ../gdb.am
GDB_OPTS +=
diff --git a/contrib/crossrpms/rtems4.8/mips/gcc-sources.add b/contrib/crossrpms/rtems4.8/mips/gcc-sources.add
index ab22a92a6c..fb41d05b07 100644
--- a/contrib/crossrpms/rtems4.8/mips/gcc-sources.add
+++ b/contrib/crossrpms/rtems4.8/mips/gcc-sources.add
@@ -44,7 +44,7 @@ Source5: ftp://ftp.gnu.org/gnu/gcc/gcc-%{gcc_version}/gcc-objc-%{gcc_pkgvers}.ta
%if %build_newlib
Source50: ftp://sources.redhat.com/pub/newlib/newlib-%{newlib_version}.tar.gz
%if "%{newlib_version}" == "1.15.0"
-Patch50: newlib-1.15.0-rtems4.8-20080508.diff
+Patch50: newlib-1.15.0-rtems4.8-20080903.diff
%endif
%{?_without_sources:NoSource: 50}
%endif
diff --git a/contrib/crossrpms/rtems4.8/mips/rtems-4.8-mips-rtems4.8-binutils.spec b/contrib/crossrpms/rtems4.8/mips/rtems-4.8-mips-rtems4.8-binutils.spec
index 1b0f804f6d..5a30057c93 100644
--- a/contrib/crossrpms/rtems4.8/mips/rtems-4.8-mips-rtems4.8-binutils.spec
+++ b/contrib/crossrpms/rtems4.8/mips/rtems-4.8-mips-rtems4.8-binutils.spec
@@ -13,6 +13,18 @@
%define _exeext %{nil}
%endif
+%ifos cygwin cygwin32
+%define optflags -O3 -pipe -march=i486 -funroll-loops
+%define _libdir %{_exec_prefix}/lib
+%define debug_package %{nil}
+%endif
+
+%if "%{_build}" != "%{_host}"
+%define _host_rpmprefix rtems-4.8-%{_host}-
+%else
+%define _host_rpmprefix %{nil}
+%endif
+
%define binutils_pkgvers 2.18
%define binutils_version 2.18
%define binutils_rpmvers %{expand:%(echo "2.18" | tr - _ )}
@@ -21,11 +33,15 @@ Name: rtems-4.8-mips-rtems4.8-binutils
Summary: Binutils for target mips-rtems4.8
Group: Development/Tools
Version: %{binutils_rpmvers}
-Release: 3%{?dist}
+Release: 4%{?dist}
License: GPL/LGPL
URL: http://sources.redhat.com/binutils
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
+%if "%{_build}" != "%{_host}"
+BuildRequires: rtems-4.8-%{_host}-gcc
+%endif
+
%if "%{binutils_version}" >= "2.18"
# Bug in bfd: Doesn't build without texinfo installed
BuildRequires: texinfo >= 4.2
@@ -56,12 +72,16 @@ cd binutils-%{binutils_pkgvers}
cd ..
%build
+ export PATH="%{_bindir}:${PATH}"
%if "mips-rtems4.8" == "i686-pc-cygwin"
# The cygwin sources are leaking memory
RPM_OPT_FLAGS="$(echo "$RPM_OPT_FLAGS"|sed -e 's; -Wp,-D_FORTIFY_SOURCE=2;;')"
%endif
mkdir -p build
cd build
+%if "%{_build}" != "%{_host}"
+ CFLAGS_FOR_BUILD="-g -O2 -Wall" \
+%endif
CFLAGS="$RPM_OPT_FLAGS" \
../binutils-%{binutils_pkgvers}/configure \
--build=%_build --host=%_host \
@@ -80,17 +100,11 @@ cd ..
cd ..
%install
+ export PATH="%{_bindir}:${PATH}"
rm -rf $RPM_BUILD_ROOT
cd build
- make prefix=$RPM_BUILD_ROOT%{_prefix} \
- bindir=$RPM_BUILD_ROOT%{_bindir} \
- includedir=$RPM_BUILD_ROOT%{_includedir} \
- libdir=$RPM_BUILD_ROOT%{_libdir} \
- infodir=$RPM_BUILD_ROOT%{_infodir} \
- mandir=$RPM_BUILD_ROOT%{_mandir} \
- exec_prefix=$RPM_BUILD_ROOT%{_exec_prefix} \
- install
+ make DESTDIR=$RPM_BUILD_ROOT install
make prefix=$RPM_BUILD_ROOT%{_prefix} \
bindir=$RPM_BUILD_ROOT%{_bindir} \
@@ -168,7 +182,6 @@ sed -e 's,^[ ]*/usr/lib/rpm.*/brp-strip,./brp-strip,' \
# %endif
%description -n rtems-4.8-mips-rtems4.8-binutils
-
GNU binutils targetting mips-rtems4.8.
%files -n rtems-4.8-mips-rtems4.8-binutils
diff --git a/contrib/crossrpms/rtems4.8/mips/rtems-4.8-mips-rtems4.8-gcc.spec b/contrib/crossrpms/rtems4.8/mips/rtems-4.8-mips-rtems4.8-gcc.spec
index 778f74e9ce..dea696990e 100644
--- a/contrib/crossrpms/rtems4.8/mips/rtems-4.8-mips-rtems4.8-gcc.spec
+++ b/contrib/crossrpms/rtems4.8/mips/rtems-4.8-mips-rtems4.8-gcc.spec
@@ -13,30 +13,69 @@
%define _exeext %{nil}
%endif
+%ifos cygwin cygwin32
+%define optflags -O3 -pipe -march=i486 -funroll-loops
+%define _libdir %{_exec_prefix}/lib
+%define debug_package %{nil}
+%endif
+
+%if "%{_build}" != "%{_host}"
+%define _host_rpmprefix rtems-4.8-%{_host}-
+%else
+%define _host_rpmprefix %{nil}
+%endif
-%define gcc_pkgvers 4.2.2
-%define gcc_version 4.2.2
-%define gcc_rpmvers %{expand:%(echo "4.2.2" | tr - _ )}
+
+%define gcc_pkgvers 4.2.4
+%define gcc_version 4.2.4
+%define gcc_rpmvers %{expand:%(echo "4.2.4" | tr - _ )}
%define newlib_version 1.15.0
%define gccnewlib_version gcc%{gcc_version}newlib%{newlib_version}
+%define mpfr_version 2.3.1
+
Name: rtems-4.8-mips-rtems4.8-gcc
Summary: mips-rtems4.8 gcc
Group: Development/Tools
Version: %{gcc_rpmvers}
-Release: 28%{?dist}
+Release: 31%{?dist}
License: GPL
URL: http://gcc.gnu.org
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
%define _use_internal_dependency_generator 0
+BuildRequires: %{_host_rpmprefix}gcc
+
+%if "%{gcc_version}" >= "4.3.0"
+BuildRequires: gmp-devel >= 4.1
+%if "%{_build}" != "%{_host}"
+BuildRequires: %{_host_rpmprefix}gmp-devel
+BuildRequires: %{_host_rpmprefix}mpfr-devel
+%endif
+%if "%{?fedora}" >= "8"
+BuildRequires: mpfr-devel >= 2.3.0
+%endif
+%if "%{?suse}" > "10.3"
+BuildRequires: mpfr-devel >= 2.3.0
+%endif
+# These distros ship an insufficient mpfr
+%{?el4:%define _build_mpfr 1}
+%{?suse10_2:%define _build_mpfr 1}
+%{?suse10_3:%define _build_mpfr 1}
+%endif
+
+%if "%{_build}" != "%{_host}"
+BuildRequires: rtems-4.8-mips-rtems4.8-gcc
+%endif
+
%if "%{gcc_version}" >= "4.2.0"
BuildRequires: flex bison
%endif
+
BuildRequires: texinfo >= 4.2
BuildRequires: rtems-4.8-mips-rtems4.8-binutils
@@ -53,10 +92,22 @@ Requires: rtems-4.8-mips-rtems4.8-newlib = %{newlib_version}-%{release}
%define gccexec %{_libdir}/gcc-lib
%endif
+%if "%{gcc_version}" == "4.3.0"
+Source0: ftp://ftp.gnu.org/pub/gnu/gcc/%{gcc_pkgvers}/gcc-core-%{gcc_pkgvers}.tar.bz2
+Patch0: gcc-core-%{gcc_pkgvers}-rtems4.8-20080417.diff
+%endif
%if "%{gcc_version}" == "4.2.2"
Source0: ftp://gcc.gnu.org/pub/gcc/%{gcc_pkgvers}/gcc-core-%{gcc_pkgvers}.tar.bz2
Patch0: gcc-core-4.2.2-rtems4.8-20071127.diff
%endif
+%if "%{gcc_version}" == "4.2.3"
+Source0: ftp://gcc.gnu.org/pub/gcc/%{gcc_pkgvers}/gcc-core-%{gcc_pkgvers}.tar.bz2
+Patch0: gcc-core-4.2.3-rtems4.8-20080508.diff
+%endif
+%if "%{gcc_version}" == "4.2.4"
+Source0: ftp://gcc.gnu.org/pub/gcc/%{gcc_pkgvers}/gcc-core-%{gcc_pkgvers}.tar.bz2
+Patch0: gcc-core-4.2.4-rtems4.8-20080526.diff
+%endif
%{?_without_sources:NoSource: 0}
Source1: ftp://ftp.gnu.org/gnu/gcc/gcc-%{gcc_version}/gcc-g++-%{gcc_pkgvers}.tar.bz2
@@ -64,10 +115,14 @@ Source1: ftp://ftp.gnu.org/gnu/gcc/gcc-%{gcc_version}/gcc-g++-%{gcc_pkgvers}.ta
Source50: ftp://sources.redhat.com/pub/newlib/newlib-%{newlib_version}.tar.gz
%if "%{newlib_version}" == "1.15.0"
-Patch50: newlib-1.15.0-rtems4.8-20071221.diff
+Patch50: newlib-1.15.0-rtems4.8-20080903.diff
%endif
%{?_without_sources:NoSource: 50}
+%if "%{gcc_version}" >= "4.3.0"
+Source60: http://www.mpfr.org/mpfr-current/mpfr-%{mpfr_version}.tar.bz2
+%endif
+
%description
Cross gcc for mips-rtems4.8.
@@ -91,6 +146,13 @@ cd ..
# Copy the C library into gcc's source tree
ln -s ../newlib-%{newlib_version}/newlib gcc-%{gcc_pkgvers}
+%if 0%{?_build_mpfr}
+%setup -q -T -D -n %{name}-%{version} -a60
+%{?PATCH60:%patch60 -p1}
+ # Build mpfr one-tree style
+ ln -s ../mpfr-%{mpfr_version} gcc-%{gcc_pkgvers}/mpfr
+%endif
+
%if "%{gcc_version}" < "4.1.0"
sed -e 's/\(version_string.* = \"[^\"]*\)/\1 (RTEMS gcc-%{gcc_version}\/newlib-%{newlib_version}-%release)/' \
gcc-%{gcc_pkgvers}/gcc/version.c > gcc-%{gcc_pkgvers}/gcc/version.c~
@@ -113,8 +175,12 @@ cd ..
languages="c"
languages="$languages,c++"
export PATH="%{_bindir}:${PATH}"
-
+%if "%{_build}" != "%{_host}"
+ CFLAGS_FOR_BUILD="-g -O2 -Wall" \
+ CC="%{_host}-gcc ${RPM_OPT_FLAGS}" \
+%else
CC="%{__cc} ${RPM_OPT_FLAGS}" \
+%endif
../gcc-%{gcc_pkgvers}/configure \
--prefix=%{_prefix} \
--bindir=%{_bindir} \
@@ -385,7 +451,6 @@ Requires(post): /sbin/install-info
Requires(preun): /sbin/install-info
%description -n rtems-4.8-gcc-common
-
GCC files that are shared by all targets.
%files -n rtems-4.8-gcc-common
@@ -440,6 +505,9 @@ Group: Development/Tools
Version: %{gcc_rpmvers}
License: GPL
+%if "%{_build}" != "%{_host}"
+BuildRequires: rtems-4.8-mips-rtems4.8-gcc-c++
+%endif
Provides: rtems-4.8-mips-rtems4.8-c++ = %{gcc_rpmvers}-%{release}
Obsoletes: rtems-4.8-mips-rtems4.8-c++ < %{gcc_rpmvers}-%{release}
diff --git a/contrib/crossrpms/rtems4.8/mips/rtems-4.8-mips-rtems4.8-gdb.spec b/contrib/crossrpms/rtems4.8/mips/rtems-4.8-mips-rtems4.8-gdb.spec
index 9f8bc7a3bc..0429cb6530 100644
--- a/contrib/crossrpms/rtems4.8/mips/rtems-4.8-mips-rtems4.8-gdb.spec
+++ b/contrib/crossrpms/rtems4.8/mips/rtems-4.8-mips-rtems4.8-gdb.spec
@@ -32,7 +32,7 @@ Name: rtems-4.8-mips-rtems4.8-gdb
Summary: Gdb for target mips-rtems4.8
Group: Development/Tools
Version: %{gdb_rpmvers}
-Release: 12%{?dist}
+Release: 13%{?dist}
License: GPL/LGPL
URL: http://sources.redhat.com/gdb
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
@@ -104,8 +104,10 @@ rm -f gdb-%{gdb_version}/readline/configure
--disable-win32-registry \
--disable-werror \
--enable-sim \
-%if "%{gdb_version}" >= "6.6"
+%if "%{gdb_version}" >= "6.7"
--with-system-readline \
+%endif
+%if "%{gdb_version}" >= "6.6"
--with-expat \
%endif
--prefix=%{_prefix} --bindir=%{_bindir} \
diff --git a/contrib/crossrpms/rtems4.8/mipstx39/Makefile.am b/contrib/crossrpms/rtems4.8/mipstx39/Makefile.am
index 790ab66d82..56d068ce91 100644
--- a/contrib/crossrpms/rtems4.8/mipstx39/Makefile.am
+++ b/contrib/crossrpms/rtems4.8/mipstx39/Makefile.am
@@ -7,6 +7,6 @@ include $(top_srcdir)/mkspec.am
# We only want a gdb with a tx39 simulator in it. We share the other tools
GDB_VERS = 6.6
GDB_PKGVERS = $(GDB_VERS)
-GDB_RPMREL = 12%{?dist}
+GDB_RPMREL = 13%{?dist}
include ../gdb.am
GDB_OPTS +=
diff --git a/contrib/crossrpms/rtems4.8/mipstx39/rtems-4.8-mipstx39-rtems4.8-gdb.spec b/contrib/crossrpms/rtems4.8/mipstx39/rtems-4.8-mipstx39-rtems4.8-gdb.spec
index 290bdf8a66..ceeee4fd6e 100644
--- a/contrib/crossrpms/rtems4.8/mipstx39/rtems-4.8-mipstx39-rtems4.8-gdb.spec
+++ b/contrib/crossrpms/rtems4.8/mipstx39/rtems-4.8-mipstx39-rtems4.8-gdb.spec
@@ -32,7 +32,7 @@ Name: rtems-4.8-mipstx39-rtems4.8-gdb
Summary: Gdb for target mipstx39-rtems4.8
Group: Development/Tools
Version: %{gdb_rpmvers}
-Release: 12%{?dist}
+Release: 13%{?dist}
License: GPL/LGPL
URL: http://sources.redhat.com/gdb
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
@@ -104,8 +104,10 @@ rm -f gdb-%{gdb_version}/readline/configure
--disable-win32-registry \
--disable-werror \
--enable-sim \
-%if "%{gdb_version}" >= "6.6"
+%if "%{gdb_version}" >= "6.7"
--with-system-readline \
+%endif
+%if "%{gdb_version}" >= "6.6"
--with-expat \
%endif
--prefix=%{_prefix} --bindir=%{_bindir} \
diff --git a/contrib/crossrpms/rtems4.8/powerpc/Makefile.am b/contrib/crossrpms/rtems4.8/powerpc/Makefile.am
index 5247f4e97d..b09399c5d0 100644
--- a/contrib/crossrpms/rtems4.8/powerpc/Makefile.am
+++ b/contrib/crossrpms/rtems4.8/powerpc/Makefile.am
@@ -6,19 +6,19 @@ include $(top_srcdir)/mkspec.am
BINUTILS_VERS = 2.18
BINUTILS_PKGVERS = $(BINUTILS_VERS)
-BINUTILS_RPMREL = 3%{?dist}
+BINUTILS_RPMREL = 4%{?dist}
include ../binutils.am
BINUTILS_OPTS +=
GCC_VERS = 4.2.4
GCC_PKGVERS = $(GCC_VERS)
-GCC_RPMREL = 30%{?dist}
+GCC_RPMREL = 31%{?dist}
NEWLIB_VERS = 1.15.0
include ../gcc.am
GCC_OPTS += --languages=cxx
GDB_VERS = 6.6
GDB_PKGVERS = $(GDB_VERS)
-GDB_RPMREL = 12%{?dist}
+GDB_RPMREL = 13%{?dist}
include ../gdb.am
GDB_OPTS +=
diff --git a/contrib/crossrpms/rtems4.8/powerpc/gcc-sources.add b/contrib/crossrpms/rtems4.8/powerpc/gcc-sources.add
index ab22a92a6c..fb41d05b07 100644
--- a/contrib/crossrpms/rtems4.8/powerpc/gcc-sources.add
+++ b/contrib/crossrpms/rtems4.8/powerpc/gcc-sources.add
@@ -44,7 +44,7 @@ Source5: ftp://ftp.gnu.org/gnu/gcc/gcc-%{gcc_version}/gcc-objc-%{gcc_pkgvers}.ta
%if %build_newlib
Source50: ftp://sources.redhat.com/pub/newlib/newlib-%{newlib_version}.tar.gz
%if "%{newlib_version}" == "1.15.0"
-Patch50: newlib-1.15.0-rtems4.8-20080508.diff
+Patch50: newlib-1.15.0-rtems4.8-20080903.diff
%endif
%{?_without_sources:NoSource: 50}
%endif
diff --git a/contrib/crossrpms/rtems4.8/powerpc/rtems-4.8-powerpc-rtems4.8-binutils.spec b/contrib/crossrpms/rtems4.8/powerpc/rtems-4.8-powerpc-rtems4.8-binutils.spec
index 04752488a9..283107c306 100644
--- a/contrib/crossrpms/rtems4.8/powerpc/rtems-4.8-powerpc-rtems4.8-binutils.spec
+++ b/contrib/crossrpms/rtems4.8/powerpc/rtems-4.8-powerpc-rtems4.8-binutils.spec
@@ -13,6 +13,18 @@
%define _exeext %{nil}
%endif
+%ifos cygwin cygwin32
+%define optflags -O3 -pipe -march=i486 -funroll-loops
+%define _libdir %{_exec_prefix}/lib
+%define debug_package %{nil}
+%endif
+
+%if "%{_build}" != "%{_host}"
+%define _host_rpmprefix rtems-4.8-%{_host}-
+%else
+%define _host_rpmprefix %{nil}
+%endif
+
%define binutils_pkgvers 2.18
%define binutils_version 2.18
%define binutils_rpmvers %{expand:%(echo "2.18" | tr - _ )}
@@ -21,11 +33,15 @@ Name: rtems-4.8-powerpc-rtems4.8-binutils
Summary: Binutils for target powerpc-rtems4.8
Group: Development/Tools
Version: %{binutils_rpmvers}
-Release: 3%{?dist}
+Release: 4%{?dist}
License: GPL/LGPL
URL: http://sources.redhat.com/binutils
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
+%if "%{_build}" != "%{_host}"
+BuildRequires: rtems-4.8-%{_host}-gcc
+%endif
+
%if "%{binutils_version}" >= "2.18"
# Bug in bfd: Doesn't build without texinfo installed
BuildRequires: texinfo >= 4.2
@@ -56,12 +72,16 @@ cd binutils-%{binutils_pkgvers}
cd ..
%build
+ export PATH="%{_bindir}:${PATH}"
%if "powerpc-rtems4.8" == "i686-pc-cygwin"
# The cygwin sources are leaking memory
RPM_OPT_FLAGS="$(echo "$RPM_OPT_FLAGS"|sed -e 's; -Wp,-D_FORTIFY_SOURCE=2;;')"
%endif
mkdir -p build
cd build
+%if "%{_build}" != "%{_host}"
+ CFLAGS_FOR_BUILD="-g -O2 -Wall" \
+%endif
CFLAGS="$RPM_OPT_FLAGS" \
../binutils-%{binutils_pkgvers}/configure \
--build=%_build --host=%_host \
@@ -80,17 +100,11 @@ cd ..
cd ..
%install
+ export PATH="%{_bindir}:${PATH}"
rm -rf $RPM_BUILD_ROOT
cd build
- make prefix=$RPM_BUILD_ROOT%{_prefix} \
- bindir=$RPM_BUILD_ROOT%{_bindir} \
- includedir=$RPM_BUILD_ROOT%{_includedir} \
- libdir=$RPM_BUILD_ROOT%{_libdir} \
- infodir=$RPM_BUILD_ROOT%{_infodir} \
- mandir=$RPM_BUILD_ROOT%{_mandir} \
- exec_prefix=$RPM_BUILD_ROOT%{_exec_prefix} \
- install
+ make DESTDIR=$RPM_BUILD_ROOT install
make prefix=$RPM_BUILD_ROOT%{_prefix} \
bindir=$RPM_BUILD_ROOT%{_bindir} \
@@ -168,7 +182,6 @@ sed -e 's,^[ ]*/usr/lib/rpm.*/brp-strip,./brp-strip,' \
# %endif
%description -n rtems-4.8-powerpc-rtems4.8-binutils
-
GNU binutils targetting powerpc-rtems4.8.
%files -n rtems-4.8-powerpc-rtems4.8-binutils
diff --git a/contrib/crossrpms/rtems4.8/powerpc/rtems-4.8-powerpc-rtems4.8-gcc.spec b/contrib/crossrpms/rtems4.8/powerpc/rtems-4.8-powerpc-rtems4.8-gcc.spec
index f6a83b99a4..e85c781c37 100644
--- a/contrib/crossrpms/rtems4.8/powerpc/rtems-4.8-powerpc-rtems4.8-gcc.spec
+++ b/contrib/crossrpms/rtems4.8/powerpc/rtems-4.8-powerpc-rtems4.8-gcc.spec
@@ -13,30 +13,69 @@
%define _exeext %{nil}
%endif
+%ifos cygwin cygwin32
+%define optflags -O3 -pipe -march=i486 -funroll-loops
+%define _libdir %{_exec_prefix}/lib
+%define debug_package %{nil}
+%endif
+
+%if "%{_build}" != "%{_host}"
+%define _host_rpmprefix rtems-4.8-%{_host}-
+%else
+%define _host_rpmprefix %{nil}
+%endif
-%define gcc_pkgvers 4.2.2
-%define gcc_version 4.2.2
-%define gcc_rpmvers %{expand:%(echo "4.2.2" | tr - _ )}
+
+%define gcc_pkgvers 4.2.4
+%define gcc_version 4.2.4
+%define gcc_rpmvers %{expand:%(echo "4.2.4" | tr - _ )}
%define newlib_version 1.15.0
%define gccnewlib_version gcc%{gcc_version}newlib%{newlib_version}
+%define mpfr_version 2.3.1
+
Name: rtems-4.8-powerpc-rtems4.8-gcc
Summary: powerpc-rtems4.8 gcc
Group: Development/Tools
Version: %{gcc_rpmvers}
-Release: 28%{?dist}
+Release: 31%{?dist}
License: GPL
URL: http://gcc.gnu.org
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
%define _use_internal_dependency_generator 0
+BuildRequires: %{_host_rpmprefix}gcc
+
+%if "%{gcc_version}" >= "4.3.0"
+BuildRequires: gmp-devel >= 4.1
+%if "%{_build}" != "%{_host}"
+BuildRequires: %{_host_rpmprefix}gmp-devel
+BuildRequires: %{_host_rpmprefix}mpfr-devel
+%endif
+%if "%{?fedora}" >= "8"
+BuildRequires: mpfr-devel >= 2.3.0
+%endif
+%if "%{?suse}" > "10.3"
+BuildRequires: mpfr-devel >= 2.3.0
+%endif
+# These distros ship an insufficient mpfr
+%{?el4:%define _build_mpfr 1}
+%{?suse10_2:%define _build_mpfr 1}
+%{?suse10_3:%define _build_mpfr 1}
+%endif
+
+%if "%{_build}" != "%{_host}"
+BuildRequires: rtems-4.8-powerpc-rtems4.8-gcc
+%endif
+
%if "%{gcc_version}" >= "4.2.0"
BuildRequires: flex bison
%endif
+
BuildRequires: texinfo >= 4.2
BuildRequires: rtems-4.8-powerpc-rtems4.8-binutils
@@ -53,10 +92,22 @@ Requires: rtems-4.8-powerpc-rtems4.8-newlib = %{newlib_version}-%{release}
%define gccexec %{_libdir}/gcc-lib
%endif
+%if "%{gcc_version}" == "4.3.0"
+Source0: ftp://ftp.gnu.org/pub/gnu/gcc/%{gcc_pkgvers}/gcc-core-%{gcc_pkgvers}.tar.bz2
+Patch0: gcc-core-%{gcc_pkgvers}-rtems4.8-20080417.diff
+%endif
%if "%{gcc_version}" == "4.2.2"
Source0: ftp://gcc.gnu.org/pub/gcc/%{gcc_pkgvers}/gcc-core-%{gcc_pkgvers}.tar.bz2
Patch0: gcc-core-4.2.2-rtems4.8-20071127.diff
%endif
+%if "%{gcc_version}" == "4.2.3"
+Source0: ftp://gcc.gnu.org/pub/gcc/%{gcc_pkgvers}/gcc-core-%{gcc_pkgvers}.tar.bz2
+Patch0: gcc-core-4.2.3-rtems4.8-20080508.diff
+%endif
+%if "%{gcc_version}" == "4.2.4"
+Source0: ftp://gcc.gnu.org/pub/gcc/%{gcc_pkgvers}/gcc-core-%{gcc_pkgvers}.tar.bz2
+Patch0: gcc-core-4.2.4-rtems4.8-20080526.diff
+%endif
%{?_without_sources:NoSource: 0}
Source1: ftp://ftp.gnu.org/gnu/gcc/gcc-%{gcc_version}/gcc-g++-%{gcc_pkgvers}.tar.bz2
@@ -64,10 +115,14 @@ Source1: ftp://ftp.gnu.org/gnu/gcc/gcc-%{gcc_version}/gcc-g++-%{gcc_pkgvers}.ta
Source50: ftp://sources.redhat.com/pub/newlib/newlib-%{newlib_version}.tar.gz
%if "%{newlib_version}" == "1.15.0"
-Patch50: newlib-1.15.0-rtems4.8-20071221.diff
+Patch50: newlib-1.15.0-rtems4.8-20080903.diff
%endif
%{?_without_sources:NoSource: 50}
+%if "%{gcc_version}" >= "4.3.0"
+Source60: http://www.mpfr.org/mpfr-current/mpfr-%{mpfr_version}.tar.bz2
+%endif
+
%description
Cross gcc for powerpc-rtems4.8.
@@ -91,6 +146,13 @@ cd ..
# Copy the C library into gcc's source tree
ln -s ../newlib-%{newlib_version}/newlib gcc-%{gcc_pkgvers}
+%if 0%{?_build_mpfr}
+%setup -q -T -D -n %{name}-%{version} -a60
+%{?PATCH60:%patch60 -p1}
+ # Build mpfr one-tree style
+ ln -s ../mpfr-%{mpfr_version} gcc-%{gcc_pkgvers}/mpfr
+%endif
+
%if "%{gcc_version}" < "4.1.0"
sed -e 's/\(version_string.* = \"[^\"]*\)/\1 (RTEMS gcc-%{gcc_version}\/newlib-%{newlib_version}-%release)/' \
gcc-%{gcc_pkgvers}/gcc/version.c > gcc-%{gcc_pkgvers}/gcc/version.c~
@@ -113,8 +175,12 @@ cd ..
languages="c"
languages="$languages,c++"
export PATH="%{_bindir}:${PATH}"
-
+%if "%{_build}" != "%{_host}"
+ CFLAGS_FOR_BUILD="-g -O2 -Wall" \
+ CC="%{_host}-gcc ${RPM_OPT_FLAGS}" \
+%else
CC="%{__cc} ${RPM_OPT_FLAGS}" \
+%endif
../gcc-%{gcc_pkgvers}/configure \
--prefix=%{_prefix} \
--bindir=%{_bindir} \
@@ -385,7 +451,6 @@ Requires(post): /sbin/install-info
Requires(preun): /sbin/install-info
%description -n rtems-4.8-gcc-common
-
GCC files that are shared by all targets.
%files -n rtems-4.8-gcc-common
@@ -440,6 +505,9 @@ Group: Development/Tools
Version: %{gcc_rpmvers}
License: GPL
+%if "%{_build}" != "%{_host}"
+BuildRequires: rtems-4.8-powerpc-rtems4.8-gcc-c++
+%endif
Provides: rtems-4.8-powerpc-rtems4.8-c++ = %{gcc_rpmvers}-%{release}
Obsoletes: rtems-4.8-powerpc-rtems4.8-c++ < %{gcc_rpmvers}-%{release}
diff --git a/contrib/crossrpms/rtems4.8/powerpc/rtems-4.8-powerpc-rtems4.8-gdb.spec b/contrib/crossrpms/rtems4.8/powerpc/rtems-4.8-powerpc-rtems4.8-gdb.spec
index 1954953038..ef25a689cc 100644
--- a/contrib/crossrpms/rtems4.8/powerpc/rtems-4.8-powerpc-rtems4.8-gdb.spec
+++ b/contrib/crossrpms/rtems4.8/powerpc/rtems-4.8-powerpc-rtems4.8-gdb.spec
@@ -32,7 +32,7 @@ Name: rtems-4.8-powerpc-rtems4.8-gdb
Summary: Gdb for target powerpc-rtems4.8
Group: Development/Tools
Version: %{gdb_rpmvers}
-Release: 12%{?dist}
+Release: 13%{?dist}
License: GPL/LGPL
URL: http://sources.redhat.com/gdb
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
@@ -104,8 +104,10 @@ rm -f gdb-%{gdb_version}/readline/configure
--disable-win32-registry \
--disable-werror \
--enable-sim \
-%if "%{gdb_version}" >= "6.6"
+%if "%{gdb_version}" >= "6.7"
--with-system-readline \
+%endif
+%if "%{gdb_version}" >= "6.6"
--with-expat \
%endif
--prefix=%{_prefix} --bindir=%{_bindir} \
diff --git a/contrib/crossrpms/rtems4.8/sh/Makefile.am b/contrib/crossrpms/rtems4.8/sh/Makefile.am
index e690ab8aee..de91342c30 100644
--- a/contrib/crossrpms/rtems4.8/sh/Makefile.am
+++ b/contrib/crossrpms/rtems4.8/sh/Makefile.am
@@ -6,19 +6,19 @@ include $(top_srcdir)/mkspec.am
BINUTILS_VERS = 2.18
BINUTILS_PKGVERS = $(BINUTILS_VERS)
-BINUTILS_RPMREL = 3%{?dist}
+BINUTILS_RPMREL = 4%{?dist}
include ../binutils.am
BINUTILS_OPTS +=
GCC_VERS = 4.2.4
GCC_PKGVERS = $(GCC_VERS)
-GCC_RPMREL = 30%{?dist}
+GCC_RPMREL = 31%{?dist}
NEWLIB_VERS = 1.15.0
include ../gcc.am
GCC_OPTS += --languages=cxx
GDB_VERS = 6.6
GDB_PKGVERS = $(GDB_VERS)
-GDB_RPMREL = 12%{?dist}
+GDB_RPMREL = 13%{?dist}
include ../gdb.am
GDB_OPTS +=
diff --git a/contrib/crossrpms/rtems4.8/sh/gcc-sources.add b/contrib/crossrpms/rtems4.8/sh/gcc-sources.add
index ab22a92a6c..fb41d05b07 100644
--- a/contrib/crossrpms/rtems4.8/sh/gcc-sources.add
+++ b/contrib/crossrpms/rtems4.8/sh/gcc-sources.add
@@ -44,7 +44,7 @@ Source5: ftp://ftp.gnu.org/gnu/gcc/gcc-%{gcc_version}/gcc-objc-%{gcc_pkgvers}.ta
%if %build_newlib
Source50: ftp://sources.redhat.com/pub/newlib/newlib-%{newlib_version}.tar.gz
%if "%{newlib_version}" == "1.15.0"
-Patch50: newlib-1.15.0-rtems4.8-20080508.diff
+Patch50: newlib-1.15.0-rtems4.8-20080903.diff
%endif
%{?_without_sources:NoSource: 50}
%endif
diff --git a/contrib/crossrpms/rtems4.8/sh/rtems-4.8-sh-rtems4.8-binutils.spec b/contrib/crossrpms/rtems4.8/sh/rtems-4.8-sh-rtems4.8-binutils.spec
index 55393bfa9d..dd791191c4 100644
--- a/contrib/crossrpms/rtems4.8/sh/rtems-4.8-sh-rtems4.8-binutils.spec
+++ b/contrib/crossrpms/rtems4.8/sh/rtems-4.8-sh-rtems4.8-binutils.spec
@@ -13,6 +13,18 @@
%define _exeext %{nil}
%endif
+%ifos cygwin cygwin32
+%define optflags -O3 -pipe -march=i486 -funroll-loops
+%define _libdir %{_exec_prefix}/lib
+%define debug_package %{nil}
+%endif
+
+%if "%{_build}" != "%{_host}"
+%define _host_rpmprefix rtems-4.8-%{_host}-
+%else
+%define _host_rpmprefix %{nil}
+%endif
+
%define binutils_pkgvers 2.18
%define binutils_version 2.18
%define binutils_rpmvers %{expand:%(echo "2.18" | tr - _ )}
@@ -21,11 +33,15 @@ Name: rtems-4.8-sh-rtems4.8-binutils
Summary: Binutils for target sh-rtems4.8
Group: Development/Tools
Version: %{binutils_rpmvers}
-Release: 3%{?dist}
+Release: 4%{?dist}
License: GPL/LGPL
URL: http://sources.redhat.com/binutils
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
+%if "%{_build}" != "%{_host}"
+BuildRequires: rtems-4.8-%{_host}-gcc
+%endif
+
%if "%{binutils_version}" >= "2.18"
# Bug in bfd: Doesn't build without texinfo installed
BuildRequires: texinfo >= 4.2
@@ -56,12 +72,16 @@ cd binutils-%{binutils_pkgvers}
cd ..
%build
+ export PATH="%{_bindir}:${PATH}"
%if "sh-rtems4.8" == "i686-pc-cygwin"
# The cygwin sources are leaking memory
RPM_OPT_FLAGS="$(echo "$RPM_OPT_FLAGS"|sed -e 's; -Wp,-D_FORTIFY_SOURCE=2;;')"
%endif
mkdir -p build
cd build
+%if "%{_build}" != "%{_host}"
+ CFLAGS_FOR_BUILD="-g -O2 -Wall" \
+%endif
CFLAGS="$RPM_OPT_FLAGS" \
../binutils-%{binutils_pkgvers}/configure \
--build=%_build --host=%_host \
@@ -80,17 +100,11 @@ cd ..
cd ..
%install
+ export PATH="%{_bindir}:${PATH}"
rm -rf $RPM_BUILD_ROOT
cd build
- make prefix=$RPM_BUILD_ROOT%{_prefix} \
- bindir=$RPM_BUILD_ROOT%{_bindir} \
- includedir=$RPM_BUILD_ROOT%{_includedir} \
- libdir=$RPM_BUILD_ROOT%{_libdir} \
- infodir=$RPM_BUILD_ROOT%{_infodir} \
- mandir=$RPM_BUILD_ROOT%{_mandir} \
- exec_prefix=$RPM_BUILD_ROOT%{_exec_prefix} \
- install
+ make DESTDIR=$RPM_BUILD_ROOT install
make prefix=$RPM_BUILD_ROOT%{_prefix} \
bindir=$RPM_BUILD_ROOT%{_bindir} \
@@ -168,7 +182,6 @@ sed -e 's,^[ ]*/usr/lib/rpm.*/brp-strip,./brp-strip,' \
# %endif
%description -n rtems-4.8-sh-rtems4.8-binutils
-
GNU binutils targetting sh-rtems4.8.
%files -n rtems-4.8-sh-rtems4.8-binutils
diff --git a/contrib/crossrpms/rtems4.8/sh/rtems-4.8-sh-rtems4.8-gcc.spec b/contrib/crossrpms/rtems4.8/sh/rtems-4.8-sh-rtems4.8-gcc.spec
index e6994f7c26..36efc89aff 100644
--- a/contrib/crossrpms/rtems4.8/sh/rtems-4.8-sh-rtems4.8-gcc.spec
+++ b/contrib/crossrpms/rtems4.8/sh/rtems-4.8-sh-rtems4.8-gcc.spec
@@ -13,30 +13,69 @@
%define _exeext %{nil}
%endif
+%ifos cygwin cygwin32
+%define optflags -O3 -pipe -march=i486 -funroll-loops
+%define _libdir %{_exec_prefix}/lib
+%define debug_package %{nil}
+%endif
+
+%if "%{_build}" != "%{_host}"
+%define _host_rpmprefix rtems-4.8-%{_host}-
+%else
+%define _host_rpmprefix %{nil}
+%endif
-%define gcc_pkgvers 4.2.2
-%define gcc_version 4.2.2
-%define gcc_rpmvers %{expand:%(echo "4.2.2" | tr - _ )}
+
+%define gcc_pkgvers 4.2.4
+%define gcc_version 4.2.4
+%define gcc_rpmvers %{expand:%(echo "4.2.4" | tr - _ )}
%define newlib_version 1.15.0
%define gccnewlib_version gcc%{gcc_version}newlib%{newlib_version}
+%define mpfr_version 2.3.1
+
Name: rtems-4.8-sh-rtems4.8-gcc
Summary: sh-rtems4.8 gcc
Group: Development/Tools
Version: %{gcc_rpmvers}
-Release: 28%{?dist}
+Release: 31%{?dist}
License: GPL
URL: http://gcc.gnu.org
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
%define _use_internal_dependency_generator 0
+BuildRequires: %{_host_rpmprefix}gcc
+
+%if "%{gcc_version}" >= "4.3.0"
+BuildRequires: gmp-devel >= 4.1
+%if "%{_build}" != "%{_host}"
+BuildRequires: %{_host_rpmprefix}gmp-devel
+BuildRequires: %{_host_rpmprefix}mpfr-devel
+%endif
+%if "%{?fedora}" >= "8"
+BuildRequires: mpfr-devel >= 2.3.0
+%endif
+%if "%{?suse}" > "10.3"
+BuildRequires: mpfr-devel >= 2.3.0
+%endif
+# These distros ship an insufficient mpfr
+%{?el4:%define _build_mpfr 1}
+%{?suse10_2:%define _build_mpfr 1}
+%{?suse10_3:%define _build_mpfr 1}
+%endif
+
+%if "%{_build}" != "%{_host}"
+BuildRequires: rtems-4.8-sh-rtems4.8-gcc
+%endif
+
%if "%{gcc_version}" >= "4.2.0"
BuildRequires: flex bison
%endif
+
BuildRequires: texinfo >= 4.2
BuildRequires: rtems-4.8-sh-rtems4.8-binutils
@@ -53,10 +92,22 @@ Requires: rtems-4.8-sh-rtems4.8-newlib = %{newlib_version}-%{release}
%define gccexec %{_libdir}/gcc-lib
%endif
+%if "%{gcc_version}" == "4.3.0"
+Source0: ftp://ftp.gnu.org/pub/gnu/gcc/%{gcc_pkgvers}/gcc-core-%{gcc_pkgvers}.tar.bz2
+Patch0: gcc-core-%{gcc_pkgvers}-rtems4.8-20080417.diff
+%endif
%if "%{gcc_version}" == "4.2.2"
Source0: ftp://gcc.gnu.org/pub/gcc/%{gcc_pkgvers}/gcc-core-%{gcc_pkgvers}.tar.bz2
Patch0: gcc-core-4.2.2-rtems4.8-20071127.diff
%endif
+%if "%{gcc_version}" == "4.2.3"
+Source0: ftp://gcc.gnu.org/pub/gcc/%{gcc_pkgvers}/gcc-core-%{gcc_pkgvers}.tar.bz2
+Patch0: gcc-core-4.2.3-rtems4.8-20080508.diff
+%endif
+%if "%{gcc_version}" == "4.2.4"
+Source0: ftp://gcc.gnu.org/pub/gcc/%{gcc_pkgvers}/gcc-core-%{gcc_pkgvers}.tar.bz2
+Patch0: gcc-core-4.2.4-rtems4.8-20080526.diff
+%endif
%{?_without_sources:NoSource: 0}
Source1: ftp://ftp.gnu.org/gnu/gcc/gcc-%{gcc_version}/gcc-g++-%{gcc_pkgvers}.tar.bz2
@@ -64,10 +115,14 @@ Source1: ftp://ftp.gnu.org/gnu/gcc/gcc-%{gcc_version}/gcc-g++-%{gcc_pkgvers}.ta
Source50: ftp://sources.redhat.com/pub/newlib/newlib-%{newlib_version}.tar.gz
%if "%{newlib_version}" == "1.15.0"
-Patch50: newlib-1.15.0-rtems4.8-20071221.diff
+Patch50: newlib-1.15.0-rtems4.8-20080903.diff
%endif
%{?_without_sources:NoSource: 50}
+%if "%{gcc_version}" >= "4.3.0"
+Source60: http://www.mpfr.org/mpfr-current/mpfr-%{mpfr_version}.tar.bz2
+%endif
+
%description
Cross gcc for sh-rtems4.8.
@@ -91,6 +146,13 @@ cd ..
# Copy the C library into gcc's source tree
ln -s ../newlib-%{newlib_version}/newlib gcc-%{gcc_pkgvers}
+%if 0%{?_build_mpfr}
+%setup -q -T -D -n %{name}-%{version} -a60
+%{?PATCH60:%patch60 -p1}
+ # Build mpfr one-tree style
+ ln -s ../mpfr-%{mpfr_version} gcc-%{gcc_pkgvers}/mpfr
+%endif
+
%if "%{gcc_version}" < "4.1.0"
sed -e 's/\(version_string.* = \"[^\"]*\)/\1 (RTEMS gcc-%{gcc_version}\/newlib-%{newlib_version}-%release)/' \
gcc-%{gcc_pkgvers}/gcc/version.c > gcc-%{gcc_pkgvers}/gcc/version.c~
@@ -113,8 +175,12 @@ cd ..
languages="c"
languages="$languages,c++"
export PATH="%{_bindir}:${PATH}"
-
+%if "%{_build}" != "%{_host}"
+ CFLAGS_FOR_BUILD="-g -O2 -Wall" \
+ CC="%{_host}-gcc ${RPM_OPT_FLAGS}" \
+%else
CC="%{__cc} ${RPM_OPT_FLAGS}" \
+%endif
../gcc-%{gcc_pkgvers}/configure \
--prefix=%{_prefix} \
--bindir=%{_bindir} \
@@ -385,7 +451,6 @@ Requires(post): /sbin/install-info
Requires(preun): /sbin/install-info
%description -n rtems-4.8-gcc-common
-
GCC files that are shared by all targets.
%files -n rtems-4.8-gcc-common
@@ -440,6 +505,9 @@ Group: Development/Tools
Version: %{gcc_rpmvers}
License: GPL
+%if "%{_build}" != "%{_host}"
+BuildRequires: rtems-4.8-sh-rtems4.8-gcc-c++
+%endif
Provides: rtems-4.8-sh-rtems4.8-c++ = %{gcc_rpmvers}-%{release}
Obsoletes: rtems-4.8-sh-rtems4.8-c++ < %{gcc_rpmvers}-%{release}
diff --git a/contrib/crossrpms/rtems4.8/sh/rtems-4.8-sh-rtems4.8-gdb.spec b/contrib/crossrpms/rtems4.8/sh/rtems-4.8-sh-rtems4.8-gdb.spec
index a7832dc73f..8600ab57c3 100644
--- a/contrib/crossrpms/rtems4.8/sh/rtems-4.8-sh-rtems4.8-gdb.spec
+++ b/contrib/crossrpms/rtems4.8/sh/rtems-4.8-sh-rtems4.8-gdb.spec
@@ -32,7 +32,7 @@ Name: rtems-4.8-sh-rtems4.8-gdb
Summary: Gdb for target sh-rtems4.8
Group: Development/Tools
Version: %{gdb_rpmvers}
-Release: 12%{?dist}
+Release: 13%{?dist}
License: GPL/LGPL
URL: http://sources.redhat.com/gdb
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
@@ -104,8 +104,10 @@ rm -f gdb-%{gdb_version}/readline/configure
--disable-win32-registry \
--disable-werror \
--enable-sim \
-%if "%{gdb_version}" >= "6.6"
+%if "%{gdb_version}" >= "6.7"
--with-system-readline \
+%endif
+%if "%{gdb_version}" >= "6.6"
--with-expat \
%endif
--prefix=%{_prefix} --bindir=%{_bindir} \
diff --git a/contrib/crossrpms/rtems4.8/sparc/Makefile.am b/contrib/crossrpms/rtems4.8/sparc/Makefile.am
index e85c1d0f2f..021089b9eb 100644
--- a/contrib/crossrpms/rtems4.8/sparc/Makefile.am
+++ b/contrib/crossrpms/rtems4.8/sparc/Makefile.am
@@ -6,19 +6,19 @@ include $(top_srcdir)/mkspec.am
BINUTILS_VERS = 2.18
BINUTILS_PKGVERS = $(BINUTILS_VERS)
-BINUTILS_RPMREL = 3%{?dist}
+BINUTILS_RPMREL = 4%{?dist}
include ../binutils.am
BINUTILS_OPTS +=
GCC_VERS = 4.2.4
GCC_PKGVERS = $(GCC_VERS)
-GCC_RPMREL = 30%{?dist}
+GCC_RPMREL = 31%{?dist}
NEWLIB_VERS = 1.15.0
include ../gcc.am
GCC_OPTS += --languages=cxx
GDB_VERS = 6.8
GDB_PKGVERS = $(GDB_VERS)
-GDB_RPMREL = 1%{?dist}
+GDB_RPMREL = 2%{?dist}
include ../gdb.am
GDB_OPTS +=
diff --git a/contrib/crossrpms/rtems4.8/sparc/gcc-sources.add b/contrib/crossrpms/rtems4.8/sparc/gcc-sources.add
index ab22a92a6c..fb41d05b07 100644
--- a/contrib/crossrpms/rtems4.8/sparc/gcc-sources.add
+++ b/contrib/crossrpms/rtems4.8/sparc/gcc-sources.add
@@ -44,7 +44,7 @@ Source5: ftp://ftp.gnu.org/gnu/gcc/gcc-%{gcc_version}/gcc-objc-%{gcc_pkgvers}.ta
%if %build_newlib
Source50: ftp://sources.redhat.com/pub/newlib/newlib-%{newlib_version}.tar.gz
%if "%{newlib_version}" == "1.15.0"
-Patch50: newlib-1.15.0-rtems4.8-20080508.diff
+Patch50: newlib-1.15.0-rtems4.8-20080903.diff
%endif
%{?_without_sources:NoSource: 50}
%endif
diff --git a/contrib/crossrpms/rtems4.8/sparc/rtems-4.8-sparc-rtems4.8-binutils.spec b/contrib/crossrpms/rtems4.8/sparc/rtems-4.8-sparc-rtems4.8-binutils.spec
index 613280c31f..0c7a99f23a 100644
--- a/contrib/crossrpms/rtems4.8/sparc/rtems-4.8-sparc-rtems4.8-binutils.spec
+++ b/contrib/crossrpms/rtems4.8/sparc/rtems-4.8-sparc-rtems4.8-binutils.spec
@@ -13,6 +13,18 @@
%define _exeext %{nil}
%endif
+%ifos cygwin cygwin32
+%define optflags -O3 -pipe -march=i486 -funroll-loops
+%define _libdir %{_exec_prefix}/lib
+%define debug_package %{nil}
+%endif
+
+%if "%{_build}" != "%{_host}"
+%define _host_rpmprefix rtems-4.8-%{_host}-
+%else
+%define _host_rpmprefix %{nil}
+%endif
+
%define binutils_pkgvers 2.18
%define binutils_version 2.18
%define binutils_rpmvers %{expand:%(echo "2.18" | tr - _ )}
@@ -21,11 +33,15 @@ Name: rtems-4.8-sparc-rtems4.8-binutils
Summary: Binutils for target sparc-rtems4.8
Group: Development/Tools
Version: %{binutils_rpmvers}
-Release: 3%{?dist}
+Release: 4%{?dist}
License: GPL/LGPL
URL: http://sources.redhat.com/binutils
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
+%if "%{_build}" != "%{_host}"
+BuildRequires: rtems-4.8-%{_host}-gcc
+%endif
+
%if "%{binutils_version}" >= "2.18"
# Bug in bfd: Doesn't build without texinfo installed
BuildRequires: texinfo >= 4.2
@@ -56,12 +72,16 @@ cd binutils-%{binutils_pkgvers}
cd ..
%build
+ export PATH="%{_bindir}:${PATH}"
%if "sparc-rtems4.8" == "i686-pc-cygwin"
# The cygwin sources are leaking memory
RPM_OPT_FLAGS="$(echo "$RPM_OPT_FLAGS"|sed -e 's; -Wp,-D_FORTIFY_SOURCE=2;;')"
%endif
mkdir -p build
cd build
+%if "%{_build}" != "%{_host}"
+ CFLAGS_FOR_BUILD="-g -O2 -Wall" \
+%endif
CFLAGS="$RPM_OPT_FLAGS" \
../binutils-%{binutils_pkgvers}/configure \
--build=%_build --host=%_host \
@@ -80,17 +100,11 @@ cd ..
cd ..
%install
+ export PATH="%{_bindir}:${PATH}"
rm -rf $RPM_BUILD_ROOT
cd build
- make prefix=$RPM_BUILD_ROOT%{_prefix} \
- bindir=$RPM_BUILD_ROOT%{_bindir} \
- includedir=$RPM_BUILD_ROOT%{_includedir} \
- libdir=$RPM_BUILD_ROOT%{_libdir} \
- infodir=$RPM_BUILD_ROOT%{_infodir} \
- mandir=$RPM_BUILD_ROOT%{_mandir} \
- exec_prefix=$RPM_BUILD_ROOT%{_exec_prefix} \
- install
+ make DESTDIR=$RPM_BUILD_ROOT install
make prefix=$RPM_BUILD_ROOT%{_prefix} \
bindir=$RPM_BUILD_ROOT%{_bindir} \
@@ -168,7 +182,6 @@ sed -e 's,^[ ]*/usr/lib/rpm.*/brp-strip,./brp-strip,' \
# %endif
%description -n rtems-4.8-sparc-rtems4.8-binutils
-
GNU binutils targetting sparc-rtems4.8.
%files -n rtems-4.8-sparc-rtems4.8-binutils
diff --git a/contrib/crossrpms/rtems4.8/sparc/rtems-4.8-sparc-rtems4.8-gcc.spec b/contrib/crossrpms/rtems4.8/sparc/rtems-4.8-sparc-rtems4.8-gcc.spec
index 0bc53f4a0e..b3815931c3 100644
--- a/contrib/crossrpms/rtems4.8/sparc/rtems-4.8-sparc-rtems4.8-gcc.spec
+++ b/contrib/crossrpms/rtems4.8/sparc/rtems-4.8-sparc-rtems4.8-gcc.spec
@@ -13,30 +13,69 @@
%define _exeext %{nil}
%endif
+%ifos cygwin cygwin32
+%define optflags -O3 -pipe -march=i486 -funroll-loops
+%define _libdir %{_exec_prefix}/lib
+%define debug_package %{nil}
+%endif
+
+%if "%{_build}" != "%{_host}"
+%define _host_rpmprefix rtems-4.8-%{_host}-
+%else
+%define _host_rpmprefix %{nil}
+%endif
-%define gcc_pkgvers 4.2.2
-%define gcc_version 4.2.2
-%define gcc_rpmvers %{expand:%(echo "4.2.2" | tr - _ )}
+
+%define gcc_pkgvers 4.2.4
+%define gcc_version 4.2.4
+%define gcc_rpmvers %{expand:%(echo "4.2.4" | tr - _ )}
%define newlib_version 1.15.0
%define gccnewlib_version gcc%{gcc_version}newlib%{newlib_version}
+%define mpfr_version 2.3.1
+
Name: rtems-4.8-sparc-rtems4.8-gcc
Summary: sparc-rtems4.8 gcc
Group: Development/Tools
Version: %{gcc_rpmvers}
-Release: 28%{?dist}
+Release: 31%{?dist}
License: GPL
URL: http://gcc.gnu.org
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
%define _use_internal_dependency_generator 0
+BuildRequires: %{_host_rpmprefix}gcc
+
+%if "%{gcc_version}" >= "4.3.0"
+BuildRequires: gmp-devel >= 4.1
+%if "%{_build}" != "%{_host}"
+BuildRequires: %{_host_rpmprefix}gmp-devel
+BuildRequires: %{_host_rpmprefix}mpfr-devel
+%endif
+%if "%{?fedora}" >= "8"
+BuildRequires: mpfr-devel >= 2.3.0
+%endif
+%if "%{?suse}" > "10.3"
+BuildRequires: mpfr-devel >= 2.3.0
+%endif
+# These distros ship an insufficient mpfr
+%{?el4:%define _build_mpfr 1}
+%{?suse10_2:%define _build_mpfr 1}
+%{?suse10_3:%define _build_mpfr 1}
+%endif
+
+%if "%{_build}" != "%{_host}"
+BuildRequires: rtems-4.8-sparc-rtems4.8-gcc
+%endif
+
%if "%{gcc_version}" >= "4.2.0"
BuildRequires: flex bison
%endif
+
BuildRequires: texinfo >= 4.2
BuildRequires: rtems-4.8-sparc-rtems4.8-binutils
@@ -53,10 +92,22 @@ Requires: rtems-4.8-sparc-rtems4.8-newlib = %{newlib_version}-%{release}
%define gccexec %{_libdir}/gcc-lib
%endif
+%if "%{gcc_version}" == "4.3.0"
+Source0: ftp://ftp.gnu.org/pub/gnu/gcc/%{gcc_pkgvers}/gcc-core-%{gcc_pkgvers}.tar.bz2
+Patch0: gcc-core-%{gcc_pkgvers}-rtems4.8-20080417.diff
+%endif
%if "%{gcc_version}" == "4.2.2"
Source0: ftp://gcc.gnu.org/pub/gcc/%{gcc_pkgvers}/gcc-core-%{gcc_pkgvers}.tar.bz2
Patch0: gcc-core-4.2.2-rtems4.8-20071127.diff
%endif
+%if "%{gcc_version}" == "4.2.3"
+Source0: ftp://gcc.gnu.org/pub/gcc/%{gcc_pkgvers}/gcc-core-%{gcc_pkgvers}.tar.bz2
+Patch0: gcc-core-4.2.3-rtems4.8-20080508.diff
+%endif
+%if "%{gcc_version}" == "4.2.4"
+Source0: ftp://gcc.gnu.org/pub/gcc/%{gcc_pkgvers}/gcc-core-%{gcc_pkgvers}.tar.bz2
+Patch0: gcc-core-4.2.4-rtems4.8-20080526.diff
+%endif
%{?_without_sources:NoSource: 0}
Source1: ftp://ftp.gnu.org/gnu/gcc/gcc-%{gcc_version}/gcc-g++-%{gcc_pkgvers}.tar.bz2
@@ -64,10 +115,14 @@ Source1: ftp://ftp.gnu.org/gnu/gcc/gcc-%{gcc_version}/gcc-g++-%{gcc_pkgvers}.ta
Source50: ftp://sources.redhat.com/pub/newlib/newlib-%{newlib_version}.tar.gz
%if "%{newlib_version}" == "1.15.0"
-Patch50: newlib-1.15.0-rtems4.8-20071221.diff
+Patch50: newlib-1.15.0-rtems4.8-20080903.diff
%endif
%{?_without_sources:NoSource: 50}
+%if "%{gcc_version}" >= "4.3.0"
+Source60: http://www.mpfr.org/mpfr-current/mpfr-%{mpfr_version}.tar.bz2
+%endif
+
%description
Cross gcc for sparc-rtems4.8.
@@ -91,6 +146,13 @@ cd ..
# Copy the C library into gcc's source tree
ln -s ../newlib-%{newlib_version}/newlib gcc-%{gcc_pkgvers}
+%if 0%{?_build_mpfr}
+%setup -q -T -D -n %{name}-%{version} -a60
+%{?PATCH60:%patch60 -p1}
+ # Build mpfr one-tree style
+ ln -s ../mpfr-%{mpfr_version} gcc-%{gcc_pkgvers}/mpfr
+%endif
+
%if "%{gcc_version}" < "4.1.0"
sed -e 's/\(version_string.* = \"[^\"]*\)/\1 (RTEMS gcc-%{gcc_version}\/newlib-%{newlib_version}-%release)/' \
gcc-%{gcc_pkgvers}/gcc/version.c > gcc-%{gcc_pkgvers}/gcc/version.c~
@@ -113,8 +175,12 @@ cd ..
languages="c"
languages="$languages,c++"
export PATH="%{_bindir}:${PATH}"
-
+%if "%{_build}" != "%{_host}"
+ CFLAGS_FOR_BUILD="-g -O2 -Wall" \
+ CC="%{_host}-gcc ${RPM_OPT_FLAGS}" \
+%else
CC="%{__cc} ${RPM_OPT_FLAGS}" \
+%endif
../gcc-%{gcc_pkgvers}/configure \
--prefix=%{_prefix} \
--bindir=%{_bindir} \
@@ -385,7 +451,6 @@ Requires(post): /sbin/install-info
Requires(preun): /sbin/install-info
%description -n rtems-4.8-gcc-common
-
GCC files that are shared by all targets.
%files -n rtems-4.8-gcc-common
@@ -440,6 +505,9 @@ Group: Development/Tools
Version: %{gcc_rpmvers}
License: GPL
+%if "%{_build}" != "%{_host}"
+BuildRequires: rtems-4.8-sparc-rtems4.8-gcc-c++
+%endif
Provides: rtems-4.8-sparc-rtems4.8-c++ = %{gcc_rpmvers}-%{release}
Obsoletes: rtems-4.8-sparc-rtems4.8-c++ < %{gcc_rpmvers}-%{release}
diff --git a/contrib/crossrpms/rtems4.8/sparc/rtems-4.8-sparc-rtems4.8-gdb.spec b/contrib/crossrpms/rtems4.8/sparc/rtems-4.8-sparc-rtems4.8-gdb.spec
index 27c7c97a63..42e02b3a3d 100644
--- a/contrib/crossrpms/rtems4.8/sparc/rtems-4.8-sparc-rtems4.8-gdb.spec
+++ b/contrib/crossrpms/rtems4.8/sparc/rtems-4.8-sparc-rtems4.8-gdb.spec
@@ -32,7 +32,7 @@ Name: rtems-4.8-sparc-rtems4.8-gdb
Summary: Gdb for target sparc-rtems4.8
Group: Development/Tools
Version: %{gdb_rpmvers}
-Release: 1%{?dist}
+Release: 2%{?dist}
License: GPL/LGPL
URL: http://sources.redhat.com/gdb
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
@@ -104,8 +104,10 @@ rm -f gdb-%{gdb_version}/readline/configure
--disable-win32-registry \
--disable-werror \
--enable-sim \
-%if "%{gdb_version}" >= "6.6"
+%if "%{gdb_version}" >= "6.7"
--with-system-readline \
+%endif
+%if "%{gdb_version}" >= "6.6"
--with-expat \
%endif
--prefix=%{_prefix} --bindir=%{_bindir} \