]> git.pld-linux.org Git - packages/crossmingw32-gcc.git/blob - crossmingw32-gcc.spec
- mass commit; now req: name = epoch:version
[packages/crossmingw32-gcc.git] / crossmingw32-gcc.spec
1 %define         DASHED_SNAP     %{nil}
2 %define         SNAP            %(echo %{DASHED_SNAP} | sed -e "s#-##g")
3 %define         GCC_VERSION     3.3
4 Summary:        Mingw32 Binary Utility Development Utilities - gcc
5 Summary(pl):    Zestaw narzêdzi mingw32 - gcc
6 Name:           crossmingw32-gcc
7 Version:        %{GCC_VERSION}
8 Release:        1
9 Epoch:          1
10 License:        GPL
11 Group:          Development/Languages
12 ExclusiveArch:  %{ix86}
13 Source0:        ftp://gcc.gnu.org/pub/gcc/releases/gcc-%{GCC_VERSION}/gcc-%{GCC_VERSION}.tar.bz2
14 # Source0-md5:  39147717455d8dba4d43d1b058ea46e2
15 Patch0:         %{name}-noioctl.patch
16 BuildRequires:  autoconf
17 BuildRequires:  bison
18 BuildRequires:  crossmingw32-binutils
19 BuildRequires:  crossmingw32-w32api
20 BuildRequires:  flex
21 Requires:       crossmingw32-binutils
22 Requires:       crossmingw32-w32api
23 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
24
25 %define         no_install_post_strip   1
26
27 %define         target          i386-mingw32
28 %define         target_platform i386-pc-mingw32
29 %define         arch            %{_prefix}/%{target}
30 %define         gccarch         %{_prefix}/lib/gcc-lib/%{target}
31 %define         gcclib          %{_prefix}/lib/gcc-lib/%{target}/%{version}
32
33 %description
34 crossmingw32 is a complete cross-compiling development system for
35 building stand-alone Microsoft Windows applications under Linux using
36 the Mingw32 build libraries. This includes a binutils, gcc with g++
37 and objc, and libstdc++, all cross targeted to i386-mingw32, along
38 with supporting Win32 libraries in 'coff' format from free sources.
39
40 This package contains cross targeted gcc.
41
42 %description -l pl
43 crossmingw32 jest kompletnym systemem do kroskompilacji, pozwalaj±cym
44 budowaæ aplikacje MS Windows pod Linuksem u¿ywaj±c bibliotek mingw32.
45 System sk³ada siê z binutils, gcc z g++ i objc, libstdc++ - wszystkie
46 generuj±ce kod dla platformy i386-mingw32, oraz z bibliotek w formacie
47 COFF.
48
49 Ten pakiet zawiera gcc generuj±ce kod dla Win32.
50
51 %package c++
52 Summary:        Mingw32 Binary Utility Development Utilities - g++
53 Summary(pl):    Zestaw narzêdzi mingw32 - g++
54 Group:          Development/Languages
55 Requires:       %{name} = %{epoch}:%{version}
56
57 %description c++
58 crossmingw32 is a complete cross-compiling development system for
59 building stand-alone Microsoft Windows applications under Linux using
60 the Mingw32 build libraries. This includes a binutils, gcc with g++
61 and objc, and libstdc++, all cross targeted to i386-mingw32, along
62 with supporting Win32 libraries in 'coff' format from free sources.
63
64 This package contains cross targeted g++ and (static) libstdc++.
65
66 %description c++ -l pl
67 crossmingw32 jest kompletnym systemem do kroskompilacji, pozwalaj±cym
68 budowaæ aplikacje MS Windows pod Linuksem u¿ywaj±c bibliotek mingw32.
69 System sk³ada siê z binutils, gcc z g++ i objc, libstdc++ - wszystkie
70 generuj±ce kod dla platformy i386-mingw32, oraz z bibliotek w formacie
71 COFF.
72
73 Ten pakiet zawiera g++ generuj±ce kod pod Win32 oraz bibliotekê
74 libstdc++.
75
76 # does this even work?
77 %package objc
78 Summary:        Mingw32 Binary Utility Development Utilities - objc
79 Summary(pl):    Zestaw narzêdzi mingw32 - objc
80 Group:          Development/Languages
81 Requires:       %{name} = %{epoch}:%{version}
82
83 %description objc
84 crossmingw32 is a complete cross-compiling development system for
85 building stand-alone Microsoft Windows applications under Linux using
86 the Mingw32 build libraries. This includes a binutils, gcc with g++
87 and objc, and libstdc++, all cross targeted to i386-mingw32, along
88 with supporting Win32 libraries in 'coff' format from free sources.
89
90 This package contains cross targeted objc.
91
92 %description objc -l pl
93 crossmingw32 jest kompletnym systemem do kroskompilacji, pozwalaj±cym
94 budowaæ aplikacje MS Windows pod Linuksem u¿ywaj±c bibliotek mingw32.
95 System sk³ada siê z binutils, gcc z g++ i objc, libstdc++ - wszystkie
96 generuj±ce kod dla platformy i386-mingw32, oraz z bibliotek w formacie
97 COFF.
98
99 Ten pakiet zawiera kompilator objc generuj±cy kod pod Win32.
100
101 # does this even work?
102 %package g77
103 Summary:        Mingw32 Binary Utility Development Utilities - g77
104 Summary(pl):    Zestaw narzêdzi mingw32 - g77
105 Group:          Development/Languages
106 Requires:       %{name} = %{epoch}:%{version}
107
108 %description g77
109 crossmingw32 is a complete cross-compiling development system for
110 building stand-alone Microsoft Windows applications under Linux using
111 the Mingw32 build libraries. This includes a binutils, gcc with g++
112 and objc, and libstdc++, all cross targeted to i386-mingw32, along
113 with supporting Win32 libraries in 'coff' format from free sources.
114
115 This package contains cross targeted g77.
116
117 %description g77 -l pl
118 crossmingw32 jest kompletnym systemem do kroskompilacji, pozwalaj±cym
119 budowaæ aplikacje MS Windows pod Linuksem u¿ywaj±c bibliotek mingw32.
120 System sk³ada siê z binutils, gcc z g++ i objc, libstdc++ - wszystkie
121 generuj±ce kod dla platformy i386-mingw32, oraz z bibliotek w formacie
122 COFF.
123
124 Ten pakiet zawiera g77 generuj±cy kod pod Win32.
125
126 # does this even work?
127 %package java
128 Summary:        Mingw32 Binary Utility Development Utilities - java
129 Summary(pl):    Zestaw narzêdzi mingw32 - java
130 Group:          Development/Languages
131 Requires:       %{name} = %{epoch}:%{version}
132
133 %description java
134 crossmingw32 is a complete cross-compiling development system for
135 building stand-alone Microsoft Windows applications under Linux using
136 the Mingw32 build libraries. This includes a binutils, gcc with g++
137 and objc, and libstdc++, all cross targeted to i386-mingw32, along
138 with supporting Win32 libraries in 'coff' format from free sources.
139
140 This package contains cross targeted java.
141
142 %description java -l pl
143 crossmingw32 jest kompletnym systemem do kroskompilacji, pozwalaj±cym
144 budowaæ aplikacje MS Windows pod Linuksem u¿ywaj±c bibliotek mingw32.
145 System sk³ada siê z binutils, gcc z g++ i objc, libstdc++ - wszystkie
146 generuj±ce kod dla platformy i386-mingw32, oraz z bibliotek w formacie
147 COFF.
148
149 Ten pakiet zawiera kompilator Javy generuj±cy kod pod Win32.
150
151 %prep
152 %setup -q -n gcc-%{version}
153 %patch -p1
154
155 %build
156 rm -rf obj-%{target_platform} && install -d obj-%{target_platform} && cd obj-%{target_platform}
157
158 CFLAGS="%{rpmcflags}" \
159 CXXFLAGS="%{rpmcflags}"  \
160 LDFLAGS="%{rpmldflags}" \
161 TEXCONFIG=false \
162 ../configure \
163         --prefix=%{_prefix} \
164         --infodir=%{_infodir} \
165         --mandir=%{_mandir} \
166         --bindir=%{arch}/bin \
167         --enable-languages="c,c++,f77,java,objc" \
168         --with-gnu-as \
169         --with-gnu-ld \
170         --with-gxx-include-dir=%{arch}/include/g++ \
171         --enable-threads \
172         --target=%{target}
173
174 #touch ../gcc/c-gperf.h
175
176 %{__make} \
177         LDFLAGS_FOR_TARGET="%{rpmldflags}" \
178         TARGET_LIBGCC2_CFLAGS="-UCROSS_COMPILE"
179
180 # build libobjc.dll for Objective C
181 # to trzeba wywo³ywaæ z katalogu obj-%{target_platform}/%{target}/libobjc
182 # ale trzeba podaæ jeszcze GCC_FOR_TARGET - a mi siê nie chce.
183 # BTW, ten dll jest do czego¶ potrzebny???
184 #
185 #make \
186 #       LDFLAGS="%{rpmldflags}" \
187 #       TARGET_LIBGCC2_CFLAGS="-UCROSS_COMPILE" \
188 #       DLLTOOL="%{target}-dlltool --as=%{target}-as" libobjc.dll
189
190 # spec files for msvcrt*.dll configurations
191 cd gcc
192 for n in msvcrt msvcrt20 msvcrt40; do
193         sed "s/crtdll/$n/g" <specs | sed "s/crt1/crt2/g" >specs.$n
194 done
195
196 %install
197 rm -rf $RPM_BUILD_ROOT
198
199 install -d $RPM_BUILD_ROOT%{_bindir}
200 install -d $RPM_BUILD_ROOT%{_datadir}
201 cd obj-%{target_platform}
202
203 %{__make} install \
204         DESTDIR=$RPM_BUILD_ROOT
205
206 cd gcc
207 install specs.msvcrt specs.msvcrt20 specs.msvcrt40 $RPM_BUILD_ROOT%{gcclib}
208 cd ../..
209
210 mv -f $RPM_BUILD_ROOT%{arch}/bin/%{target}-* $RPM_BUILD_ROOT%{_bindir}
211
212 # already in arch/lib, shouldn't be here
213 rm -f $RPM_BUILD_ROOT%{_libdir}/libiberty.a
214
215 %if 0%{!?debug:1}
216 # strip linux binaries
217 strip -R .comment -R .note \
218         `echo $RPM_BUILD_ROOT{%{_bindir}/*,%{arch}/bin/*} | grep -v gccbug` \
219         $RPM_BUILD_ROOT%{gcclib}/{cc1*,f771,jc1,jvgenmain}
220
221 # strip mingw32 libraries
222 %{target}-strip -g \
223         $RPM_BUILD_ROOT%{gcclib}/libgcc.a \
224         $RPM_BUILD_ROOT%{arch}/lib/lib*.a
225 %endif
226
227 # restore hardlinks
228 ln -f $RPM_BUILD_ROOT%{_bindir}/%{target}-{g++,c++}
229 ln -f $RPM_BUILD_ROOT%{arch}/bin/{g++,c++}
230
231 # the same... make hardlink
232 ln -f $RPM_BUILD_ROOT%{arch}/bin/gcc $RPM_BUILD_ROOT%{_bindir}/%{target}-gcc
233
234 %clean
235 rm -rf $RPM_BUILD_ROOT
236
237 %files
238 %defattr(644,root,root,755)
239 %attr(755,root,root) %{_bindir}/%{target}-gcc*
240 %attr(755,root,root) %{_bindir}/%{target}-cpp
241 %attr(755,root,root) %{_bindir}/%{target}-gcov
242 %attr(755,root,root) %{arch}/bin/gcc
243 %{arch}/lib/libiberty.a
244
245 %dir %{gccarch}
246 %dir %{gcclib}
247 %attr(755,root,root) %{gcclib}/cc1
248 %{gcclib}/libgcc.a
249 %{gcclib}/specs*
250 %{gcclib}/include
251
252 %{_mandir}/man1/%{target}-gcc.1*
253
254 %files c++
255 %defattr(644,root,root,755)
256 %attr(755,root,root) %{_bindir}/%{target}-[cg]++
257 %attr(755,root,root) %{arch}/bin/[cg]++
258 %attr(755,root,root) %{gcclib}/cc1plus
259 %{arch}/lib/libstdc++.a
260 %{arch}/lib/libstdc++.la
261 %{arch}/lib/libsupc++.a
262 %{arch}/lib/libsupc++.la
263 %{arch}/include/g++
264 %{_mandir}/man1/%{target}-g++.1*
265
266 %files objc
267 %defattr(644,root,root,755)
268 %attr(755,root,root) %{gcclib}/cc1obj
269 %{arch}/lib/libobjc.a
270 %{arch}/lib/libobjc.la
271
272 %files g77
273 %defattr(644,root,root,755)
274 %attr(755,root,root) %{_bindir}/%{target}-g77
275 %attr(755,root,root) %{gcclib}/f771
276 %{arch}/lib/libfrtbegin.a
277 %{arch}/lib/libg2c.a
278 %{arch}/lib/libg2c.la
279 %{_mandir}/man1/%{target}-g77.1*
280
281 %files java
282 %defattr(644,root,root,755)
283 %attr(755,root,root) %{_bindir}/%{target}-gcj
284 %attr(755,root,root) %{_bindir}/%{target}-gcjh
285 %attr(755,root,root) %{_bindir}/%{target}-jcf-dump
286 %attr(755,root,root) %{_bindir}/%{target}-jv-scan
287 %attr(755,root,root) %{arch}/bin/grepjar
288 %attr(755,root,root) %{arch}/bin/jar
289 %attr(755,root,root) %{gcclib}/jc1
290 %attr(755,root,root) %{gcclib}/jvgenmain
291 %{_mandir}/man1/%{target}-gcj.1*
This page took 0.059866 seconds and 4 git commands to generate.