]>
Commit | Line | Data |
---|---|---|
281bac7a | 1 | Summary: Cross AVR GNU binary utility development utilities - gcc |
c7d51c5d ER |
2 | Summary(es.UTF-8): Utilitarios para desarrollo de binarios de la GNU - AVR gcc |
3 | Summary(fr.UTF-8): Utilitaires de développement binaire de GNU - AVR gcc | |
4 | Summary(pl.UTF-8): Skrośne narzędzia programistyczne GNU dla AVR - gcc | |
5 | Summary(pt_BR.UTF-8): Utilitários para desenvolvimento de binários da GNU - AVR gcc | |
6 | Summary(tr.UTF-8): GNU geliştirme araçları - AVR gcc | |
40ea5eb2 | 7 | Name: crossavr-gcc |
a9577062 | 8 | Version: 4.1.2 |
f323cece | 9 | Release: 2 |
391a0dd0 ER |
10 | Patch0: %{name}-0b-constants.patch |
11 | Patch1: %{name}-attribute_alias.patch | |
12 | Patch2: %{name}-bug25672.patch | |
13 | Patch3: %{name}-dwarf.patch | |
14 | Patch4: %{name}-libiberty-Makefile.in.patch | |
15 | Patch5: %{name}-newdevices.patch | |
16 | Patch6: %{name}-zz-atmega256x.patch | |
40ea5eb2 WK |
17 | Epoch: 1 |
18 | License: GPL | |
19 | Group: Development/Languages | |
6b88a121 | 20 | Source0: ftp://gcc.gnu.org/pub/gcc/releases/gcc-%{version}/gcc-%{version}.tar.bz2 |
a9577062 | 21 | # Source0-md5: a4a3eb15c96030906d8494959eeda23c |
40ea5eb2 | 22 | BuildRequires: /bin/bash |
f323cece | 23 | BuildRequires: autoconf |
fdd61bcf JB |
24 | BuildRequires: bison |
25 | BuildRequires: crossavr-binutils | |
26 | BuildRequires: flex | |
40ea5eb2 | 27 | Requires: crossavr-binutils |
c2bc48fa | 28 | Requires: gcc-dirs |
40ea5eb2 WK |
29 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
30 | ||
40ea5eb2 | 31 | %define target avr |
40ea5eb2 | 32 | %define arch %{_prefix}/%{target} |
df3c6f23 JB |
33 | %define gccarch %{_libdir}/gcc/%{target} |
34 | %define gcclib %{_libdir}/gcc/%{target}/%{version} | |
ef8212dd | 35 | %define _noautostrip .*%{gcclib}.*/libgc.*\\.a |
40ea5eb2 WK |
36 | |
37 | %description | |
38 | This package contains a cross-gcc which allows the creation of | |
7f5526fe | 39 | binaries to be run on Atmel AVR on other machines. |
40ea5eb2 | 40 | |
76648510 | 41 | %description -l de.UTF-8 |
42 | Dieses Paket enthält einen Cross-gcc, der es erlaubt, auf einem | |
43 | anderem Rechner Code für Atmel AVR zu generieren. | |
40ea5eb2 | 44 | |
76648510 | 45 | %description -l pl.UTF-8 |
46 | Ten pakiet zawiera skrośny gcc pozwalający na robienie na innych | |
47 | maszynach binariów do uruchamiania na Atmel AVR. | |
40ea5eb2 | 48 | |
1c790698 | 49 | %package c++ |
fdd61bcf | 50 | Summary: C++ support for avr-gcc |
c7d51c5d | 51 | Summary(pl.UTF-8): Obsługa C++ dla avr-gcc |
fdd61bcf | 52 | Group: Development/Languages |
aaeaf91a | 53 | Requires: %{name} = %{epoch}:%{version}-%{release} |
1c790698 | 54 | |
55 | %description c++ | |
56 | This package adds C++ support to the GNU Compiler Collection for AVR. | |
57 | ||
76648510 | 58 | %description c++ -l pl.UTF-8 |
59 | Ten pakiet dodaje obsługę C++ do kompilatora gcc dla AVR. | |
1c790698 | 60 | |
40ea5eb2 WK |
61 | %prep |
62 | %setup -q -n gcc-%{version} | |
391a0dd0 ER |
63 | %patch0 -p0 |
64 | %patch1 -p0 | |
65 | %patch2 -p0 | |
66 | %patch3 -p0 | |
67 | %patch4 -p0 | |
68 | %patch5 -p0 | |
69 | %patch6 -p0 | |
40ea5eb2 WK |
70 | |
71 | %build | |
72 | rm -rf obj-%{target} | |
73 | install -d obj-%{target} | |
74 | cd obj-%{target} | |
75 | ||
76 | CFLAGS="%{rpmcflags}" \ | |
77 | CXXFLAGS="%{rpmcflags}" \ | |
fdd61bcf JB |
78 | TEXCONFIG=false \ |
79 | ../configure \ | |
40ea5eb2 WK |
80 | --prefix=%{_prefix} \ |
81 | --infodir=%{_infodir} \ | |
82 | --mandir=%{_mandir} \ | |
df3c6f23 JB |
83 | --bindir=%{_bindir} \ |
84 | --libdir=%{_libdir} \ | |
85 | --libexecdir=%{_libdir} \ | |
40ea5eb2 | 86 | --disable-shared \ |
69b7b918 | 87 | --disable-libssp \ |
1c790698 | 88 | --enable-languages="c,c++" \ |
391a0dd0 | 89 | --with-dwarf2 \ |
40ea5eb2 WK |
90 | --with-gnu-as \ |
91 | --with-gnu-ld \ | |
92 | --with-system-zlib \ | |
93 | --with-multilib \ | |
94 | --without-x \ | |
ef8212dd JB |
95 | --build=%{_target_platform} \ |
96 | --host=%{_target_platform} \ | |
40ea5eb2 WK |
97 | --target=%{target} |
98 | ||
69b7b918 | 99 | %{__make} CFLAGS_FOR_TARGET="-Os" |
40ea5eb2 WK |
100 | |
101 | %install | |
102 | rm -rf $RPM_BUILD_ROOT | |
40ea5eb2 | 103 | |
ef8212dd | 104 | %{__make} -C obj-%{target} install \ |
40ea5eb2 WK |
105 | DESTDIR=$RPM_BUILD_ROOT |
106 | ||
ef8212dd JB |
107 | # don't want it here |
108 | rm -f $RPM_BUILD_ROOT%{_libdir}/libiberty.a | |
f323cece ER |
109 | rm -rf $RPM_BUILD_ROOT%{_infodir} |
110 | rm -f $RPM_BUILD_ROOT%{_mandir}/man7/fsf-funding.7 | |
111 | rm -f $RPM_BUILD_ROOT%{_mandir}/man7/gfdl.7 | |
112 | rm -f $RPM_BUILD_ROOT%{_mandir}/man7/gpl.7 | |
113 | rm -f $RPM_BUILD_ROOT%{_datadir}/locale/*/LC_MESSAGES/{gcc,cpplib}.mo | |
114 | rm -f $RPM_BUILD_ROOT%{gcclib}/include/fixed | |
115 | rm -f $RPM_BUILD_ROOT%{gcclib}/include/README | |
116 | rm -rf $RPM_BUILD_ROOT%{gcclib}/install-tools | |
40ea5eb2 | 117 | |
ef8212dd | 118 | %if 0%{!?debug:1} |
df3c6f23 JB |
119 | # strip target libraries |
120 | %{target}-strip -g $RPM_BUILD_ROOT%{gcclib}{,/avr*}/libg*.a | |
121 | %endif | |
1c790698 | 122 | |
40ea5eb2 WK |
123 | %clean |
124 | rm -rf $RPM_BUILD_ROOT | |
125 | ||
f323cece | 126 | %files |
40ea5eb2 | 127 | %defattr(644,root,root,755) |
1c790698 | 128 | %attr(755,root,root) %{_bindir}/%{target}-gcc* |
129 | %attr(755,root,root) %{_bindir}/%{target}-cpp | |
130 | %attr(755,root,root) %{_bindir}/%{target}-gcov | |
f323cece | 131 | %dir %{arch} |
40ea5eb2 WK |
132 | %dir %{gccarch} |
133 | %dir %{gcclib} | |
134 | %attr(755,root,root) %{gcclib}/cc1 | |
40ea5eb2 | 135 | %attr(755,root,root) %{gcclib}/collect2 |
df3c6f23 | 136 | %{gcclib}/libg*.a |
f1442436 | 137 | %{gcclib}/%{target}* |
40ea5eb2 WK |
138 | %dir %{gcclib}/include |
139 | %{gcclib}/include/*.h | |
df3c6f23 | 140 | %{_mandir}/man1/%{target}-cpp.1* |
40ea5eb2 | 141 | %{_mandir}/man1/%{target}-gcc.1* |
df3c6f23 | 142 | %{_mandir}/man1/%{target}-gcov.1* |
1c790698 | 143 | |
144 | %files c++ | |
145 | %defattr(644,root,root,755) | |
146 | %attr(755,root,root) %{_bindir}/%{target}-g++ | |
147 | %attr(755,root,root) %{_bindir}/%{target}-c++ | |
148 | %attr(755,root,root) %{gcclib}/cc1plus | |
149 | %{_mandir}/man1/%{target}-g++.1* |