# The following three variables define the target tuple %define processor_arch arm %define platform none %define abi eabi # CodeSourcery releases are identified by a date, a release number, # and a package number for downloading from their web site %define cs_date 2010q1 %define cs_rel 188 %define cs_pkgnum 6492 %define target %{processor_arch}-%{platform}-%{abi} Name: %{target}-binutils-cs Version: %{cs_date}_%{cs_rel} Release: 1%{?dist} Summary: GNU Binutils for cross-compilation for %{target} target Group: Development/Tools License: GPLv2+ and GPLv3+ and LGPLv2+ and BSD URL: http://www.codesourcery.com/sgpp/lite/%{processor_arch} Source0: http://www.codesourcery.com/sgpp/lite/%{processor_arch}/portal/package%{cs_pkgnum}/public/%{target}/%{processor_arch}-%{cs_date}-%{cs_rel}-%{target}.src.tar.bz2 Source1: README.fedora BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-%(%{__id_u} -n) BuildRequires: flex bison ppl-devel cloog-ppl-devel gawk BuildRequires: texinfo texinfo-tex texlive-utils %description This is a cross-compilation version of GNU Binutils, which can be used to assemble and link binaries for the %{target} platform. This Binutils package is based on the CodeSourcery %{cs_date}-%{cs_rel} release, which includes improved ARM target support compared to the corresponding FSF release. CodeSourcery contributes their changes to the FSF, but it takes a while for them to get merged. For the ARM target, effectively CodeSourcery is upstream of FSF. %prep %setup -q -c tar -xj --strip-components=1 -f arm-%{cs_date}-%{cs_rel}-%{target}/binutils-%{cs_date}-%{cs_rel}.tar.bz2 rm -rf arm-%{cs_date}-%{cs_rel}-%{target} cp %{SOURCE1} . %build ./configure CFLAGS="$RPM_OPT_FLAGS" \ --target=%{target} \ "--with-pkgversion=Sourcery G++ Lite %{cs_date}-%{cs_rel}" \ --enable-poison-system-directories \ --prefix=%{_prefix} \ --libdir=%{_libdir} \ --mandir=%{_mandir} \ --infodir=%{_infodir} \ --with-docdir=share/doc/%{name}-%{cs_date}_%{cs_rel} \ --disable-nls \ --disable-werror make %{?_smp_mflags} %install rm -rf %{buildroot} make install DESTDIR=%{buildroot} # these are for win targets only rm %{buildroot}%{_mandir}/man1/%{target}-{dlltool,nlmconv,windres}.1 # we don't want these as we are a cross version rm -r %{buildroot}%{_infodir} rm %{buildroot}%{_libdir}/libiberty.a %clean rm -rf %{buildroot} %files %defattr(-,root,root,-) %doc %{_docdir}/%{name}-%{cs_date}_%{cs_rel}/ %{_prefix}/%{target} %{_bindir}/%{target}-* %{_mandir}/man1/%{target}-*.1.gz %changelog * Fri Feb 5 2010 Eric Smith 2010q1_188-1 - new spec for arm-none-eabi using CodeSourcery release