%define target arm-none-eabi Name: %{target}-binutils Version: 2.20 Release: 1%{?dist} Summary: Cross Compiling GNU binutils targeted at %{target} Group: Development/Tools License: GPLv2+ URL: http://www.gnu.org/software/binutils/ Source0: ftp://ftp.gnu.org/pub/gnu/binutils/binutils-%{version}.tar.bz2 Source1: README.fedora BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-%(%{__id_u} -n) %description This is a Cross Compiling version of GNU binutils, which can be used to assemble and link binaries for the %{target} platform, instead of for the native %{_arch} platform. %prep %setup -q -c pushd binutils-%{version} popd cp %{SOURCE1} . %build mkdir -p build pushd build CFLAGS="$RPM_OPT_FLAGS" ../binutils-%{version}/configure --prefix=%{_prefix} \ --libdir=%{_libdir} --mandir=%{_mandir} --infodir=%{_infodir} \ --target=%{target} --disable-werror --disable-nls make %{?_smp_mflags} popd build %install rm -rf $RPM_BUILD_ROOT pushd build make install DESTDIR=$RPM_BUILD_ROOT popd build # these are for win targets only rm $RPM_BUILD_ROOT%{_mandir}/man1/%{target}-{dlltool,nlmconv,windres}.1 # we don't want these as we are a cross version rm -r $RPM_BUILD_ROOT%{_infodir} rm $RPM_BUILD_ROOT%{_libdir}/libiberty.a %clean rm -rf $RPM_BUILD_ROOT %files %defattr(-,root,root,-) %doc binutils-%{version}/COPYING binutils-%{version}/COPYING.LIB %doc binutils-%{version}/README README.fedora %{_prefix}/%{target} %{_bindir}/%{target}-* %{_mandir}/man1/%{target}-*.1.gz %changelog * Fri Feb 5 2010 Eric Smith 2.20-1 - new spec for arm-none-eabi, based on arm-gp2x-linux-binutils-2.16.1-7