1 | # |
---|
2 | # spec file for binutils package targetting freebsd |
---|
3 | # |
---|
4 | |
---|
5 | %define _prefix @PREFIX@ |
---|
6 | |
---|
7 | %define binutils_version @BINUTILS_VERS@ |
---|
8 | %define binutils_rpmvers %{expand: %(echo @BINUTILS_VERS@ | tr - _)} |
---|
9 | |
---|
10 | %define __os_install_post %{nil} |
---|
11 | |
---|
12 | Vendor: RTEMS.org |
---|
13 | Distribution: Linux |
---|
14 | Name: i386-freebsd5-binutils |
---|
15 | Summary: binutils for target i386-freebsd5 |
---|
16 | Group: freebsd |
---|
17 | Release: @BINUTILS_RPMREL@ |
---|
18 | Summary: binutils for i386-freebsd5 |
---|
19 | License: GPL/LGPL |
---|
20 | Packager: Ralf Corsepius <ralf_corsepius@rtems.org> |
---|
21 | Prefix: %{_prefix} |
---|
22 | BuildRoot: @RPM_BUILD_ROOT@ |
---|
23 | |
---|
24 | Version: %binutils_rpmvers |
---|
25 | Source0: ftp://ftp.gnu.org.com/pub/gnu/binutils/binutils-%{binutils_version}-20040411.tar.bz2 |
---|
26 | NoSource: 0 |
---|
27 | |
---|
28 | # Urgh, but RH's find-* is too stupid to cope with foreign objects |
---|
29 | # Autoreqprov: off |
---|
30 | |
---|
31 | %description |
---|
32 | |
---|
33 | Cross binutils for target freebsd |
---|
34 | |
---|
35 | %prep |
---|
36 | # untar the sources inside i386-freebsd5-binutils |
---|
37 | %setup -c -n i386-freebsd5-binutils -a 0 |
---|
38 | |
---|
39 | %build |
---|
40 | test -d build || mkdir build |
---|
41 | cd build |
---|
42 | ../binutils-%{binutils_version}/configure --target=i386-freebsd5 \ |
---|
43 | --disable-nls --disable-win32-registry \ |
---|
44 | --verbose --prefix=%{prefix} |
---|
45 | |
---|
46 | make all |
---|
47 | |
---|
48 | %install |
---|
49 | rm -rf $RPM_BUILD_ROOT |
---|
50 | cd build |
---|
51 | make prefix=$RPM_BUILD_ROOT%{prefix} install |
---|
52 | |
---|
53 | # A bug in binutils: binutils does not install share/locale |
---|
54 | # however it uses it |
---|
55 | ../binutils-%{binutils_version}/mkinstalldirs \ |
---|
56 | $RPM_BUILD_ROOT%{prefix}/share/locale |
---|
57 | |
---|
58 | # We don't want info files |
---|
59 | rm -rf $RPM_BUILD_ROOT%{prefix}/info |
---|
60 | |
---|
61 | %files |
---|
62 | |
---|
63 | %dir %{prefix}/man |
---|
64 | %dir %{prefix}/man/man1 |
---|
65 | %doc %{prefix}/man/man1/i386-freebsd5* |
---|
66 | |
---|
67 | # %dir %{prefix}/include |
---|
68 | # %{prefix}/include/*.h |
---|
69 | |
---|
70 | %exclude %{prefix}/lib |
---|
71 | |
---|
72 | %dir %{prefix}/share |
---|
73 | %dir %{prefix}/share/locale |
---|
74 | |
---|
75 | %dir %{prefix}/bin |
---|
76 | %{prefix}/bin/* |
---|
77 | |
---|
78 | %dir %{prefix}/i386-freebsd5 |
---|
79 | %dir %{prefix}/i386-freebsd5/bin |
---|
80 | %{prefix}/i386-freebsd5/bin/* |
---|
81 | |
---|
82 | %dir %{prefix}/i386-freebsd5/lib |
---|
83 | %{prefix}/i386-freebsd5/lib/ldscripts |
---|