]> git.pld-linux.org Git - packages/crossmingw32-gcc.git/blob - crossmingw32-gcc.spec
- updated to 10.5.0
[packages/crossmingw32-gcc.git] / crossmingw32-gcc.spec
1 #
2 # Conditional build:
3 %bcond_with     bootstrap       # bootstrap build (using binary w32api/mingwrt, only C/C++, no gomp)
4 %bcond_without  pthreads        # POSIX threads support (needed for GOMP and C++ 11 thread/mutex support)
5 %bcond_without  gomp            # OpenMP libraries
6 #
7 %if %{with bootstrap}
8 %undefine       with_pthreads
9 %endif
10 %if %{without pthreads}
11 %undefine       with_gomp
12 %endif
13 Summary:        Cross MinGW32 GNU binary utility development utilities - gcc
14 Summary(es.UTF-8):      Utilitarios para desarrollo de binarios de la GNU - MinGW32 gcc
15 Summary(fr.UTF-8):      Utilitaires de développement binaire de GNU - MinGW32 gcc
16 Summary(pl.UTF-8):      Skrośne narzędzia programistyczne GNU dla MinGW32 - gcc
17 Summary(pt_BR.UTF-8):   Utilitários para desenvolvimento de binários da GNU - MinGW32 gcc
18 Summary(tr.UTF-8):      GNU geliştirme araçları - MinGW32 gcc
19 Name:           crossmingw32-gcc
20 Version:        10.5.0
21 Release:        1
22 Epoch:          1
23 License:        GPL v3+
24 Group:          Development/Languages
25 Source0:        https://ftp.gnu.org/gnu/gcc/gcc-%{version}/gcc-%{version}.tar.xz
26 # Source0-md5:  c7d1958570fbd1cd859b015774b9987a
27 %define         w32api_ver      5.4.2
28 #Source1Download: https://osdn.net/projects/mingw/releases/
29 Source1:        https://osdn.net/projects/mingw/downloads/74926/w32api-%{w32api_ver}-mingw32-dev.tar.xz
30 # Source1-md5:  88b0dc6185079e60d83bdbaec92028b8
31 %define         mingw32_ver     5.4.2
32 #Source2Download: https://osdn.net/projects/mingw/releases/
33 Source2:        https://osdn.net/projects/mingw/downloads/74925/mingwrt-%{mingw32_ver}-mingw32-dev.tar.xz
34 # Source2-md5:  d8dceb05b85602eec82eac4e11d5c027
35 Source3:        gcc-optimize-la.pl
36 #Patch100:      gcc-branch.diff
37 Patch0:         %{name}-buildsystem1.patch
38 Patch1:         %{name}-buildsystem2.patch
39 Patch2:         %{name}-lfs.patch
40 Patch3:         gcc-mingw32.patch
41 Patch4:         gcc-build-libvtv.patch
42 Patch5:         gcc-pthreads-w32.patch
43 URL:            http://gcc.gnu.org/
44 BuildRequires:  autoconf >= 2.64
45 BuildRequires:  automake >= 1:1.11.1
46 BuildRequires:  bison
47 BuildRequires:  crossmingw32-binutils >= 2.30
48 %{?with_pthreads:BuildRequires: crossmingw32-pthreads-w32}
49 %if %{without bootstrap}
50 BuildRequires:  crossmingw32-runtime >= 3.5
51 BuildRequires:  crossmingw32-w32api >= 1:5.4.2-3
52 %endif
53 BuildRequires:  flex >= 2.5.4
54 BuildRequires:  gettext-tools >= 0.14.5
55 BuildRequires:  gmp-devel >= 4.3.2
56 BuildRequires:  isl-devel >= 0.15
57 BuildRequires:  libmpc-devel >= 0.8.1
58 BuildRequires:  libstdc++-devel
59 BuildRequires:  mpfr-devel >= 3.1.0
60 BuildRequires:  perl-tools-pod
61 BuildRequires:  tar >= 1:1.22
62 BuildRequires:  texinfo >= 4.7
63 BuildRequires:  xz
64 BuildRequires:  zlib-devel
65 BuildConflicts: pdksh < 5.2.14-50
66 Requires:       crossmingw32-binutils >= 2.30
67 Requires:       gcc-dirs
68 Requires:       gmp >= 4.3.2
69 Requires:       isl >= 0.15
70 Requires:       libmpc >= 0.8.1
71 Requires:       mpfr >= 3.1.0
72 # java support dropped from gcc 7+
73 Obsoletes:      crossmingw32-java < 1:7
74 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
75
76 %define         target          i386-mingw32
77 %define         sysprefix       /usr
78 %define         archprefix      %{sysprefix}/%{target}
79 %define         archbindir      %{archprefix}/bin
80 %define         archincludedir  %{archprefix}/include
81 %define         archlibdir      %{archprefix}/lib
82 %define         gccarchdir      %{_libdir}/gcc/%{target}
83 %define         gcclibdir       %{gccarchdir}/%{version}
84 %define         _dlldir         /usr/share/wine/windows/system
85
86 %define         _noautostrip    .*/lib.*\\.a
87
88 %define         _enable_debug_packages 0
89
90 # functions with printf format attribute but with special parser and also
91 # receiving non constant format strings
92 %define         Werror_cflags   %{nil}
93 %define         _ssp_cflags     %{nil}
94 # -fPIC is not valid for target platform
95 %define         filterout_c     -fPIC
96
97 %description
98 crossmingw32 is a complete cross-compiling development system for
99 building stand-alone Microsoft Windows applications under Linux using
100 the MinGW32 build libraries. This includes a binutils, gcc with g++
101 and objc, and libstdc++, all cross targeted to i386-mingw32, along
102 with supporting Win32 libraries in 'coff' format from free sources.
103
104 This package contains cross targeted gcc.
105
106 %description -l de.UTF-8
107 Dieses Paket enthält einen Cross-gcc, der es erlaubt, auf einem
108 anderem Rechner Code für Win32 zu generieren.
109
110 %description -l pl.UTF-8
111 crossmingw32 jest kompletnym systemem do kompilacji skrośnej,
112 pozwalającym budować aplikacje MS Windows pod Linuksem używając
113 bibliotek MinGW32. System składa się z binutils, gcc z g++ i objc,
114 libstdc++ - wszystkie generujące kod dla platformy i386-mingw32, oraz
115 z bibliotek w formacie COFF.
116
117 Ten pakiet zawiera gcc generujące skrośnie kod dla Win32.
118
119 %package -n crossmingw32-libgcc-dll
120 Summary:        libgcc DLL library for Windows
121 Summary(pl.UTF-8):      Biblioteka DLL libgcc dla Windows
122 Group:          Applications/Emulators
123 Requires:       wine
124
125 %description -n crossmingw32-libgcc-dll
126 libgcc DLL library for Windows.
127
128 %description -n crossmingw32-libgcc-dll -l pl.UTF-8
129 Biblioteka DLL libgcc dla Windows.
130
131 %package -n crossmingw32-libatomic
132 Summary:        The GNU Atomic library - cross MinGW32 version
133 Summary(pl.UTF-8):      Biblioteka GNU Atomic - wersja skrośna MinGW32
134 License:        GPL v3+ with GCC Runtime Library Exception v3.1
135 Group:          Development/Libraries
136 Requires:       %{name} = %{epoch}:%{version}-%{release}
137
138 %description -n crossmingw32-libatomic
139 This package contains cross MinGW32 version of the GNU Atomic library
140 which is a GCC support library for atomic operations not supported by
141 hardware.
142
143 %description -n crossmingw32-libatomic -l pl.UTF-8
144 Ten pakiet zawiera wersję skrośną MinGW32 biblioteki GNU Atomic,
145 będącej biblioteką GCC, wspierającej operacje atomowe na sprzęcie ich
146 nie obsługującym.
147
148 %package -n crossmingw32-libatomic-static
149 Summary:        The GNU Atomic static library - cross MinGW32 version
150 Summary(pl.UTF-8):      Statyczna biblioteka GNU Atomic - wersja skrośna MinGW32
151 License:        GPL v3+ with GCC Runtime Library Exception v3.1
152 Group:          Development/Libraries
153 Requires:       crossmingw32-libatomic = %{epoch}:%{version}-%{release}
154
155 %description -n crossmingw32-libatomic-static
156 The GNU Atomic static library - cross MinGW32 version.
157
158 %description -n crossmingw32-libatomic-static -l pl.UTF-8
159 Statyczna biblioteka GNU Atomic - wersja skrośna MinGW32.
160
161 %package -n crossmingw32-libatomic-dll
162 Summary:        DLL GNU Atomic library for Windows
163 Summary(pl.UTF-8):      Biblioteka DLL GNU Atomic dla Windows
164 License:        GPL v3+ with GCC Runtime Library Exception v3.1
165 Group:          Applications/Emulators
166 Requires:       wine
167
168 %description -n crossmingw32-libatomic-dll
169 DLL GNU Atomic library for Windows.
170
171 %description -n crossmingw32-libatomic-dll -l pl.UTF-8
172 Biblioteka DLL GNU Atomic dla Windows.
173
174 %package -n crossmingw32-libgomp
175 Summary:        GNU OpenMP library - cross MinGW32 version
176 Summary(pl.UTF-8):      Biblioteka GNU OpenMP - wersja skrośna MinGW32
177 License:        GPL v3+ with GCC Runtime Library Exception v3.1
178 Group:          Development/Libraries
179 Requires:       %{name} = %{epoch}:%{version}-%{release}
180
181 %description -n crossmingw32-libgomp
182 This package contains cross MinGW32 version of GNU OpenMP library.
183
184 %description -n crossmingw32-libgomp -l pl.UTF-8
185 Ten pakiet zawiera wersję skrośną MinGW32 biblioteki GNU OpenMP.
186
187 %package -n crossmingw32-libgomp-static
188 Summary:        Static GNU OpenMP library - cross MinGW32 version
189 Summary(pl.UTF-8):      Statyczna biblioteka GNU OpenMP - wersja skrośna MinGW32
190 License:        GPL v3+ with GCC Runtime Library Exception v3.1
191 Group:          Development/Libraries
192 Requires:       crossmingw32-libgomp = %{epoch}:%{version}-%{release}
193
194 %description -n crossmingw32-libgomp-static
195 Static GNU OpenMP library - cross MinGW32 version.
196
197 %description -n crossmingw32-libgomp-static -l pl.UTF-8
198 Statyczna biblioteka GNU OpenMP - wersja skrośna MinGW32.
199
200 %package -n crossmingw32-libgomp-dll
201 Summary:        DLL GNU OpenMP library for Windows
202 Summary(pl.UTF-8):      Biblioteka DLL GNU OpenMP dla Windows
203 License:        GPL v3+ with GCC Runtime Library Exception v3.1
204 Group:          Applications/Emulators
205 Requires:       crossmingw32-libgcc-dll = %{epoch}:%{version}-%{release}
206 Requires:       crossmingw32-pthreads-w32-dll
207
208 %description -n crossmingw32-libgomp-dll
209 DLL GNU OpenMP library for Windows.
210
211 %description -n crossmingw32-libgomp-dll -l pl.UTF-8
212 Biblioteka DLL GNU OpenMP dla Windows.
213
214 %package -n crossmingw32-libvtv
215 Summary:        The Virtual Table Verification library - cross MinGW32 version
216 Summary(pl.UTF-8):      Biblioteka Virtual Table Verification do weryfikacji tablicy wirtualnej - wersja skrośna MinGW32
217 License:        GPL v3+ with GCC Runtime Library Exception v3.1
218 Group:          Development/Libraries
219 URL:            https://gcc.gnu.org/wiki/vtv
220 Requires:       %{name} = %{epoch}:%{version}-%{release}
221
222 %description -n crossmingw32-libvtv
223 This package contains cross MinGW32 version of the Virtual Table
224 Verification library which is used for -fvtable-verify=...
225 instrumented programs.
226
227 %description -n crossmingw32-libvtv -l pl.UTF-8
228 Ten pakiet zawiera wersję skrośną MinGW32 biblioteki Virtual Table
229 Verification, służącej do weryfikacji tablicy wirtualnej w programach
230 kompilowanych z opcją -fvtable-verify=....
231
232 %package -n crossmingw32-libvtv-static
233 Summary:        The Virtual Table Verification static library - cross MinGW32 version
234 Summary(pl.UTF-8):      Statyczna biblioteka Virtual Table Verification - wersja skrośna MinGW32
235 License:        GPL v3+ with GCC Runtime Library Exception v3.1
236 Group:          Development/Libraries
237 URL:            https://gcc.gnu.org/wiki/vtv
238 Requires:       crossmingw32-libvtv = %{epoch}:%{version}-%{release}
239
240 %description -n crossmingw32-libvtv-static
241 The Virtual Table Verification static library - cross MinGW32 version.
242
243 %description -n crossmingw32-libvtv-static -l pl.UTF-8
244 Statyczna biblioteka Virtual Table Verification - wersja skrośna
245 MinGW32.
246
247 %package -n crossmingw32-libvtv-dll
248 Summary:        DLL Virtual Table Verification libraries for Windows
249 Summary(pl.UTF-8):      Biblioteki DLL Virtual Table Verification dla Windows
250 License:        GPL v3+ with GCC Runtime Library Exception v3.1
251 Group:          Applications/Emulators
252 URL:            https://gcc.gnu.org/wiki/vtv
253 Requires:       crossmingw32-libgcc-dll = %{epoch}:%{version}-%{release}
254
255 %description -n crossmingw32-libvtv-dll
256 DLL Virtual Table Verification libraries for Windows.
257
258 %description -n crossmingw32-libvtv-dll -l pl.UTF-8
259 Biblioteki DLL Virtual Table Verification dla Windows.
260
261 %package c++
262 Summary:        MinGW32 binary utility development utilities - g++
263 Summary(pl.UTF-8):      Zestaw narzędzi MinGW32 - g++
264 Group:          Development/Languages
265 Requires:       %{name} = %{epoch}:%{version}-%{release}
266
267 %description c++
268 crossmingw32 is a complete cross-compiling development system for
269 building stand-alone Microsoft Windows applications under Linux using
270 the MinGW32 build libraries. This includes a binutils, gcc with g++
271 and objc, and libstdc++, all cross targeted to i386-mingw32, along
272 with supporting Win32 libraries in 'coff' format from free sources.
273
274 This package contains cross targeted g++ and (static) libstdc++.
275
276 %description c++ -l pl.UTF-8
277 crossmingw32 jest kompletnym systemem do kompilacji skrośnej,
278 pozwalającym budować aplikacje MS Windows pod Linuksem używając
279 bibliotek MinGW32. System składa się z binutils, gcc z g++ i objc,
280 libstdc++ - wszystkie generujące kod dla platformy i386-mingw32, oraz
281 z bibliotek w formacie COFF.
282
283 Ten pakiet zawiera g++ generujące kod pod Win32 oraz bibliotekę
284 libstdc++.
285
286 %package -n crossmingw32-libstdc++-static
287 Summary:        Static standard C++ library - cross MinGW32 version
288 Summary(pl.UTF-8):      Statyczna biblioteka standardowa C++ - wersja skrośna MinGW32
289 Group:          Development/Libraries
290 Requires:       %{name}-c++ = %{epoch}:%{version}-%{release}
291
292 %description -n crossmingw32-libstdc++-static
293 Static standard C++ library - cross MinGW32 version.
294
295 %description -n crossmingw32-libstdc++-static -l pl.UTF-8
296 Statyczna biblioteka standardowa C++ - wersja skrośna MinGW32.
297
298 %package -n crossmingw32-libstdc++-dll
299 Summary:        libstdc++ DLL library for Windows
300 Summary(pl.UTF-8):      Biblioteka DLL libstdc++ dla Windows
301 Group:          Applications/Emulators
302 Requires:       crossmingw32-libgcc-dll = %{epoch}:%{version}-%{release}
303 Requires:       wine
304
305 %description -n crossmingw32-libstdc++-dll
306 libstdc++ DLL library for Windows.
307
308 %description -n crossmingw32-libstdc++-dll -l pl.UTF-8
309 Biblioteka DLL libstdc++ dla Windows.
310
311 %package objc
312 Summary:        MinGW32 binary utility development utilities - objc
313 Summary(pl.UTF-8):      Zestaw narzędzi MinGW32 - objc
314 Group:          Development/Languages
315 Requires:       %{name} = %{epoch}:%{version}-%{release}
316
317 %description objc
318 crossmingw32 is a complete cross-compiling development system for
319 building stand-alone Microsoft Windows applications under Linux using
320 the MinGW32 build libraries. This includes a binutils, gcc with g++
321 and objc, and libstdc++, all cross targeted to i386-mingw32, along
322 with supporting Win32 libraries in 'coff' format from free sources.
323
324 This package contains cross targeted objc compiler.
325
326 %description objc -l pl.UTF-8
327 crossmingw32 jest kompletnym systemem do kompilacji skrośnej,
328 pozwalającym budować aplikacje MS Windows pod Linuksem używając
329 bibliotek MinGW32. System składa się z binutils, gcc z g++ i objc,
330 libstdc++ - wszystkie generujące kod dla platformy i386-mingw32, oraz
331 z bibliotek w formacie COFF.
332
333 Ten pakiet zawiera kompilator objc generujący kod pod Win32.
334
335 %package objc++
336 Summary:        MinGW32 binary utility development utilities - objc++
337 Summary(pl.UTF-8):      Zestaw narzędzi MinGW32 - objc++
338 Group:          Development/Languages
339 Requires:       %{name}-objc = %{epoch}:%{version}-%{release}
340
341 %description objc++
342 crossmingw32 is a complete cross-compiling development system for
343 building stand-alone Microsoft Windows applications under Linux using
344 the MinGW32 build libraries. This includes a binutils, gcc with g++
345 and objc, and libstdc++, all cross targeted to i386-mingw32, along
346 with supporting Win32 libraries in 'coff' format from free sources.
347
348 This package contains Objective C++ support.
349
350 %description objc++ -l pl.UTF-8
351 crossmingw32 jest kompletnym systemem do kompilacji skrośnej,
352 pozwalającym budować aplikacje MS Windows pod Linuksem używając
353 bibliotek MinGW32. System składa się z binutils, gcc z g++ i objc,
354 libstdc++ - wszystkie generujące kod dla platformy i386-mingw32, oraz
355 z bibliotek w formacie COFF.
356
357 Ten pakiet zawiera obsługę języka Objective C++.
358
359 %package -n crossmingw32-libobjc-static
360 Summary:        Static Objective C library - cross MinGW32 version
361 Summary(pl.UTF-8):      Statyczna biblioteka Objective C - wersja skrośna MinGW32
362 Group:          Development/Libraries
363 Requires:       %{name}-objc = %{epoch}:%{version}-%{release}
364
365 %description -n crossmingw32-libobjc-static
366 Static Objective C library - cross MinGW32 version.
367
368 %description -n crossmingw32-libobjc-static -l pl.UTF-8
369 Statyczna biblioteka Objective C - wersja skrośna MinGW32.
370
371 %package -n crossmingw32-libobjc-dll
372 Summary:        libobjc DLL library for Windows
373 Summary(pl.UTF-8):      Biblioteka DLL libobjc dla Windows
374 Group:          Applications/Emulators
375 Requires:       crossmingw32-libgcc-dll = %{epoch}:%{version}-%{release}
376 Requires:       wine
377
378 %description -n crossmingw32-libobjc-dll
379 libobjc DLL library for Windows.
380
381 %description -n crossmingw32-libobjc-dll -l pl.UTF-8
382 Biblioteka DLL libobjc dla Windows.
383
384 %package fortran
385 Summary:        MinGW32 binary utility development utilities - Fortran
386 Summary(pl.UTF-8):      Zestaw narzędzi MinGW32 - Fortran
387 Group:          Development/Languages
388 Requires:       %{name} = %{epoch}:%{version}-%{release}
389 Requires:       crossmingw32-libquadmath = %{epoch}:%{version}-%{release}
390 Obsoletes:      crossmingw32-gcc-g77 < 1:4
391
392 %description fortran
393 crossmingw32 is a complete cross-compiling development system for
394 building stand-alone Microsoft Windows applications under Linux using
395 the MinGW32 build libraries. This includes a binutils, gcc with g++
396 and objc, and libstdc++, all cross targeted to i386-mingw32, along
397 with supporting Win32 libraries in 'coff' format from free sources.
398
399 This package contains cross targeted Fortran compiler.
400
401 %description fortran -l pl.UTF-8
402 crossmingw32 jest kompletnym systemem do kompilacji skrośnej,
403 pozwalającym budować aplikacje MS Windows pod Linuksem używając
404 bibliotek MinGW32. System składa się z binutils, gcc z g++ i objc,
405 libstdc++ - wszystkie generujące kod dla platformy i386-mingw32, oraz
406 z bibliotek w formacie COFF.
407
408 Ten pakiet zawiera kompilator Fortranu generujący kod pod Win32.
409
410 %package -n crossmingw32-libgfortran-static
411 Summary:        Static Fortran library - cross MinGW32 version
412 Summary(pl.UTF-8):      Statyczna biblioteka Fortranu - wersja skrośna MinGW32
413 Group:          Development/Libraries
414 Requires:       %{name}-fortran = %{epoch}:%{version}-%{release}
415
416 %description -n crossmingw32-libgfortran-static
417 Static Fortran library - cross MinGW32 version.
418
419 %description -n crossmingw32-libgfortran-static -l pl.UTF-8
420 Statyczna biblioteka Fortranu - wersja skrośna MinGW32.
421
422 %package -n crossmingw32-libgfortran-dll
423 Summary:        libgfortran DLL library for Windows
424 Summary(pl.UTF-8):      Biblioteka DLL libgfortran dla Windows
425 Group:          Applications/Emulators
426 Requires:       crossmingw32-libquadmath-dll
427
428 %description -n crossmingw32-libgfortran-dll
429 libgfortran DLL library for Windows.
430
431 %description -n crossmingw32-libgfortran-dll -l pl.UTF-8
432 Biblioteka DLL libgfortran dla Windows.
433
434 %package -n crossmingw32-libquadmath
435 Summary:        GCC __float128 support library - cross MinGW32 version
436 Summary(pl.UTF-8):      Biblioteka do obsługi typu __float128 - wersja skrośna MinGW32
437 License:        GPL v2+ with linking exception
438 Group:          Development/Libraries
439 Requires:       %{name} = %{epoch}:%{version}-%{release}
440
441 %description -n crossmingw32-libquadmath
442 This package contains cross MinGW32 version of GCC support library
443 which is needed for __float128 math support and for Fortran REAL*16
444 support.
445
446 %description -n crossmingw32-libquadmath -l pl.UTF-8
447 Ten pakiet zawiera wersję skrośną MinGW32 biblioteki GCC do obsługi
448 operacji matematycznych na zmiennych typu __float128 oraz typu REAL*16
449 w Fortranie.
450
451 %package -n crossmingw32-libquadmath-static
452 Summary:        Static GCC __float128 support library - cross MinGW32 version
453 Summary(pl.UTF-8):      Biblioteka statyczna GCC do obsługi typu __float128 - wersja skrośna MinGW32
454 License:        GPL v2+ with linking exception
455 Group:          Development/Libraries
456 Requires:       crossmingw32-libquadmath = %{epoch}:%{version}-%{release}
457
458 %description -n crossmingw32-libquadmath-static
459 Static GCC __float128 support library - cross MinGW32 version.
460
461 %description -n crossmingw32-libquadmath-static -l pl.UTF-8
462 Biblioteka statyczna GCC do obsługi typu __float128 - wersja skrośna
463 MinGW32.
464
465 %package -n crossmingw32-libquadmath-dll
466 Summary:        DLL GCC __float128 support library for Windows
467 Summary(pl.UTF-8):      Biblioteka DLL GCC do obsługi typu __float128 dla Windows
468 License:        GPL v2+ with linking exception
469 Group:          Applications/Emulators
470 Requires:       wine
471
472 %description -n crossmingw32-libquadmath-dll
473 DLL GCC __float128 support library for Windows.
474
475 %description -n crossmingw32-libquadmath-dll -l pl.UTF-8
476 Biblioteka DLL GCC do obsługi typu __float128 dla Windows.
477
478 %prep
479 %setup -q -n gcc-%{version}
480 #patch100 -p0
481 %patch0 -p1
482 %patch2 -p1
483 %patch3 -p1
484 %patch4 -p1
485 %patch5 -p1
486
487 %if %{with bootstrap}
488 # note: "winsup" dirs are special, handled by gcc's configure
489 install -d winsup/{mingw,w32api}
490 tar xf %{SOURCE1} -C winsup/w32api
491 tar xf %{SOURCE2} -C winsup/mingw
492 # required by _mingw.h
493 touch winsup/mingw/include/features.h
494 %endif
495
496 # override snapshot version.
497 echo %{version} > gcc/BASE-VER
498 echo "release" > gcc/DEV-PHASE
499
500 %build
501 cd libvtv
502 %{__aclocal} -I .. -I ../config
503 %{__autoconf}
504 %{__automake}
505 cd ..
506
507 rm -rf builddir && install -d builddir && cd builddir
508 %if %{with bootstrap}
509 install -d %{target}/winsup
510 ln -sf ../../../winsup/mingw/lib %{target}/winsup/mingw
511 ln -sf ../../../winsup/w32api %{target}/winsup/w32api
512 WINSUPDIR=$(cd ..; pwd)/winsup
513 %endif
514
515 # note: libbacktrace requires at least i486 now
516 CC="%{__cc}" \
517 CFLAGS="%{rpmcflags}" \
518 CXXFLAGS="%{rpmcxxflags}" \
519 TEXCONFIG=false \
520 CFLAGS_FOR_TARGET="-O2 -march=i486" \
521 CXXFLAGS_FOR_TARGET="-O2 -march=i486" \
522 ../configure \
523         --prefix=%{sysprefix} \
524         --bindir=%{archbindir} \
525         --libdir=%{_libdir} \
526         --includedir=%{archincludedir} \
527         --libexecdir=%{_libdir} \
528         --infodir=%{_infodir} \
529         --mandir=%{_mandir} \
530         --with-bugurl="http://bugs.pld-linux.org" \
531         --with-build-time-tools=%{archbindir} \
532         %{!?with_bootstrap:--with-headers=%{archincludedir}} \
533         --with-libs=%{!?with_bootstrap:%{archlibdir}}%{?with_bootstrap:${WINSUPDIR}/mingw/lib} \
534         --with-demangler-in-ld \
535         --with-dwarf2 \
536         --with-gnu-as \
537         --with-gnu-ld \
538         --with-long-double-128 \
539         --with-pkgversion="PLD-Linux" \
540         --enable-c99 \
541         --enable-fully-dynamic-string \
542         --disable-isl-version-check \
543         --enable-languages="c,c++%{!?with_bootstrap:,fortran,objc,obj-c++}" \
544         %{?with_bootstrap:--disable-libatomic} \
545         --disable-libcc1 \
546         --enable-libgomp%{!?with_gomp:=no} \
547         %{?with_bootstrap:--disable-libquadmath} \
548         --disable-libssp \
549         --enable-libstdcxx-allocator=new \
550         %{?with_bootstrap:--disable-libvtv} \
551         --enable-linker-build-id \
552         --enable-long-long \
553         --enable-lto \
554         --disable-multilib \
555         --disable-nls \
556         --enable-shared \
557         --disable-sjlj-exceptions \
558         --disable-symvers \
559         --enable-threads%{?with_pthreads:=posix} \
560         --disable-werror \
561         --disable-win32-registry \
562         --target=%{target}
563
564 cd ..
565 %{__make} -C builddir all-host
566 patch -p1 <%{PATCH1}
567 %{__make} -C builddir
568
569 %install
570 rm -rf $RPM_BUILD_ROOT
571 install -d $RPM_BUILD_ROOT%{_bindir}
572
573 %{__make} -C builddir install \
574         DESTDIR=$RPM_BUILD_ROOT
575
576 %{__mv} $RPM_BUILD_ROOT%{gcclibdir}/include-fixed/{limits,syslimits}.h $RPM_BUILD_ROOT%{gcclibdir}/include
577 %{__rm} -r $RPM_BUILD_ROOT%{gcclibdir}/include-fixed
578 %{__rm} -r $RPM_BUILD_ROOT%{gcclibdir}/install-tools
579
580 # these must be symlinks: gcclibdir is calculated relatively to real binary path
581 ln -sf %{archbindir}/%{target}-gcc $RPM_BUILD_ROOT%{_bindir}/%{target}-gcc
582 ln -sf %{archbindir}/%{target}-g++ $RPM_BUILD_ROOT%{_bindir}/%{target}-g++
583 ln -sf %{archbindir}/%{target}-cpp $RPM_BUILD_ROOT%{_bindir}/%{target}-cpp
584 ln -sf %{archbindir}/%{target}-gcov $RPM_BUILD_ROOT%{_bindir}/%{target}-gcov
585 ln -sf %{archbindir}/%{target}-gcov-dump $RPM_BUILD_ROOT%{_bindir}/%{target}-gcov-dump
586 ln -sf %{archbindir}/%{target}-gcov-tool $RPM_BUILD_ROOT%{_bindir}/%{target}-gcov-tool
587 ln -sf %{archbindir}/%{target}-gfortran $RPM_BUILD_ROOT%{_bindir}/%{target}-gfortran
588 ln -sf %{archbindir}/%{target}-lto-dump $RPM_BUILD_ROOT%{_bindir}/%{target}-lto-dump
589
590 # DLLs
591 install -d $RPM_BUILD_ROOT%{_dlldir}
592 %{__mv} $RPM_BUILD_ROOT%{archlibdir}/*.dll $RPM_BUILD_ROOT%{_dlldir}
593 if [ ! -f $RPM_BUILD_ROOT%{_dlldir}/libgcc_s_dw2-1.dll ]; then
594         echo "libgcc DLL not installed?"
595         install builddir/i386-mingw32/libgcc/shlib/libgcc_s_dw2-1.dll $RPM_BUILD_ROOT%{_dlldir}
596 fi
597
598 %if 0%{!?debug:1}
599 %{target}-strip --strip-unneeded -R.comment -R.note $RPM_BUILD_ROOT%{_dlldir}/*.dll
600 %{target}-strip -g -R.comment -R.note $RPM_BUILD_ROOT%{archlibdir}/lib*.a
601 %{target}-strip -g -R.comment -R.note $RPM_BUILD_ROOT%{gcclibdir}/lib*.a
602 %endif
603
604 # avoid -L poisoning in *.la
605 %if %{without bootstrap}
606 for f in libatomic.la libgfortran.la libobjc.la libquadmath.la %{?with_gomp:libgomp.la} ; do
607         file="$RPM_BUILD_ROOT%{archlibdir}/$f"
608         %{__perl} %{SOURCE3} "$file" %{gcclibdir} >"${file}.fixed"
609         %{__mv} "${file}.fixed" "$file"
610 done
611 for f in libcaf_single.la ; do
612         file="$RPM_BUILD_ROOT%{gcclibdir}/$f"
613         %{__perl} %{SOURCE3} "$file" %{gcclibdir} >"${file}.fixed"
614         %{__mv} "${file}.fixed" "$file"
615 done
616 %endif
617
618 # for pretty-printers see native gcc
619 %{__rm} $RPM_BUILD_ROOT%{archlibdir}/libstdc++.dll.a-gdb.py
620 %{__rm} -r $RPM_BUILD_ROOT%{_datadir}/gcc-%{version}/python/libstdcxx
621 # no plugin development for mingw32 (at least for now)
622 %{__rm} $RPM_BUILD_ROOT%{gcclibdir}/liblto_plugin.la
623 %{__rm} -r $RPM_BUILD_ROOT%{gcclibdir}/plugin
624 # already in native gcc
625 %{__rm} -r $RPM_BUILD_ROOT%{_infodir}
626 # common FSF man pages
627 %{__rm} $RPM_BUILD_ROOT%{_mandir}/man7/{fsf-funding,gfdl,gpl}.7
628
629 %clean
630 rm -rf $RPM_BUILD_ROOT
631
632 %files
633 %defattr(644,root,root,755)
634 %attr(755,root,root) %{_bindir}/%{target}-gcc
635 %attr(755,root,root) %{_bindir}/%{target}-cpp
636 %attr(755,root,root) %{_bindir}/%{target}-gcov
637 %attr(755,root,root) %{_bindir}/%{target}-gcov-dump
638 %attr(755,root,root) %{_bindir}/%{target}-gcov-tool
639 %attr(755,root,root) %{_bindir}/%{target}-lto-dump
640 %attr(755,root,root) %{archbindir}/%{target}-cpp
641 %attr(755,root,root) %{archbindir}/%{target}-gcc
642 %attr(755,root,root) %{archbindir}/%{target}-gcc-%{version}
643 %attr(755,root,root) %{archbindir}/%{target}-gcc-ar
644 %attr(755,root,root) %{archbindir}/%{target}-gcc-nm
645 %attr(755,root,root) %{archbindir}/%{target}-gcc-ranlib
646 %attr(755,root,root) %{archbindir}/%{target}-gcov
647 %attr(755,root,root) %{archbindir}/%{target}-gcov-dump
648 %attr(755,root,root) %{archbindir}/%{target}-gcov-tool
649 %attr(755,root,root) %{archbindir}/%{target}-lto-dump
650 %{archlibdir}/libgcc_s.a
651 %dir %{gccarchdir}
652 %dir %{gcclibdir}
653 %attr(755,root,root) %{gcclibdir}/cc1
654 %attr(755,root,root) %{gcclibdir}/collect2
655 %attr(755,root,root) %{gcclibdir}/lto-wrapper
656 %attr(755,root,root) %{gcclibdir}/lto1
657 %attr(755,root,root) %{gcclibdir}/liblto_plugin.so*
658 %{gcclibdir}/libgcc.a
659 %{gcclibdir}/libgcc_eh.a
660 %{gcclibdir}/libgcov.a
661 %{gcclibdir}/crtbegin.o
662 %{gcclibdir}/crtend.o
663 %{gcclibdir}/crtfastmath.o
664 %dir %{gcclibdir}/include
665 %{gcclibdir}/include/*.h
666 %{_mandir}/man1/%{target}-cpp.1*
667 %{_mandir}/man1/%{target}-gcc.1*
668 %{_mandir}/man1/%{target}-gcov.1*
669 %{_mandir}/man1/%{target}-gcov-dump.1*
670 %{_mandir}/man1/%{target}-gcov-tool.1*
671 %{_mandir}/man1/%{target}-lto-dump.1*
672
673 %files -n crossmingw32-libgcc-dll
674 %defattr(644,root,root,755)
675 %{_dlldir}/libgcc_s_dw2-1.dll
676
677 %if %{without bootstrap}
678 %files -n crossmingw32-libatomic
679 %defattr(644,root,root,755)
680 %{archlibdir}/libatomic.dll.a
681 %{archlibdir}/libatomic.la
682
683 %files -n crossmingw32-libatomic-static
684 %defattr(644,root,root,755)
685 %{archlibdir}/libatomic.a
686
687 %files -n crossmingw32-libatomic-dll
688 %defattr(644,root,root,755)
689 %{_dlldir}/libatomic-1.dll
690 %endif
691
692 %if %{with gomp}
693 %files -n crossmingw32-libgomp
694 %defattr(644,root,root,755)
695 %{archlibdir}/libgomp.dll.a
696 %{archlibdir}/libgomp.la
697 %{archlibdir}/libgomp.spec
698
699 %files -n crossmingw32-libgomp-static
700 %defattr(644,root,root,755)
701 %{archlibdir}/libgomp.a
702
703 %files -n crossmingw32-libgomp-dll
704 %defattr(644,root,root,755)
705 %{_dlldir}/libgomp-1.dll
706 %endif
707
708 %if %{without bootstrap}
709 %files -n crossmingw32-libvtv
710 %defattr(644,root,root,755)
711 %{archlibdir}/libvtv.dll.a
712 %{archlibdir}/libvtv.la
713 %{archlibdir}/libvtv_stubs.dll.a
714 %{archlibdir}/libvtv_stubs.la
715
716 %files -n crossmingw32-libvtv-static
717 %defattr(644,root,root,755)
718 %{archlibdir}/libvtv.a
719 %{archlibdir}/libvtv_stubs.a
720
721 %files -n crossmingw32-libvtv-dll
722 %defattr(644,root,root,755)
723 %{_dlldir}/libvtv-0.dll
724 %{_dlldir}/libvtv_stubs-0.dll
725 %endif
726
727 %files c++
728 %defattr(644,root,root,755)
729 %attr(755,root,root) %{_bindir}/%{target}-g++
730 %attr(755,root,root) %{archbindir}/%{target}-c++
731 %attr(755,root,root) %{archbindir}/%{target}-g++
732 %attr(755,root,root) %{gcclibdir}/cc1plus
733 %{archlibdir}/libstdc++.dll.a
734 %{archlibdir}/libstdc++.la
735 %{archlibdir}/libstdc++fs.a
736 %{archlibdir}/libstdc++fs.la
737 %{archlibdir}/libsupc++.la
738 %{archlibdir}/libsupc++.a
739 %{archincludedir}/c++
740 %{_mandir}/man1/%{target}-g++.1*
741
742 %files -n crossmingw32-libstdc++-static
743 %defattr(644,root,root,755)
744 %{archlibdir}/libstdc++.a
745
746 %files -n crossmingw32-libstdc++-dll
747 %defattr(644,root,root,755)
748 %{_dlldir}/libstdc++-6.dll
749
750 %if %{without bootstrap}
751 %files objc
752 %defattr(644,root,root,755)
753 %doc libobjc/README
754 %attr(755,root,root) %{gcclibdir}/cc1obj
755 %{archlibdir}/libobjc.dll.a
756 %{archlibdir}/libobjc.la
757 %{gcclibdir}/include/objc
758
759 %files objc++
760 %defattr(644,root,root,755)
761 %doc gcc/objcp/ChangeLog
762 %attr(755,root,root) %{gcclibdir}/cc1objplus
763
764 %files -n crossmingw32-libobjc-static
765 %defattr(644,root,root,755)
766 %{archlibdir}/libobjc.a
767
768 %files -n crossmingw32-libobjc-dll
769 %defattr(644,root,root,755)
770 %{_dlldir}/libobjc-4.dll
771
772 %files fortran
773 %defattr(644,root,root,755)
774 %attr(755,root,root) %{_bindir}/%{target}-gfortran
775 %attr(755,root,root) %{archbindir}/%{target}-gfortran
776 %attr(755,root,root) %{gcclibdir}/f951
777 %{archlibdir}/libgfortran.dll.a
778 %{archlibdir}/libgfortran.la
779 %{archlibdir}/libgfortran.spec
780 %{gcclibdir}/finclude
781 %{gcclibdir}/libcaf_single.a
782 %{gcclibdir}/libcaf_single.la
783 %{_mandir}/man1/%{target}-gfortran.1*
784
785 %files -n crossmingw32-libgfortran-static
786 %defattr(644,root,root,755)
787 %{archlibdir}/libgfortran.a
788
789 %files -n crossmingw32-libgfortran-dll
790 %defattr(644,root,root,755)
791 %{_dlldir}/libgfortran-5.dll
792
793 %files -n crossmingw32-libquadmath
794 %defattr(644,root,root,755)
795 %{archlibdir}/libquadmath.dll.a
796 %{archlibdir}/libquadmath.la
797
798 %files -n crossmingw32-libquadmath-static
799 %defattr(644,root,root,755)
800 %{archlibdir}/libquadmath.a
801
802 %files -n crossmingw32-libquadmath-dll
803 %defattr(644,root,root,755)
804 %{_dlldir}/libquadmath-0.dll
805 %endif
This page took 0.118753 seconds and 3 git commands to generate.