#
-# conditional build:
-# _with_allarchs - enable
+# Conditional build:
+%bcond_with allarchs # enable all targets
+# define addtargets x,y,z # build with additional targets x,y,z (e.g. x86_64-linux)
#
Summary: GNU Binary Utility Development Utilities
Summary(de): GNU Binary Utility Development Utilities
Summary(tr): GNU geliþtirme araçlarý
Summary(uk): îÁÂ¦Ò ¦ÎÓÔÒÕÍÅÎÔ¦× GNU ÄÌÑ ÐÏÂÕÄÏ×É ×ÉËÏÎÕ×ÁÎÉÈ ÐÒÏÇÒÁÍ
Name: binutils
-Version: 2.14.90.0.6
+Version: 2.16.90.0.1
Release: 2
Epoch: 2
License: GPL
Group: Development/Tools
Source0: ftp://ftp.kernel.org/pub/linux/devel/binutils/%{name}-%{version}.tar.bz2
-# Source0-md5: 71b99dba3045a359dc314dbebedcf502
+# Source0-md5: b231856d84a6181572b0b3371cfc6843
Source1: http://www.mif.pg.gda.pl/homepages/ankry/man-PLD/%{name}-non-english-man-pages.tar.bz2
# Source1-md5: a717d9707ec77d82acb6ec9078c472d6
Patch0: %{name}-gasp.patch
Patch1: %{name}-info.patch
-Patch2: %{name}-array-sects-compat.patch
-Patch3: %{name}-eh-frame-ro.patch
-Patch4: %{name}-ia64-bootstrap.patch
-Patch5: %{name}-libtool-relink.patch
-Patch6: %{name}-sparc-cfi.patch
+Patch2: %{name}-libtool-relink.patch
+Patch3: %{name}-pt_pax_flags.patch
+Patch4: %{name}-mips-relocs.patch
+Patch5: %{name}-flex.patch
+Patch6: %{name}-needed.patch
+Patch7: %{name}-pr815.patch
+Patch8: %{name}-pr872.patch
URL: http://sources.redhat.com/binutils/
-BuildRequires: automake
+BuildRequires: autoconf >= 2.59
+BuildRequires: automake >= 1:1.8.2
BuildRequires: bison
BuildRequires: flex
BuildRequires: gettext-devel
- nlmconv - convert object code into an NLM.
%description -l es
-binutils es una colectánea de utilitarios necesarios para compilar
+Binutils es una colección de utilitarios necesarios para compilar
programas. Incluye assembler y linker, así como varios otros programas
para trabajar con formatos que se puedan ejecutar.
Summary: GNU Binutils static libraries
Summary(pl): Biblioteki statyczne do GNU Binutils
Group: Development/Libraries
-Requires: %{name} = %{epoch}:%{version}
+Requires: %{name} = %{epoch}:%{version}-%{release}
%description static
Static libraries for GNU Binutils.
Summary: GASP - old preprocessor for assembly programs
Summary(pl): GASP - stary preprocesor dla programów w asemblerze
Group: Development/Tools
-Requires: %{name} = %{epoch}:%{version}
+Requires: %{name} = %{epoch}:%{version}-%{release}
%description gasp
GASP - old preprocessor for assembly programs. It's officially
niektórych pakietów.
%prep
-%setup -q
+%setup -q
%patch0 -p1
%patch1 -p1
-%ifarch %{ix86}
%patch2 -p1
-%endif
+%patch3 -p1
+%patch4 -p0
%patch5 -p1
%patch6 -p0
-# need update:
-#%patch3 -p1
-#%patch4 -p1
+%patch7 -p0
+%patch8 -p0
%build
+# non-standard regeneration (needed because of gasp patch)
+cd gas
+aclocal
+automake --cygnus Makefile
+automake --cygnus doc/Makefile
+autoconf
+cd ..
+
+# More targets
+TARGETS=
+%ifarch ia64
+TARGETS=i686-linux
+%endif
+# uhm?
+%ifarch %{ix86}
+TARGETS=x86_64-linux
+%endif
+%ifarch sparc
+TARGETS=sparc64-linux
+%endif
+%{?addtargets:TARGETS="%{addtargets}"}
+
cp -f /usr/share/automake/config.* .
CFLAGS="%{rpmcflags}"; export CFLAGS
CC="%{__cc}"; export CC
sparc32 \
%endif
./configure %{_target_platform} \
- --enable-shared \
--disable-debug \
+ --enable-build-warnings=,-Wno-missing-prototypes \
+ --enable-shared \
--prefix=%{_prefix} \
+ --libdir=%{_libdir} \
--infodir=%{_infodir} \
--mandir=%{_mandir} \
+ %{!?with_allarchs:`[ -n "${TARGETS}" ] && echo "--enable-targets=${TARGETS}"`} \
%ifarch sparc
- --enable-targets=sparc64-linux \
--enable-64-bit-bfd \
+%else
+ %{?with_allarchs:--enable-64-bit-bfd} \
%endif
-%ifnarch sparc
- %{?_with_allarchs:--enable-64-bit-bfd} \
-%endif
- %{?_with_allarchs:--enable-targets=alpha-linux,arm-linux,cris-linux,hppa-linux,i386-linux,ia64-linux,m68k-linux,mips-linux,mips64-linux,mips64el-linux,mipsel-linux,ppc-linux,s390-linux,s390x-linux,sh-linux,sparc-linux,sparc64-linux,i386-linuxaout}
+ %{?with_allarchs:--enable-targets=alpha-linux,arm-linux,cris-linux,hppa-linux,i386-linux,ia64-linux,x86_64-linux,m68k-linux,mips-linux,mips64-linux,mips64el-linux,mipsel-linux,ppc-linux,s390-linux,s390x-linux,sh-linux,sparc-linux,sparc64-linux,i386-linuxaout}
-%{__make} tooldir=%{_prefix} all info
+%{__make} configure-bfd
+%{__make} headers -C bfd
+%{__make} all info \
+ tooldir=%{_prefix}
%install
rm -rf $RPM_BUILD_ROOT
bzip2 -dc %{SOURCE1} | tar xf - -C $RPM_BUILD_ROOT%{_mandir}
install include/libiberty.h $RPM_BUILD_ROOT%{_includedir}
+install libiberty/pic/libiberty.a $RPM_BUILD_ROOT%{_libdir}
# remove evil -L pointing inside builder's home
perl -pi -e 's@-L[^ ]*/pic @@g' $RPM_BUILD_ROOT%{_libdir}/libbfd.la
%{_libdir}*/libiberty.a
%{_libdir}*/lib*.la
-%{_libdir}/ldscripts
+%{_prefix}/lib/ldscripts
%{_includedir}/*.h
%{_infodir}/[!g]*.info*