New native version of GnuTLS.
[fedora-mingw.git] / binutils / mingw-binutils.spec
1 %define binutils_version 2.18.50
2 %define mingw_binutils_version 20080109-2
3 %define mingw_binutils_rpmvers %{expand:%(echo %{mingw_binutils_version} | tr - _)} 
4
5 Name:           mingw-binutils
6 Version:        %{binutils_version}_%{mingw_binutils_rpmvers}
7 Release:        7%{?dist}
8 Summary:        MinGW Windows binutils
9
10 License:        GPLv2+ and LGPLv2+ and GPLv3+ and LGPLv3+
11 Group:          Development/Libraries
12 URL:            http://www.mingw.org/
13 Source0:        http://dl.sourceforge.net/sourceforge/mingw/binutils-%{binutils_version}-%{mingw_binutils_version}-src.tar.gz
14 BuildRoot:      %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
15
16 BuildRequires:  flex
17 BuildRequires:  bison
18 BuildRequires:  texinfo
19 BuildRequires:  mingw-filesystem >= 2
20
21 Requires:       mingw-filesystem >= 2
22
23
24 %description
25 MinGW Windows binutils (utilities like 'strip', 'as', 'ld') which
26 understand Windows executables and DLLs.
27
28
29 %prep
30 %setup -q -n binutils-%{binutils_version}
31
32
33 %build
34 mkdir -p build
35 cd build
36 CFLAGS="$RPM_OPT_FLAGS" \
37 ../configure \
38   --build=%_build --host=%_host \
39   --target=%{_mingw_target} \
40   --verbose --disable-nls \
41   --without-included-gettext \
42   --disable-win32-registry \
43   --disable-werror \
44   --with-sysroot=%{_mingw_sysroot} \
45   --prefix=%{_prefix} --bindir=%{_bindir} \
46   --includedir=%{_includedir} --libdir=%{_libdir} \
47   --mandir=%{_mandir} --infodir=%{_infodir}
48
49 make all
50
51
52 %install
53 rm -rf $RPM_BUILD_ROOT
54
55 cd build
56 make DESTDIR=$RPM_BUILD_ROOT install
57
58 # These files conflict with ordinary binutils.
59 rm -rf $RPM_BUILD_ROOT%{_infodir}
60 rm -f ${RPM_BUILD_ROOT}%{_libdir}/libiberty*
61
62
63 %clean
64 rm -rf $RPM_BUILD_ROOT
65
66
67 %files
68 %defattr(-,root,root)
69 %{_mandir}/man1/*
70 %{_bindir}/i686-pc-mingw32-*
71 %{_prefix}/i686-pc-mingw32/bin
72 %{_prefix}/i686-pc-mingw32/lib/ldscripts
73
74
75 %changelog
76 * Thu Sep  4 2008 Richard W.M. Jones <rjones@redhat.com> - 2.18.50_20080109_2-7
77 - Use mingw-filesystem.
78
79 * Mon Jul  7 2008 Richard W.M. Jones <rjones@redhat.com> - 2.18.50_20080109_2-5
80 - Initial RPM release, largely based on earlier work from several sources.