]> git.pld-linux.org Git - packages/crossavr32-gcc.git/blame - crossavr32-gcc.spec
- pl for -libstdc++, ~cosmetics
[packages/crossavr32-gcc.git] / crossavr32-gcc.spec
CommitLineData
913b8880 1#
2# Conditional build:
3%bcond_with bootstrap # for bootstraping
4#
5Summary: Cross AVR32 GNU binary utility development utilities - gcc
6Summary(es.UTF-8): Utilitarios para desarrollo de binarios de la GNU - AVR32 gcc
7Summary(fr.UTF-8): Utilitaires de développement binaire de GNU - AVR32 gcc
8Summary(pl.UTF-8): Skrośne narzędzia programistyczne GNU dla AVR32 - gcc
9Summary(pt_BR.UTF-8): Utilitários para desenvolvimento de binários da GNU - AVR32 gcc
10Summary(tr.UTF-8): GNU geliştirme araçları - AVR32 gcc
11Name: crossavr32-gcc
12Version: 4.2.1
13Release: 0.6%{?with_bootstrap:.bootstrap}
14Epoch: 1
3ac1c30c 15License: GPL v2+
913b8880 16Group: Development/Languages
17Source0: ftp://gcc.gnu.org/pub/gcc/releases/gcc-%{version}/gcc-%{version}.tar.bz2
18# Source0-md5: cba410e6ff70f7d7f4be7a0267707fd0
19Patch0: %{name}.patch
20Patch1: %{name}-configure.patch
3ac1c30c 21URL: http://gcc.gnu.org/
913b8880 22BuildRequires: /bin/bash
23BuildRequires: autoconf
24BuildRequires: bison
25BuildRequires: crossavr32-binutils
26BuildRequires: flex
27Requires: crossavr32-binutils >= 2.17
28%{!?with_boostrap:Requires: crossavr32-uClibc}
29Requires: gcc-dirs
30BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
31
32%define target avr32-pld-linux
33%define arch %{_prefix}/%{target}
34%define gccarch %{_libdir}/gcc/%{target}
35%define gcclib %{_libdir}/gcc/%{target}/%{version}
36%define _noautostrip .*%{arch}/lib/.*
37%define _noautochrpath .*%{arch}/lib/.*
38
39%description
40This package contains a cross-gcc which allows the creation of
41binaries to be run on Atmel AVR32 on other machines.
42
43%description -l de.UTF-8
44Dieses Paket enthält einen Cross-gcc, der es erlaubt, auf einem
45anderem Rechner Code für Atmel AVR32 zu generieren.
46
47%description -l pl.UTF-8
48Ten pakiet zawiera skrośny gcc pozwalający na robienie na innych
3ac1c30c 49maszynach binariów do uruchamiania na platformie Atmel AVR.
913b8880 50
51%package c++
52Summary: C++ support for avr32-gcc
53Summary(pl.UTF-8): Obsługa C++ dla avr32-gcc
54Group: Development/Languages
55Requires: %{name} = %{epoch}:%{version}-%{release}
56
57%description c++
58This package adds C++ support to the GNU Compiler Collection for
3ac1c30c 59Atmel AVR32.
913b8880 60
61%description c++ -l pl.UTF-8
3ac1c30c
JB
62Ten pakiet dodaje obsługę C++ do kompilatora gcc dla platformy Atmel
63AVR32.
913b8880 64
65%package -n crossavr32-libgomp
66Summary: GNU OpenMP library
67Summary(pl.UTF-8): Biblioteka GNU OpenMP
68License: GPL v2+ with unlimited link permission
69Group: Libraries
70
71%description -n crossavr32-libgomp
72GNU OpenMP library.
73
74%description -n crossavr32-libgomp -l pl.UTF-8
75Biblioteka GNU OpenMP.
76
77%package -n crossavr32-libstdc++
3ac1c30c 78Summary: GNU C++ libraries
913b8880 79Summary(pl.UTF-8): Biblioteki GNU C++
80License: GPL v2+ with free software exception
81Group: Libraries
82
83%description -n crossavr32-libstdc++
84This is the GNU implementation of the standard C++ libraries, along
85with additional GNU tools. This package includes the shared libraries
86necessary to run C++ applications.
87
3ac1c30c
JB
88%description -n crossavr32-libstdc++ -l pl.UTF-8
89Implementacja GNU standardowych bibliotek C++ wraz z dodatkowymi
90narzędziami do C++. Ten pakiet zawiera biblioteki współdzielone
91potrzebne do uruchamiania aplikacji w C++.
92
913b8880 93%prep
94%setup -q -n gcc-%{version}
95%patch0 -p1
96%patch1 -p0
97
98%build
99%{__autoconf}
100
101rm -rf obj-%{target}
102install -d obj-%{target}
103cd obj-%{target}
104
105CFLAGS="%{rpmcflags}" \
106CXXFLAGS="%{rpmcflags}" \
107TEXCONFIG=false \
108../configure \
109 --prefix=%{_prefix} \
110 --infodir=%{_infodir} \
111 --mandir=%{_mandir} \
112 --bindir=%{_bindir} \
113 --libdir=%{_libdir} \
114 --libexecdir=%{_libdir} \
115 --enable-shared \
116%if %{with bootstrap}
117 --enable-languages="c" \
118 --disable-libssp \
119 --disable-threads \
120 --disable-libmudflap \
121 --disable-nls \
122 --disable-libgomp \
123%else
124 --enable-languages="c,c++" \
125 --enable-threads=posix \
126 --enable-libssp \
127 --disable-libstdcxx-pch \
128 --enable-__cxa_atexit \
129 --enable-libstdcxx-allocator=new \
130%endif
131 --with-dwarf2 \
132 --with-gnu-as \
133 --with-gnu-ld \
134 --with-system-zlib \
135 --with-multilib \
136 --without-x \
137 --build=%{_target_platform} \
138 --host=%{_target_platform} \
139 --target=%{target}
140
141
142CXXFLAGS_FOR_TARGET="-Os"
143export CXXFLAGS_FOR_TARGET
3ac1c30c
JB
144%{__make} \
145 CFLAGS_FOR_TARGET="-Os" \
146 CXXFLAGS_FOR_TARGET="-Os"
913b8880 147
148%install
149rm -rf $RPM_BUILD_ROOT
150
151%{__make} -C obj-%{target} install \
152 DESTDIR=$RPM_BUILD_ROOT
153
154# don't want it here
155rm -f $RPM_BUILD_ROOT%{_libdir}/libiberty.a
156rm -rf $RPM_BUILD_ROOT%{_infodir}
157rm -f $RPM_BUILD_ROOT%{_mandir}/man7/fsf-funding.7
158rm -f $RPM_BUILD_ROOT%{_mandir}/man7/gfdl.7
159rm -f $RPM_BUILD_ROOT%{_mandir}/man7/gpl.7
160rm -f $RPM_BUILD_ROOT%{_datadir}/locale/*/LC_MESSAGES/{gcc,cpplib}.mo
161rm -f $RPM_BUILD_ROOT%{gcclib}/include/fixed
162rm -f $RPM_BUILD_ROOT%{gcclib}/include/README
163rm -rf $RPM_BUILD_ROOT%{gcclib}/install-tools
164
165%if 0%{!?debug:1}
166# strip target libraries
167%{target}-strip --strip-debug --remove-section=.note --remove-section=.comment \
168 $RPM_BUILD_ROOT%{gcclib}{,/uc}/libg*.a \
169 $RPM_BUILD_ROOT%{arch}/lib{,/uc}/lib*.a
170%{target}-strip --strip-unneeded --remove-section=.note --remove-section=.comment \
171 $RPM_BUILD_ROOT%{arch}/lib{,/uc}/lib*.so.*.*
172%endif
173
174%clean
175rm -rf $RPM_BUILD_ROOT
176
177%files
178%defattr(644,root,root,755)
179%attr(755,root,root) %{_bindir}/%{target}-gcc*
180%attr(755,root,root) %{_bindir}/%{target}-cpp
181%attr(755,root,root) %{_bindir}/%{target}-gcov
182%dir %{gccarch}
183%dir %{gcclib}
184%attr(755,root,root) %{gcclib}/cc1
185%attr(755,root,root) %{gcclib}/collect2
186%{gcclib}/libg*.a
187%{gcclib}/crt*.o
188%{gcclib}/uc
189%dir %{gcclib}/include
190%{gcclib}/include/*.h
191%{_mandir}/man1/%{target}-cpp.1*
192%{_mandir}/man1/%{target}-gcc.1*
193%{_mandir}/man1/%{target}-gcov.1*
194
195%if %{without bootstrap}
196%files c++
197%defattr(644,root,root,755)
198%attr(755,root,root) %{_bindir}/%{target}-g++
199%attr(755,root,root) %{_bindir}/%{target}-c++
200%attr(755,root,root) %{gcclib}/cc1plus
201%{_mandir}/man1/%{target}-g++.1*
202
203%files -n crossavr32-libgomp
204%defattr(644,root,root,755)
205%{arch}/lib/libgomp*
206%{arch}/lib/uc/libgomp*
207
208%files -n crossavr32-libstdc++
209%defattr(644,root,root,755)
210%{arch}/lib/libstdc*
211%{arch}/lib/libsupc*
212%{arch}/lib/uc/libstdc*
213%{arch}/lib/uc/libsupc*
214%{arch}/include/c++
913b8880 215%endif
This page took 0.137001 seconds and 4 git commands to generate.