34e47762066526971a9a57cdf90106a5d61f0955
[platform/upstream/gcc49.git] / packaging / gcc.spec.in
1 #
2 # spec file for package gcc49
3 #
4 # Copyright (c) 2009 SUSE LINUX Products GmbH, Nuernberg, Germany.
5 #
6 # All modifications and additions to the file contributed by third parties
7 # remain the property of their copyright owners, unless otherwise agreed
8 # upon. The license for this file, and modifications and additions to the
9 # file, is the same license as for the pristine package itself (unless the
10 # license for the pristine package is not an Open Source License, in which
11 # case the license is the MIT License). An "Open Source License" is a
12 # license that conforms to the Open Source Definition (Version 1.9)
13 # published by the Open Source Initiative.
14
15 # Please submit bugfixes or comments via http://bugs.opensuse.org/
16 #
17
18 # norootforbuild
19 # icecream 0
20
21
22 %define build_ada 0
23
24 %define quadmath_arch %ix86 x86_64 ia64
25 %define tsan_arch x86_64
26 %define asan_arch x86_64 %ix86 ppc ppc64 %sparc %arm
27 %define itm_arch x86_64 %ix86 %arm ppc ppc64 ppc64le s390 s390x %sparc aarch64
28 %define atomic_arch x86_64 %ix86 %arm aarch64 ppc ppc64 ppc64le s390 s390x %sparc m68k
29 %define lsan_arch x86_64
30 %define ubsan_arch x86_64 %ix86 ppc ppc64 %arm
31 %if 0%{?build_libvtv:1}
32 %define vtv_arch x86_64 %ix86
33 %endif
34 %define cilkrts_arch x86_64 %ix86
35
36 # We don't want to build java
37 %define build_java 0
38 %define build_libjava 0
39
40 # Also go and objc aren't needed right now
41 %define build_objc 0
42 %define build_objcp 0
43 %define build_go 0
44
45 %define build_cp 1
46 %define build_fortran !0%{?building_libjava:1}%{?building_libffi:1}
47
48 %if %{build_objcp}
49 %define build_cp 1
50 %define build_objc 1
51 %endif
52
53 %if %{build_libjava}
54 %define build_cp 1
55 %endif
56
57 # For optional compilers only build C, C++ and Fortran
58 %if 0%{?build_optional_compiler_languages:1}
59 %define build_ada 0
60 %define build_java 0
61 %define build_libjava 0
62 %define build_objc 0
63 %define build_objcp 0
64 %define build_go 0
65 %endif
66
67 # Shared library SONAME versions
68 %ifarch hppa
69 %define libgcc_s 4
70 %else
71 %ifarch m68k
72 %define libgcc_s 2
73 %else
74 %define libgcc_s 1
75 %endif
76 %endif
77 %define libgcj_sover %{nil}
78 %define libgcj_bc_sover %{nil}
79 %define libffi_sover %{nil}
80 %define libgomp_sover %{nil}
81 %define libstdcxx_sover %{nil}
82 %define libobjc_sover %{nil}
83 %define libgfortran_sover %{nil}
84 %define libquadmath_sover %{nil}
85 %define libasan_sover %{nil}
86 %define libtsan_sover %{nil}
87 %define libatomic_sover %{nil}
88 %define libitm_sover %{nil}
89 %define libubsan_sover %{nil}
90 %define liblsan_sover %{nil}
91 %define libvtv_sover %{nil}
92 %define libcilkrts_sover %{nil}
93 %define libgo_sover %{nil}
94
95 # Shared library package suffix
96 # This is used for the "non-standard" set of libraries, the standard
97 # being defined by %product_libs_gcc_ver, the GCC version that should
98 # provide un-suffixed shared library packages following the shared-library
99 # policy.  Even suffixed variants should provide the shared-library policy
100 # mandated names and ensure they conflict with each other.
101 # Note that on SONAME changes of any library the %product_libs_gcc_ver
102 # define needs to be either split or the newest GCC version still providing
103 # the old SONAME needs to unconditionally produce an un-suffixed library
104 # if %product_libs_gcc_ver is newer than it.  Similar the _oldest_ GCC
105 # version first providing a new SONAME needs to unconditionally produce
106 # an un-suffixed library if %product_libs_gcc_ver is lower that it.
107 %if %{!?product_libs_gcc_ver:@base_ver@}%{?product_libs_gcc_ver} != @base_ver@
108 %define pne 1
109 %endif
110 %define libgcc_s_suffix %{?pne:-gcc@base_ver@}
111 # libgcj SONAME changes with every GCC version
112 %define libgcj_suffix %nil
113 %define libgcj_bc_suffix %{?pne:-gcc@base_ver@}
114 %define libffi_suffix %{?pne:-gcc@base_ver@}
115 %define libgomp_suffix %{?pne:-gcc@base_ver@}
116 %define libstdcxx_suffix %{?pne:-gcc@base_ver@}
117 %define libobjc_suffix %{?pne:-gcc@base_ver@}
118 %define libgfortran_suffix %{?pne:-gcc@base_ver@}
119 %define libquadmath_suffix %{?pne:-gcc@base_ver@}
120 %define libasan_suffix %{?pne:-gcc@base_ver@}
121 %define libtsan_suffix %{?pne:-gcc@base_ver@}
122 %define libatomic_suffix %{?pne:-gcc@base_ver@}
123 %define libitm_suffix %{?pne:-gcc@base_ver@}
124
125
126 %define libubsan_suffix %{?pne:-gcc@base_ver@}
127 %define liblsan_suffix %{?pne:-gcc@base_ver@}
128 %define libvtv_suffix %{?pne:-gcc@base_ver@}
129 %define libcilkrts_suffix %{?pne:-gcc@base_ver@}
130 %define libgo_suffix %{?pne:-gcc@base_ver@}
131
132 %define selfconflict() %1
133
134 Name:         gcc@base_ver@
135 # For unknown reason when libgcc.so is built with gold, it causes python to
136 # make syscalls with zero-length buffers. That's why we disable gold for gcc
137 BuildConflicts: binutils-gold
138 # With generated files in src we could drop the following
139 BuildRequires: bison
140 BuildRequires: flex
141 BuildRequires: gettext-devel
142 BuildRequires: makeinfo
143 # until here, but at least renaming and patching info files breaks this
144 BuildRequires: gcc-c++
145 BuildRequires: glibc-devel-32bit
146 BuildRequires: mpc-devel
147 BuildRequires: mpfr-devel
148 BuildRequires: perl
149 BuildRequires: zlib-devel
150 %ifarch %ix86 x86_64 ppc ppc64 s390 s390x ia64 %sparc hppa %arm aarch64
151 BuildRequires: cloog-isl-devel
152 BuildRequires: isl-devel
153 %endif
154 %if %{build_ada}
155 %define hostsuffix -4.9
156 BuildRequires: gcc49-ada
157 %endif
158 %if 0%{?building_libjava:1}%{?building_testsuite:1}
159 BuildRequires: fastjar
160 %endif
161 %if 0%{?building_libffi:1}
162 BuildRequires: pkg-config
163 %endif
164 %ifarch ia64
165 BuildRequires: libunwind-devel
166 %endif
167 %if 0%{?run_tests:1}
168 BuildRequires: dejagnu
169 BuildRequires: expect
170 BuildRequires: gdb
171 %endif
172
173 %define separate_bi32 0
174 %define separate_bi64 0
175 %ifarch ppc sparcv9
176 # Beware, this does _not_ separate libgcj, as for that one multilibing
177 # is inactive for the time being
178 %define separate_bi64 1
179 %endif
180 %ifarch x86_64 s390x ppc64 sparc64
181 %define separate_bi32 1
182 %endif
183
184 # Define two macros to trigger -32bit or -64bit package variants
185 %define separate_biarch 0
186 %if %{separate_bi32}
187 %define separate_biarch 1
188 %define separate_biarch_suffix -32bit
189 %endif
190 %if %{separate_bi64}
191 %define separate_biarch 1
192 %define separate_biarch_suffix -64bit
193 %endif
194
195 %ifarch x86_64 ia64 s390x alpha ppc64 sparc64 aarch64
196 # 64-bit is primary build target
197 %define build_primary_64bit 1
198 %else
199 %define build_primary_64bit 0
200 %endif
201
202 %define biarch_libjava 0
203
204 # COMMON-BEGIN
205 %define biarch_targets x86_64 s390x powerpc64 powerpc sparc sparc64
206
207 URL:          http://gcc.gnu.org/
208 Version: 4.9.2
209 Release:      1
210 %define gcc_dir_version 4.9
211 %define binsuffix -4.9
212 # COMMON-END
213
214 %if !0%{?building_libjava:1}%{?building_libffi:1}%{?building_testsuite:1}
215 Requires: binutils glibc-devel
216 Requires: cpp@base_ver@ = %{version}-%{release}
217 Requires: libgcc_s%{libgcc_s} >= %{version}-%{release}
218 Requires: libgomp%{libgomp_sover} >= %{version}-%{release}
219 %ifarch %asan_arch
220 Requires: libasan%{libasan_sover} >= %{version}-%{release}
221 %endif
222 %ifarch %tsan_arch
223 Requires: libtsan%{libtsan_sover} >= %{version}-%{release}
224 %endif
225 %ifarch %atomic_arch
226 Requires: libatomic%{libatomic_sover} >= %{version}-%{release}
227 %endif
228 %ifarch %itm_arch
229 Requires: libitm%{libitm_sover} >= %{version}-%{release}
230 %endif
231 %ifarch %cilkrts_arch
232 Requires: libcilkrts%{libcilkrts_sover} >= %{version}-%{release}
233 %endif
234 %ifarch %lsan_arch
235 Requires: liblsan%{liblsan_sover} >= %{version}-%{release}
236 %endif
237 %ifarch %ubsan_arch
238 Requires: libubsan%{libubsan_sover} >= %{version}-%{release}
239 %endif
240 %ifarch %vtv_arch
241 Requires: libvtv%{libvtv_sover} >= %{version}-%{release}
242 %endif
243 Requires: gcc@base_ver@-info gcc@base_ver@-locale
244 %endif
245
246 # COMMON-BEGIN
247 BuildRoot:      %{_tmppath}/%{name}-%{version}-build
248 Source:         gcc-%{version}.tar.bz2
249 Source1:        change_spec
250 Source3:        gcc49-rpmlintrc
251 Source4:        ecj.jar
252 Source5:        baselibs.conf
253
254 # GCC-TESTSUITE-DELETE-BEGIN
255 # LIBJAVA-DELETE-BEGIN
256 Group:          Development/Building
257 Summary:        The GNU C Compiler and Support Files
258 License:        GPL-3.0+
259
260 %description
261 Core package for the GNU Compiler Collection, including the C language
262 frontend.
263
264 Language frontends other than C are split to different sub-packages,
265 namely gcc-ada, gcc-c++, gcc-fortran, gcc-java, gcc-objc and
266 gcc-obj-c++.
267 # LIBFFI-DELETE-BEGIN
268
269
270
271 # COMMON-END
272 %package -n gcc@base_ver@-32bit
273 Summary:      The GNU C Compiler 32bit support
274 Group:          Development/Building
275 Requires: gcc@base_ver@ = %{version}-%{release}
276 Requires: libgcc_s%{libgcc_s}-32bit >= %{version}-%{release}
277 Requires: libgomp%{libgomp_sover}-32bit >= %{version}-%{release}
278 %ifarch %asan_arch
279 Requires: libasan%{libasan_sover}-32bit >= %{version}-%{release}
280 %endif
281 %ifarch %tsan_arch
282 # tsan on x86_64 has no multilib
283 %ifarch x86_64
284 %else
285 Requires: libtsan%{libtsan_sover}-32bit >= %{version}-%{release}
286 %endif
287 %endif
288 %ifarch %atomic_arch
289 Requires: libatomic%{libatomic_sover}-32bit >= %{version}-%{release}
290 %endif
291 %ifarch %itm_arch
292 Requires: libitm%{libitm_sover}-32bit >= %{version}-%{release}
293 %endif
294 %ifarch %cilkrts_arch
295 Requires: libcilkrts%{libcilkrts_sover}-32bit >= %{version}-%{release}
296 %endif
297 # lsan on x86_64 has no multilib
298 %ifarch x86_64
299 %else
300 %ifarch %lsan_arch
301 Requires: liblsan%{liblsan_sover} >= %{version}-%{release}
302 %endif
303 %endif
304 %ifarch %ubsan_arch
305 Requires: libubsan%{libubsan_sover}-32bit >= %{version}-%{release}
306 %endif
307 %ifarch %vtv_arch
308 Requires: libvtv%{libvtv_sover}-32bit >= %{version}-%{release}
309 %endif
310 Requires: glibc-devel-32bit
311
312 %description -n gcc@base_ver@-32bit
313 This package contains 32bit support for the GNU Compiler Collection.
314
315 %package -n gcc@base_ver@-64bit
316 Summary:      The GNU C Compiler 64bit support
317 Group:          Development/Building
318 Requires: gcc@base_ver@ = %{version}-%{release}
319 Requires: libgcc_s%{libgcc_s}-64bit >= %{version}-%{release}
320 Requires: libgomp%{libgomp_sover}-64bit >= %{version}-%{release}
321 %ifarch %asan_arch
322 Requires: libasan%{libasan_sover}-64bit >= %{version}-%{release}
323 %endif
324 %ifarch %tsan_arch
325 Requires: libtsan%{libtsan_sover}-64bit >= %{version}-%{release}
326 %endif
327 %ifarch %atomic_arch
328 Requires: libatomic%{libatomic_sover}-64bit >= %{version}-%{release}
329 %endif
330 %ifarch %itm_arch
331 Requires: libitm%{libitm_sover}-64bit >= %{version}-%{release}
332 %endif
333 %ifarch %cilkrts_arch
334 Requires: libcilkrts%{libcilkrts_sover}-64bit >= %{version}-%{release}
335 %endif
336 %ifarch %lsan_arch
337 Requires: liblsan%{liblsan_sover}-64bit >= %{version}-%{release}
338 %endif
339 %ifarch %ubsan_arch
340 Requires: libubsan%{libubsan_sover}-64bit >= %{version}-%{release}
341 %endif
342 %ifarch %vtv_arch
343 Requires: libvtv%{libvtv_sover}-64bit >= %{version}-%{release}
344 %endif
345 Requires: glibc-devel-64bit
346
347 %description -n gcc@base_ver@-64bit
348 This package contains 64bit support for the GNU Compiler Collection.
349
350
351 %package locale
352 Summary:      Locale Data for the GNU Compiler Collection
353 License:        GPL-3.0+
354 Group:          Development/Building
355 Requires: gcc@base_ver@ = %{version}-%{release}
356
357 %description locale
358 Locale data for the GNU Compiler Collection (GCC) to give error message
359 in the current locale.
360
361
362 %package c++
363 Summary:      The GNU C++ Compiler
364 License:        GPL-3.0+
365 Group:        Development/Languages
366 Requires: gcc@base_ver@ = %{version}-%{release}
367 Requires: libstdc++@base_ver@-devel = %{version}-%{release}
368
369 %description c++
370 This package contains the GNU compiler for C++.
371
372 # PACKAGE-BEGIN
373 %package -n libstdc++@base_ver@-devel@variant@
374 Summary:      Include Files and Libraries mandatory for Development
375 License:        GPL-3.0-with-GCC-exception
376 Group:          Development/Building
377 Requires: libstdc++%{libstdcxx_sover}@variant@ >= %{version}-%{release}
378 Requires: glibc-devel@variant@
379 %ifarch ia64
380 Requires: libunwind-devel
381 %endif
382
383 %description -n libstdc++@base_ver@-devel@variant@
384 This package contains all the headers and libraries of the standard C++
385 library. It is needed for compiling C++ code.
386 # PACKAGE-END
387
388
389 # PACKAGE-BEGIN
390 %package -n libgcc_s%{libgcc_s}%{libgcc_s_suffix}@variant@
391 Summary:      C compiler runtime library
392 License:        GPL-3.0-with-GCC-exception
393 Group:          Development/Building
394 Provides:       libgcc_s%{libgcc_s}@variant@ = %{version}-%{release}
395
396 %description -n libgcc_s%{libgcc_s}%{libgcc_s_suffix}@variant@
397 Libgcc is needed for dynamically linked C programs.
398
399 %post -n libgcc_s%{libgcc_s}%{libgcc_s_suffix}@variant@ -p /sbin/ldconfig
400
401 %postun -n libgcc_s%{libgcc_s}%{libgcc_s_suffix}@variant@ -p /sbin/ldconfig
402 # PACKAGE-END
403
404 # PACKAGE-BEGIN
405 %package -n libgomp%{libgomp_sover}%{libgomp_suffix}@variant@
406 Summary:      The GNU compiler collection OpenMP runtime library
407 License:        GPL-3.0-with-GCC-exception
408 Group:          Development/Building
409 Provides:       libgomp%{libgomp_sover}@variant@ = %{version}-%{release}
410
411 %description -n libgomp%{libgomp_sover}%{libgomp_suffix}@variant@
412 This is the OpenMP runtime library needed by OpenMP enabled programs
413 that were built with the -fopenmp compiler option and by programs that
414 were auto-parallelized via the -ftree-parallelize-loops compiler
415 option.
416
417
418 %post -n libgomp%{libgomp_sover}%{libgomp_suffix}@variant@ -p /sbin/ldconfig
419
420 %postun -n libgomp%{libgomp_sover}%{libgomp_suffix}@variant@ -p /sbin/ldconfig
421 # PACKAGE-END
422
423 # PACKAGE-BEGIN
424 %package -n libstdc++%{libstdcxx_sover}%{libstdcxx_suffix}@variant@
425 Summary:      The standard C++ shared library
426 License:        GPL-3.0-with-GCC-exception
427 Group:          Development/Building
428 Requires:       libstdc++%{libstdcxx_sover}-locale
429 Provides:       libstdc++%{libstdcxx_sover}@variant@ = %{version}-%{release}
430
431 %description -n libstdc++%{libstdcxx_sover}%{libstdcxx_suffix}@variant@
432 The standard C++ library, needed for dynamically linked C++ programs.
433
434
435 %post -n libstdc++%{libstdcxx_sover}%{libstdcxx_suffix}@variant@ -p /sbin/ldconfig
436
437 %postun -n libstdc++%{libstdcxx_sover}%{libstdcxx_suffix}@variant@ -p /sbin/ldconfig
438 # PACKAGE-END
439
440 %package -n libstdc++%{libstdcxx_sover}%{libstdcxx_suffix}-locale
441 Summary:        Locale Data for the standard C++ shared library
442 License:        GPL-3.0-with-GCC-exception
443 Group:          Development/Building
444 Provides:       libstdc++%{libstdcxx_sover}-locale = %{version}-%{release}
445
446 %description -n libstdc++%{libstdcxx_sover}%{libstdcxx_suffix}-locale
447 The standard C++ library locale data.
448
449
450 %package info
451 Summary:      Documentation for the GNU compiler collection
452 License:      GFDL-1.2
453 Group:        Development/Building
454 BuildArch:    noarch
455
456 %description info
457 GNU info-pages for the GNU compiler collection covering both user-level
458 and internals documentation.
459
460
461 # PACKAGE-BEGIN
462 %package objc@variant@
463 Summary:      GNU Objective C Compiler
464 License:        GPL-3.0+
465 Group:        Development/Languages
466 Requires: gcc@base_ver@ = %{version}-%{release}
467 Requires: libobjc%{libobjc_sover}@variant@ >= %{version}-%{release}
468
469 %description objc@variant@
470 This package contains the GNU Objective C compiler. Objective C is an
471 object oriented language, created by Next Inc. and used in their
472 Nextstep OS. The source code is available in the gcc package.
473 # PACKAGE-END
474
475 # PACKAGE-BEGIN
476 %package -n libobjc%{libobjc_sover}%{libobjc_suffix}@variant@
477 Summary:      Library for the GNU Objective C Compiler
478 License:        GPL-3.0-with-GCC-exception
479 Group:        Development/Building
480 Provides:       libobjc%{libobjc_sover}@variant@ = %{version}-%{release}
481
482 %description -n libobjc%{libobjc_sover}%{libobjc_suffix}@variant@
483 The library for the GNU Objective C compiler.
484
485 %post -n libobjc%{libobjc_sover}%{libobjc_suffix}@variant@ -p /sbin/ldconfig
486
487 %postun -n libobjc%{libobjc_sover}%{libobjc_suffix}@variant@ -p /sbin/ldconfig
488 # PACKAGE-END
489
490 %package obj-c++
491 Summary:      GNU Objective C++ Compiler
492 License:        GPL-3.0+
493 Group:        Development/Languages
494 Requires: gcc@base_ver@-objc = %{version}-%{release}
495 Requires: gcc@base_ver@-c++ = %{version}-%{release}
496
497 %description obj-c++
498 This package contains the GNU Objective C++ compiler. Objective C++ is an
499 object oriented language, created by Next Inc. and used in their
500 Nextstep OS. The source code is available in the gcc package.
501
502
503 %package -n cpp@base_ver@
504 Summary:      The GCC Preprocessor
505 License:        GPL-3.0+
506 Group:        Development/Languages
507
508 %description -n cpp@base_ver@
509 This Package contains just the preprocessor that is used by the X11
510 packages.
511
512
513 # PACKAGE-BEGIN
514 %package ada@variant@
515 Summary:      GNU Ada95 Compiler Based on GCC (GNAT)
516 License:        GPL-3.0+
517 Group:        Development/Languages
518 Requires: gcc@base_ver@@variant@ = %{version}-%{release}
519 Requires: libada@base_ver@@variant@ = %{version}-%{release}
520
521 %description ada@variant@
522 This package contains an Ada95 compiler and associated development
523 tools based on the GNU GCC technology. Ada95 is the object oriented
524 successor of the Ada83 language. To build this package from source you
525 must have installed a binary version to bootstrap the compiler.
526 # PACKAGE-END
527
528 # PACKAGE-BEGIN
529 %package -n libada@base_ver@@variant@
530 Summary:      GNU Ada Runtime Libraries
531 License:      GPL-3.0-with-GCC-exception
532 Group:        Development/Languages
533 Provides: libgnarl-4_9@variant@ = %{version}-%{release}
534 Provides: libgnat-4_9@variant@ = %{version}-%{release}
535
536 %description -n libada@base_ver@@variant@
537 This package contains the shared libraries required to run programs
538 compiled with the GNU Ada compiler (GNAT) if they are compiled to use
539 shared libraries. It also contains the shared libraries for the
540 Implementation of the Ada Semantic Interface Specification (ASIS), the
541 implementation of Distributed Systems Programming (GLADE) and the Posix
542 1003.5 Binding (Florist).
543
544 %post -n libada@base_ver@@variant@ -p /sbin/ldconfig
545
546 %postun -n libada@base_ver@@variant@ -p /sbin/ldconfig
547 # PACKAGE-END
548
549 # PACKAGE-BEGIN
550 %package fortran@variant@
551 Summary:      The GNU Fortran Compiler and Support Files
552 License:        GPL-3.0+
553 Group:        Development/Languages
554 Requires: gcc@base_ver@ = %{version}-%{release}
555 Requires: libgfortran%{libgfortran_sover}@variant@ >= %{version}-%{release}
556 %ifarch %quadmath_arch
557 Requires: libquadmath%{libquadmath_sover}@variant@ >= %{version}-%{release}
558 %endif
559
560 %description fortran@variant@
561 This is the Fortran compiler of the GNU Compiler Collection (GCC).
562 # PACKAGE-END
563
564 # PACKAGE-BEGIN
565 %package -n libgfortran%{libgfortran_sover}%{libgfortran_suffix}@variant@
566 Summary:      The GNU Fortran Compiler Runtime Library
567 License:        GPL-3.0-with-GCC-exception
568 Group:        Development/Languages
569 %ifarch %quadmath_arch
570 Requires: libquadmath%{libquadmath_sover}@variant@ >= %{version}-%{release}
571 %endif
572 Provides:       libgfortran%{libgfortran_sover}@variant@ = %{version}-%{release}
573
574 %description -n libgfortran%{libgfortran_sover}%{libgfortran_suffix}@variant@
575 The runtime library needed to run programs compiled with the Fortran compiler
576 of the GNU Compiler Collection (GCC).
577
578 %post -n libgfortran%{libgfortran_sover}%{libgfortran_suffix}@variant@ -p /sbin/ldconfig
579
580 %postun -n libgfortran%{libgfortran_sover}%{libgfortran_suffix}@variant@ -p /sbin/ldconfig
581 # PACKAGE-END
582
583 # PACKAGE-BEGIN
584 %package -n libquadmath%{libquadmath_sover}%{libquadmath_suffix}@variant@
585 Summary:      The GNU Fortran Compiler Quadmath Runtime Library
586 License:        LGPL-2.1
587 Group:        Development/Languages
588 Provides:       libquadmath%{libquadmath_sover}@variant@ = %{version}-%{release}
589
590 %description -n libquadmath%{libquadmath_sover}%{libquadmath_suffix}@variant@
591 The runtime library needed to run programs compiled with the Fortran compiler
592 of the GNU Compiler Collection (GCC) and quadruple precision floating point
593 operations.
594
595 %post -n libquadmath%{libquadmath_sover}%{libquadmath_suffix}@variant@ -p /sbin/ldconfig
596
597 %postun -n libquadmath%{libquadmath_sover}%{libquadmath_suffix}@variant@ -p /sbin/ldconfig
598 # PACKAGE-END
599
600 # PACKAGE-BEGIN
601 %package -n libitm%{libitm_sover}%{libitm_suffix}@variant@
602 Summary:      The GNU Compiler Transactional Memory Runtime Library
603 License:        MIT
604 Group:        Development/Languages
605 Provides:       libitm%{libitm_sover}@variant@ = %{version}-%{release}
606
607 %description -n libitm%{libitm_sover}%{libitm_suffix}@variant@
608 The runtime library needed to run programs compiled with the
609 -fgnu-tm option of the GNU Compiler Collection (GCC).
610
611 %post -n libitm%{libitm_sover}%{libitm_suffix}@variant@ -p /sbin/ldconfig
612
613 %postun -n libitm%{libitm_sover}%{libitm_suffix}@variant@ -p /sbin/ldconfig
614 # PACKAGE-END
615
616 # PACKAGE-BEGIN
617 %package -n libasan%{libasan_sover}%{libasan_suffix}@variant@
618 Summary:      The GNU Compiler Address Sanitizer Runtime Library
619 License:        MIT
620 Group:        Development/Languages
621 Provides:       libasan%{libasan_sover}@variant@ = %{version}-%{release}
622
623 %description -n libasan%{libasan_sover}%{libasan_suffix}@variant@
624 The runtime library needed to run programs compiled with the
625 -fsanitize=address option of the GNU Compiler Collection (GCC).
626
627 %post -n libasan%{libasan_sover}%{libasan_suffix}@variant@ -p /sbin/ldconfig
628
629 %postun -n libasan%{libasan_sover}%{libasan_suffix}@variant@ -p /sbin/ldconfig
630 # PACKAGE-END
631
632 # PACKAGE-BEGIN
633 %package -n libtsan%{libtsan_sover}%{libtsan_suffix}@variant@
634 Summary:      The GNU Compiler Thread Sanitizer Runtime Library
635 License:        MIT
636 Group:        Development/Languages
637 Provides:       libtsan%{libtsan_sover}@variant@ = %{version}-%{release}
638
639 %description -n libtsan%{libtsan_sover}%{libtsan_suffix}@variant@
640 The runtime library needed to run programs compiled with the
641 -fsanitize=thread option of the GNU Compiler Collection (GCC).
642
643 %post -n libtsan%{libtsan_sover}%{libtsan_suffix}@variant@ -p /sbin/ldconfig
644
645 %postun -n libtsan%{libtsan_sover}%{libtsan_suffix}@variant@ -p /sbin/ldconfig
646 # PACKAGE-END
647
648 # PACKAGE-BEGIN
649 %package -n libatomic%{libatomic_sover}%{libatomic_suffix}@variant@
650 Summary:      The GNU Compiler Atomic Operations Runtime Library
651 License:      GPL-3.0-with-GCC-exception
652 Group:        Development/Languages
653 Provides:       libatomic%{libatomic_sover}@variant@ = %{version}-%{release}
654
655 %description -n libatomic%{libatomic_sover}%{libatomic_suffix}@variant@
656 The runtime library for atomic operations of the GNU Compiler Collection (GCC).
657
658 %post -n libatomic%{libatomic_sover}%{libatomic_suffix}@variant@ -p /sbin/ldconfig
659
660 %postun -n libatomic%{libatomic_sover}%{libatomic_suffix}@variant@ -p /sbin/ldconfig
661 # PACKAGE-END
662
663 # PACKAGE-BEGIN
664 %package -n libcilkrts%{libcilkrts_sover}%{libcilkrts_suffix}@variant@
665 Summary:      The GNU Compiler Cilk+ Runtime Library
666 License:        MIT
667 Group:        Development/Languages
668 Provides:       libcilkrts%{libcilkrts_sover}@variant@ = %{version}-%{release}
669
670 %description -n libcilkrts%{libcilkrts_sover}%{libcilkrts_suffix}@variant@
671 The runtime library needed to run programs compiled with the
672 -fcilkplus option of the GNU Compiler Collection (GCC).
673
674 %post -n libcilkrts%{libcilkrts_sover}%{libcilkrts_suffix}@variant@ -p /sbin/ldconfig
675
676 %postun -n libcilkrts%{libcilkrts_sover}%{libcilkrts_suffix}@variant@ -p /sbin/ldconfig
677 # PACKAGE-END
678
679 # PACKAGE-BEGIN
680 %package -n liblsan%{liblsan_sover}%{liblsan_suffix}@variant@
681 Summary:      The GNU Compiler Leak Sanitizer Runtime Library
682 License:        MIT
683 Group:        Development/Languages
684 Provides:       liblsan%{liblsan_sover}@variant@ = %{version}-%{release}
685
686 %description -n liblsan%{liblsan_sover}%{liblsan_suffix}@variant@
687 The runtime library needed to run programs compiled with the
688 -fsanitize=leak option of the GNU Compiler Collection (GCC).
689
690 %post -n liblsan%{liblsan_sover}%{liblsan_suffix}@variant@ -p /sbin/ldconfig
691
692 %postun -n liblsan%{liblsan_sover}%{liblsan_suffix}@variant@ -p /sbin/ldconfig
693 # PACKAGE-END
694
695 # PACKAGE-BEGIN
696 %package -n libubsan%{libubsan_sover}%{libubsan_suffix}@variant@
697 Summary:      The GNU Compiler Undefined Sanitizer Runtime Library
698 License:        MIT
699 Group:        Development/Languages
700 Provides:       libubsan%{libubsan_sover}@variant@ = %{version}-%{release}
701
702 %description -n libubsan%{libubsan_sover}%{libubsan_suffix}@variant@
703 The runtime library needed to run programs compiled with the
704 -fsanitize=undefined option of the GNU Compiler Collection (GCC).
705
706 %post -n libubsan%{libubsan_sover}%{libubsan_suffix}@variant@ -p /sbin/ldconfig
707
708 %postun -n libubsan%{libubsan_sover}%{libubsan_suffix}@variant@ -p /sbin/ldconfig
709 # PACKAGE-END
710
711 # PACKAGE-BEGIN
712 %package -n libvtv%{libvtv_sover}%{libvtv_suffix}@variant@
713 Summary:      The GNU Compiler Vtable Verifier Runtime Library
714 License:        MIT
715 Group:        Development/Languages
716 Provides:       libvtv%{libvtv_sover}@variant@ = %{version}-%{release}
717
718 %description -n libvtv%{libvtv_sover}%{libvtv_suffix}@variant@
719 The runtime library needed to run programs compiled with the
720 -fvtable-verify option of the GNU Compiler Collection (GCC).
721
722 %post -n libvtv%{libvtv_sover}%{libvtv_suffix}@variant@ -p /sbin/ldconfig
723
724 %postun -n libvtv%{libvtv_sover}%{libvtv_suffix}@variant@ -p /sbin/ldconfig
725 # PACKAGE-END
726
727
728 %package -n libgcj@base_ver@
729 # LIBJAVA-DELETE-END
730 Summary:      Java Runtime Library for gcc
731 License:      GPL-2.0-with-classpath-exception
732 Group:        Development/Building
733 Requires:   libgcj@base_ver@-jar = %{version}-%{release}
734 Provides: libgcj%{libgcj_sover} = %{version}-%{release}
735 Provides: libgij%{libgcj_sover} = %{version}-%{release}
736 Provides: libgcj-tools%{libgcj_sover} = %{version}-%{release}
737
738 %description -n libgcj@base_ver@
739 This library is needed if you want to use the GNU Java compiler, gcj.
740 Source code for this package is in gcc.
741
742 %post -n libgcj@base_ver@ -p /sbin/ldconfig
743
744 %postun -n libgcj@base_ver@ -p /sbin/ldconfig
745
746
747 %package -n gcc@base_ver@-java
748 Summary:      The GNU Java Compiler
749 License:        GPL-3.0+
750 Group:        Development/Languages
751 Requires: gcc@base_ver@ = %{version}
752 Requires: libgcj@base_ver@-devel = %{version}-%{release}
753
754 %description -n gcc@base_ver@-java
755 The Java compiler from the GCC-tools-suite.
756
757
758 %package -n libgcj_bc%{libgcj_bc_sover}%{libgcj_bc_suffix}
759 Summary:      Fake library for BC-ABI compatibility.
760 License:        GPL-2.0-with-classpath-exception
761 Group:        Development/Languages
762 # libgcj_bc is special in that it just contains a symlink to
763 # a proper libgcj version.  So require that library and add
764 # provides for the shlib version as created at link time
765 Requires: libgcj%{libgcj_sover} >= %{version}-%{release}
766 %ifarch x86_64 ia64 ppc64 s390x sparc64 aarch64
767 Provides: libgcj_bc.so.%{libgcj_bc_sover}()(64bit)
768 %else
769 Provides: libgcj_bc.so.%{libgcj_bc_sover}
770 %endif
771 Provides:       libgcj_bc%{libgcj_bc_sover} = %{version}-%{release}
772
773 %description -n libgcj_bc%{libgcj_bc_sover}%{libgcj_bc_suffix}
774 A fake library that is used at link time only. It ensures that
775 binaries built with the BC-ABI link against a constant SONAME.
776 This way, BC-ABI binaries continue to work if the SONAME underlying
777 libgcj.so changes.
778
779
780 %package -n libgcj@base_ver@-jar
781 Summary:      Java runtime library (jar files).
782 License:        GPL-2.0-with-classpath-exception
783 Group:        Development/Languages
784
785 %description -n libgcj@base_ver@-jar
786 These are the jar files that go along with the gcj front end to gcc.
787
788
789 %package -n libgcj@base_ver@-devel
790 Summary:      Include Files and Libraries mandatory for Development.
791 License:        GPL-2.0-with-classpath-exception
792 Group:        Development/Languages
793 Requires: libgcj%{libgcj_sover} >= %{version}-%{release}
794 Requires: libgcj_bc%{libgcj_bc_sover} >= %{version}-%{release}
795 Requires: libgcj@base_ver@-jar = %{version}-%{release}
796
797 %description -n libgcj@base_ver@-devel
798 This package contains all necessary include files and libraries needed
799 to develop applications that require these.
800
801
802 %package -n gcc@base_ver@-gij
803 Summary:      Java Bytecode Interpreter for gcc
804 License:      GPL-2.0-with-classpath-exception
805 Group:        Development/Languages
806 Requires: libgcj%{libgcj_sover} >= %{version}-%{release}
807
808 %description -n gcc@base_ver@-gij
809 This package contains the java bytecode interpreter gij and related tools.
810
811
812 %package -n libstdc++@base_ver@-doc
813 Summary:      Documentation for the GNU C++ standard library
814 License:        GPL-3.0+
815 Group:        Development/Building
816 BuildArch:    noarch
817
818 %description -n libstdc++@base_ver@-doc
819 Extensive HTML documentation for the GNU C++ standard library.
820
821
822 # LIBFFI-DELETE-END
823 # PACKAGE-BEGIN
824 %package -n libffi%{libffi_sover}%{libffi_suffix}@variant@
825 Summary:      Foreign Function Interface library
826 License:        BSD-3-Clause
827 Group:        Development/Building
828 Provides:       libffi%{libffi_sover}@variant@ = %{version}-%{release}
829
830 %description -n libffi%{libffi_sover}%{libffi_suffix}@variant@
831 A foreign function interface is the popular name for the interface that allows code written in one language to call code written in another language.
832
833 %post -n libffi%{libffi_sover}%{libffi_suffix}@variant@ -p /sbin/ldconfig
834
835 %postun -n libffi%{libffi_sover}%{libffi_suffix}@variant@ -p /sbin/ldconfig
836 # PACKAGE-END
837
838 # PACKAGE-BEGIN
839 %package -n libffi@base_ver@-devel@variant@
840 Summary:      Foreign Function Interface library development files
841 License:        BSD 3-Clause
842 Group:        Development/Building
843 Requires: libffi%{libffi_sover}@variant@ >= %{version}-%{release}
844 Provides: libffi-devel@variant@ = %{version}-%{release}
845
846 %description -n libffi@base_ver@-devel@variant@
847 A foreign function interface is the popular name for the interface that allows code written in one language to call code written in another language.
848 # PACKAGE-END
849
850 # PACKAGE-BEGIN
851 %package go@variant@
852 Summary:      GNU Go Compiler
853 License:        GPL-3.0+
854 Group:        Development/Languages
855 Requires: gcc@base_ver@@variant@ = %{version}-%{release}
856 Requires: libgo%{libgo_sover}@variant@ >= %{version}-%{release}
857
858 %description go@variant@
859 This package contains a Go compiler and associated development
860 files based on the GNU GCC technology.
861 # PACKAGE-END
862
863 # PACKAGE-BEGIN
864 %package -n libgo%{libgo_sover}%{libgo_suffix}@variant@
865 Summary:      GNU Go compiler runtime library
866 License:        BSD-3-Clause
867 Group:        Development/Languages
868 Provides:       libgo%{libgo_sover}@variant@ = %{version}-%{release}
869
870 %description -n libgo%{libgo_sover}%{libgo_suffix}@variant@
871 A foreign function interface is the popular name for the interface that allows code written in one language to call code written in another language.
872
873 %post -n libgo%{libgo_sover}%{libgo_suffix}@variant@ -p /sbin/ldconfig
874
875 %postun -n libgo%{libgo_sover}%{libgo_suffix}@variant@ -p /sbin/ldconfig
876 # PACKAGE-END
877
878
879 %package -n gcc@base_ver@-testresults
880 # GCC-TESTSUITE-DELETE-END
881 Summary:      Testsuite results
882 License:        SUSE-Public-Domain
883 Group:        Development/Languages
884
885 %description -n gcc@base_ver@-testresults
886 Results from running the gcc and target library testsuites.
887
888
889
890 # COMMON-BEGIN
891
892 # Define the canonical target and host architecture
893 #   %gcc_target_arch  is supposed to be the full target triple
894 #   %TARGET_ARCH      is the canonicalized CPU part
895 #   %CONFIGURE_TARGET is the target triple used for --target=
896 %if 0%{?gcc_target_arch:1}
897 %define CONFIGURE_TARGET %{gcc_target_arch}
898 %define TARGET_ARCH %(echo %{gcc_target_arch} | cut -d - -f 1 | sed -e "s/i.86/i586/;s/ppc/powerpc/;s/sparc64.*/sparc64/;s/sparcv.*/sparc/;")
899 %if 0%{?gcc_icecream:1} && %{TARGET_ARCH} == "powerpc"
900 %define CONFIGURE_TARGET powerpc64-tizen-linux
901 %endif
902 %if 0%{?gcc_icecream:1} && %{TARGET_ARCH} == "powerpc64"
903 %define CONFIGURE_TARGET powerpc64-tizen-linux
904 %endif
905 %if 0%{?gcc_icecream:1} && %{TARGET_ARCH} == "i586"
906 %define CONFIGURE_TARGET i586-tizen-linux
907 %endif
908 %if 0%{?gcc_icecream:1} && %{TARGET_ARCH} == "aarch64"
909 %define CONFIGURE_TARGET aarch64-tizen-linux
910 %endif
911 %if 0%{?gcc_icecream:1} && %{TARGET_ARCH} == "armv7l"
912 %define CONFIGURE_TARGET armv7l-tizen-linux-gnueabi
913 %endif
914 %if 0%{?gcc_icecream:1} && %{TARGET_ARCH} == "armv7hl"
915 %define CONFIGURE_TARGET armv7hl-tizen-linux-gnueabi
916 %endif
917 %if 0%{?gcc_icecream:1} && %{TARGET_ARCH} == "armv5tel"
918 %define CONFIGURE_TARGET armv5tel-tizen-linux-gnueabi
919 %endif
920 %else
921 %define TARGET_ARCH %(echo %{_target_cpu} | sed -e "s/i.86/i586/;s/ppc/powerpc/;s/sparc64.*/sparc64/;s/sparcv.*/sparc/;")
922 %endif
923 %define biarch %(case " %{biarch_targets} " in (*" %{TARGET_ARCH} "*) echo 1;; (*) echo 0;; esac)
924
925 %define HOST_ARCH %(echo %{_host_cpu} | sed -e "s/i.86/i586/;s/ppc/powerpc/;s/sparc64.*/sparc64/;s/sparcv.*/sparc/;")
926 %ifarch ppc
927 %define GCCDIST powerpc64-tizen-linux
928 %else
929 %ifarch %sparc
930 %define GCCDIST sparc64-tizen-linux
931 %else
932 %ifarch %arm
933 %define GCCDIST %{HOST_ARCH}-tizen-linux-gnueabi
934 %else
935 %define GCCDIST %{HOST_ARCH}-tizen-linux
936 %endif
937 %endif
938 %endif
939
940 %define libsubdir %{_libdir}/gcc/%{GCCDIST}/%{gcc_dir_version}
941 %define gxxinclude %{_prefix}/include/c++/%{gcc_dir_version}
942
943 # COMMON-END
944
945 # Versionspecific directories
946 %define versmainlibdir %{libsubdir}
947 %define versmainlibdirbi32 %{libsubdir}/32
948 %define versmainlibdirbi64 %{libsubdir}/64
949 %ifarch ppc
950 %define versmainlibdirbi32 %{libsubdir}
951 %define versmainlibdirbi64 %{libsubdir}/64
952 %endif
953 %if %{build_primary_64bit}
954 %define versmainlibdirbi %{versmainlibdirbi32}
955 %else
956 %define versmainlibdirbi %{versmainlibdirbi64}
957 %endif
958
959 %define mainlibdir %{_libdir}
960 %define mainlibdirbi32 %{_prefix}/lib
961 %define mainlibdirbi64 %{_prefix}/lib64
962 %if %{build_primary_64bit}
963 %define mainlibdirbi %{mainlibdirbi32}
964 %else
965 %define mainlibdirbi %{mainlibdirbi64}
966 %endif
967
968
969 # Now define a few macros that make it easy to package libs and
970 # related files just to the right package, without caring for the
971 # exact path the files are in.
972 #   %mainlib  package X from all dirs that belong to the main package
973 #   %biarchlib   package X from all dirs that belong to the -32/64bit package
974 %define mainlib() %{mainlibdir}/%1\
975 %{nil}
976 %define biarchlib() %{nil}
977 %if %{biarch}
978 %if !%{separate_biarch}
979 %define mainlib() %{mainlibdir}/%1\
980 %{mainlibdirbi}/%1\
981 %{nil}
982 %else
983 %define biarchlib() %{mainlibdirbi}/%1\
984 %{nil}
985 %endif
986 %endif
987
988 %define versmainlib() %{versmainlibdir}/%1\
989 %{nil}
990 %define versbiarchlib() %{nil}
991 %if %{biarch}
992 %if !%{separate_biarch}
993 %define versmainlib() %{versmainlibdir}/%1\
994 %{versmainlibdirbi}/%1\
995 %{nil}
996 %else
997 %define versbiarchlib() %{versmainlibdirbi}/%1\
998 %{nil}
999 %endif
1000 %endif
1001
1002
1003 # COMMON-BEGIN
1004
1005 %prep
1006 %setup -q -n gcc-%{version}
1007
1008 # We are configuring ppc as ppc64 but with switched multilibs.  Adjust
1009 # the libstdc++ abi testsuite baseline files accordingly
1010 %ifarch ppc
1011 if [ -d libstdc++-v3/config/abi/post/powerpc64-linux-gnu ]; then
1012   mkdir -p libstdc++-v3/config/abi/post/powerpc64-linux-gnu/64
1013   mv libstdc++-v3/config/abi/post/powerpc64-linux-gnu/baseline_symbols.txt \
1014         libstdc++-v3/config/abi/post/powerpc64-linux-gnu/64/
1015   mv libstdc++-v3/config/abi/post/powerpc64-linux-gnu/32/baseline_symbols.txt \
1016         libstdc++-v3/config/abi/post/powerpc64-linux-gnu/
1017 fi
1018 %endif
1019
1020 %build
1021 # Avoid rebuilding of generated files
1022 contrib/gcc_update --touch
1023 # Avoid fucking up testsuite results with Java and indirect dispatch
1024 export LD_AS_NEEDED=0
1025 # Split version file into version used for directories (X.Y) and
1026 # version to report with --version (X.Y.Z).
1027 # See also gcc-dir-version.patch.
1028 # Also decrement the patchlevel version by one if possible and remove
1029 # the 'prerelease' tagging in this case
1030 if test `cat gcc/DEV-PHASE` == "prerelease"; then
1031   if test `cat gcc/BASE-VER | cut -d '.' -f 3` != "0"; then
1032     : > gcc/DEV-PHASE
1033   fi
1034   ( cat gcc/BASE-VER | cut -d '.' -f 1-2 | tr -d '\n'; echo -n .; cat gcc/BASE-VER | cut -d '.' -f 3 | tr '0123456789' '0012345678' ) > gcc/FULL-VER
1035 else
1036   mv gcc/BASE-VER gcc/FULL-VER
1037 fi
1038 cat gcc/FULL-VER | cut -d '.' -f 1-2 > gcc/BASE-VER
1039
1040 rm -rf obj-%{GCCDIST}
1041 mkdir obj-%{GCCDIST}
1042 cd obj-%{GCCDIST}
1043 RPM_OPT_FLAGS=`echo $RPM_OPT_FLAGS|sed -e 's/-fno-rtti//g' -e 's/-fno-exceptions//g' -e 's/-Wmissing-format-attribute//g' -e 's/-fstack-protector//g' -e 's/-ffortify=.//g' -e 's/-Wall//g' -e 's/-m32//g' -e 's/-m64//g' -e 's/-fexceptions//' -e 's/\([[:space:]]\+.*-D_FORTIFY_SOURCE=\)[[:alnum:]]\+/\10/g'
1044 RPM_OPT_FLAGS="$RPM_OPT_FLAGS -D__USE_FORTIFY_LEVEL=0"`
1045 %ifarch %ix86
1046 # -mcpu is superceded by -mtune but -mtune is not supported by
1047 # our bootstrap compiler.  -mcpu gives a warning that stops
1048 # the build process, so remove it for now.  Also remove all other
1049 # -march and -mtune flags.  They are superseeded by proper
1050 # default compiler settings now.
1051 RPM_OPT_FLAGS=`echo $RPM_OPT_FLAGS|sed -e 's/-mcpu=i.86//g' -e 's/-march=i.86//g' -e 's/-mtune=i.86//g'`
1052 %endif
1053 %ifarch s390 s390x
1054 RPM_OPT_FLAGS=`echo $RPM_OPT_FLAGS|sed -e 's/-fsigned-char//g'`
1055 RPM_OPT_FLAGS=`echo $RPM_OPT_FLAGS|sed -e 's/-O1/-O2/g'`
1056 %endif
1057 %if 0%{?gcc_target_arch:1} && 0%{!?gcc_icecream:1}
1058 # Kill all -march/tune/cpu because that screws building the target libs
1059 RPM_OPT_FLAGS=`echo $RPM_OPT_FLAGS|sed -e 's/-m\(arch\|tune\|cpu\)=[^ ]*//g'`
1060 %endif
1061 # Replace 2 spaces by one finally
1062 RPM_OPT_FLAGS=`echo $RPM_OPT_FLAGS|sed -e 's/  / /g'`
1063
1064 languages=c
1065 %if %{build_cp}
1066 languages=$languages,c++
1067 %endif
1068 %if %{build_objc}
1069 languages=$languages,objc
1070 %endif
1071 %if %{build_fortran}
1072 languages=$languages,fortran
1073 %endif
1074 %if %{build_objcp}
1075 languages=$languages,obj-c++
1076 %endif
1077 %if %{build_java}
1078 languages=$languages,java
1079 %endif
1080 %if %{build_ada}
1081 languages=$languages,ada
1082 %endif
1083 %if %{build_go}
1084 languages=$languages,go
1085 %endif
1086
1087 J=%{?jobs:%jobs}
1088 if test -z "$J"; then
1089   J=$(getconf _NPROCESSORS_CONF)
1090   JL=$(($J * 2))
1091 else
1092   test 1 -gt "$J" && J=1
1093   JL=$(($(getconf _NPROCESSORS_CONF)*2))
1094 fi
1095 if test "$J" == "0"; then
1096   J=1
1097 fi
1098 if test "$JL" == "0"; then
1099   JL=1
1100 fi
1101 PARALLEL="-j$J -l$JL"
1102
1103 # we don't want some miscompiles in the testsuite, or some fault in
1104 # the compiler to kill the machine.  Hence we limit the amount of memory
1105 # by the physical RAM plus half of swap
1106 #MEM=$(free -m | awk '/^Mem:/ {print $2}')
1107 #SWAP=$(free -m | awk '/^Swap:/ {print $2}')
1108 #ulimit -v $(((MEM + SWAP/2)*1024))
1109
1110 # In general we want to ship release checking enabled compilers
1111 # and run BETA with checking enabled.
1112 #ENABLE_CHECKING="--enable-checking=yes"
1113 ENABLE_CHECKING="--enable-checking=release"
1114
1115 # Work around tail/head -1 changes
1116 export _POSIX2_VERSION=199209
1117
1118 %if %{build_ada}
1119 # Using the host gnatmake like
1120 #   CC="gcc%{hostsuffix}" GNATBIND="gnatbind%{hostsuffix}"
1121 #   GNATMAKE="gnatmake%{hostsuffix}"
1122 # doesn't work due to PR33857, so an un-suffixed gnatmake has to be
1123 # available
1124 mkdir -p host-tools/bin
1125 cp -a /usr/bin/gnatmake%{hostsuffix} host-tools/bin/gnatmake
1126 cp -a /usr/bin/gnatlink%{hostsuffix} host-tools/bin/gnatlink
1127 cp -a /usr/bin/gnatbind%{hostsuffix} host-tools/bin/gnatbind
1128 cp -a /usr/bin/gcc%{hostsuffix} host-tools/bin/gcc
1129 ln -sf /usr/%{_lib} host-tools/%{_lib}
1130 export PATH="`pwd`/host-tools/bin:$PATH"
1131 %endif
1132 #%if 0%{?gcc_target_arch:1} && 0%{!?gcc_icecream:1}
1133 #%else
1134 #       --enable-threads=posix \
1135 #%endif
1136 #       --enable-shared \
1137 %if "%{TARGET_ARCH}" == "armv7l" || "%{TARGET_ARCH}" == "armv7hl"
1138 # temporary workaround for a miscompilation of hash functions in java code
1139 GCJ_EXTRA_FLAGS="-marm"
1140 %endif
1141
1142 CFLAGS="$RPM_OPT_FLAGS" CXXFLAGS="$RPM_OPT_FLAGS" XCFLAGS="$RPM_OPT_FLAGS" \
1143 TCFLAGS="$RPM_OPT_FLAGS" GCJFLAGS="$RPM_OPT_FLAGS $GCJ_EXTRA_FLAGS" \
1144 ../configure \
1145         --prefix=%{_prefix} \
1146         --infodir=%{_infodir} \
1147         --mandir=%{_mandir} \
1148         --libdir=%{_libdir} \
1149         --libexecdir=%{_libdir} \
1150         --enable-languages=$languages \
1151         $ENABLE_CHECKING \
1152         --with-gxx-include-dir=%{_prefix}/include/c++/%{gcc_dir_version} \
1153         --enable-ssp \
1154         --disable-libssp \
1155         --disable-bootstrap \
1156 %if 0%{!?build_libvtv:1}
1157         --disable-libvtv \
1158 %endif
1159         --disable-plugin \
1160         --with-bugurl="http://bugs.tizen.org/" \
1161         --with-pkgversion="Tizen" \
1162 %if !%{build_fortran}
1163         --disable-libquadmath \
1164 %endif
1165 %if !%{build_libjava}
1166         --disable-libgcj \
1167 %else
1168         --with-java-home=%{_libdir}/jvm/java-1.5.0-gcj%{binsuffix}-1.5.0.0/jre \
1169         --with-ecj-jar=%{libsubdir}/ecj.jar \
1170         --disable-java-awt \
1171 %if !%{biarch_libjava}
1172         --disable-libjava-multilib \
1173 %endif
1174 %endif
1175         --with-slibdir=/%{_lib} \
1176         --with-system-zlib \
1177         --enable-__cxa_atexit \
1178         --enable-libstdcxx-allocator=new \
1179         --disable-libstdcxx-pch \
1180         --enable-version-specific-runtime-libs \
1181         --enable-linker-build-id \
1182         --enable-linux-futex \
1183         --program-suffix=%{binsuffix} \
1184 %if 0%{!?gcc_target_arch:1}
1185 %ifarch ia64
1186         --with-system-libunwind \
1187 %else
1188         --without-system-libunwind \
1189 %endif
1190 %endif
1191 %if 0%{?gcc_target_arch:1}
1192         --program-prefix=%{gcc_target_arch}- \
1193         --target=%{gcc_target_arch} \
1194         --disable-nls \
1195 %if 0%{?sysroot:1}
1196         --with-sysroot=%sysroot \
1197 %else
1198         --with-sysroot=%{_prefix}/%{gcc_target_arch} \
1199 %endif
1200 %if 0%{?build_sysroot:1}
1201         --with-build-sysroot=%{build_sysroot} \
1202 %else
1203 %if 0%{?sysroot:1}
1204         --with-build-sysroot=%{sysroot} \
1205 %else
1206         --with-build-sysroot=%{_prefix}/%{gcc_target_arch} \
1207 %endif
1208 %endif
1209 %if 0%{?canonical_target:1}
1210         --with-build-time-tools=/usr/%{canonical_target}-tizen-linux%{?canonical_target_abi:%canonical_target_abi}/bin \
1211 %endif
1212 %if "%{TARGET_ARCH}" == "spu"
1213         --with-gxx-include-dir=%sysroot/include/c++/%{gcc_dir_version} \
1214         --with-newlib \
1215 %endif
1216 %endif
1217 %if "%{TARGET_ARCH}" == "armv5tel"
1218         --with-arch=armv5te \
1219         --with-float=soft \
1220         --with-mode=arm \
1221         --with-abi=aapcs-linux \
1222         --disable-sjlj-exceptions \
1223 %endif
1224 %if "%{TARGET_ARCH}" == "armv7l"
1225         --with-arch=armv7-a \
1226         --with-tune=cortex-a8 \
1227         --with-float=softfp \
1228         --with-fpu=vfpv3 \
1229         --with-mode=thumb \
1230         --disable-sjlj-exceptions \
1231 %endif
1232 %if "%{TARGET_ARCH}" == "armv7hl"
1233         --with-arch=armv7-a \
1234         --with-tune=cortex-a9 \
1235         --with-float=hard \
1236         --with-abi=aapcs-linux \
1237         --with-fpu=vfpv3-d16 \
1238         --disable-sjlj-exceptions \
1239 %endif
1240 %if  "%{TARGET_ARCH}" == "aarch64"
1241         --with-arch=armv8-a \
1242         --disable-sjlj-exceptions \
1243 %endif
1244 %if "%{TARGET_ARCH}" == "powerpc" || "%{TARGET_ARCH}" == "powerpc64"
1245 %if "%{TARGET_ARCH}" == "powerpc"
1246         --with-cpu=default32 \
1247 %endif
1248 %if "%{TARGET_ARCH}" == "powerpc64le"
1249         --with-cpu=power7 \
1250 %else
1251         --with-cpu-64=power4 \
1252 %endif
1253         --enable-secureplt \
1254         --with-long-double-128 \
1255 %if "%{TARGET_ARCH}" == "powerpc64le"
1256         --disable-multilib \
1257 %endif
1258 %endif
1259 %if "%{TARGET_ARCH}" == "sparc64"
1260         --with-cpu=ultrasparc \
1261         --with-long-double-128 \
1262 %endif
1263 %if "%{TARGET_ARCH}" == "sparc"
1264         --with-cpu=v8 \
1265         --with-long-double-128 \
1266 %endif
1267 %if "%{TARGET_ARCH}" == "i586"
1268         --with-arch-32=i586 \
1269         --with-tune=generic \
1270 %endif
1271 %if "%{TARGET_ARCH}" == "x86_64"
1272         --with-arch-32=i586 \
1273         --with-tune=generic \
1274         --enable-multilib \
1275 %endif
1276 %if "%{TARGET_ARCH}" == "s390"
1277         --with-tune=zEC12 --with-arch=z196 \
1278         --with-long-double-128 \
1279         --enable-decimal-float \
1280 %endif
1281 %if "%{TARGET_ARCH}" == "s390x"
1282         --with-tune=zEC12 --with-arch=z196 \
1283         --with-long-double-128 \
1284         --enable-decimal-float \
1285 %endif
1286 %if "%{TARGET_ARCH}" == "m68k"
1287         --disable-multilib \
1288 %endif
1289         --build=%{GCCDIST} \
1290         --host=%{GCCDIST}
1291
1292 # COMMON-END
1293
1294 %if 0%{?building_libffi:1}
1295 make stage1-bubble $PARALLEL
1296 make all-target-libffi $PARALLEL
1297 %else
1298 STAGE1_FLAGS="-g"
1299 # Only run profiled bootstrap on archs where it works and matters
1300 %ifarch ppc64le s390x
1301 make profiledbootstrap STAGE1_CFLAGS="$STAGE1_FLAGS" BOOT_CFLAGS="$RPM_OPT_FLAGS" $PARALLEL
1302 %else
1303 make STAGE1_CFLAGS="$STAGE1_FLAGS" BOOT_CFLAGS="$RPM_OPT_FLAGS" $PARALLEL
1304 %endif
1305 make info
1306 %if 0%{?building_libjava:1}
1307 make -C %{GCCDIST}/libstdc++-v3/doc doc-html-doxygen
1308 %endif
1309 %if 0%{?run_tests:1}
1310 echo "Run testsuite"
1311 (make -C %{GCCDIST}/libstdc++-v3 check-abi || true)
1312 mv %{GCCDIST}/libstdc++-v3/testsuite/libstdc++.log %{GCCDIST}/libstdc++-v3/testsuite/libstdc++-abi.log
1313 mv %{GCCDIST}/libstdc++-v3/testsuite/libstdc++.sum %{GCCDIST}/libstdc++-v3/testsuite/libstdc++-abi.sum
1314 # asan needs a whole shadow address space
1315 ulimit -v unlimited || true
1316 make -k check $PARALLEL || true
1317 mkdir ../testresults
1318 ../contrib/test_summary | tee ../testresults/test_summary.txt
1319 %endif
1320 %endif
1321
1322 %install
1323 export NO_BRP_CHECK_BYTECODE_VERSION=true
1324 cd obj-%{GCCDIST}
1325 # GCC-TESTSUITE-DELETE-BEGIN
1326 # Work around tail/head -1 changes
1327 export _POSIX2_VERSION=199209
1328 export LIBRARY_PATH=$RPM_BUILD_ROOT%{libsubdir}:$RPM_BUILD_ROOT%{mainlibdirbi}
1329 %if 0%{?building_libffi:1}
1330 make -C %{GCCDIST}/libffi install DESTDIR=$RPM_BUILD_ROOT
1331 %else
1332 %if 0%{?building_libjava:1}
1333 make -C %{GCCDIST}/libjava install DESTDIR=$RPM_BUILD_ROOT
1334 make -C gcc java.install-man DESTDIR=$RPM_BUILD_ROOT
1335 make -C gcc java.install-common DESTDIR=$RPM_BUILD_ROOT
1336 make -C gcc install-common DESTDIR=$RPM_BUILD_ROOT COMPILERS='jc1$(exeext) jvgenmain$(exeext)'
1337 # copy the libstdc++ API reference
1338 cp -r %{GCCDIST}/libstdc++-v3/doc/doxygen/html ../libstdc++-v3/doc/html/api
1339 # install-common also installs collect2, gcov and the g++ and gfortran driver
1340 %if %{build_cp}
1341 rm $RPM_BUILD_ROOT%{_prefix}/bin/g++%{binsuffix}
1342 %endif
1343 %if %{build_fortran}
1344 rm $RPM_BUILD_ROOT%{_prefix}/bin/gfortran%{binsuffix}
1345 %endif
1346 rm $RPM_BUILD_ROOT%{_prefix}/bin/gcov%{binsuffix}
1347 rm $RPM_BUILD_ROOT%{libsubdir}/collect2
1348 %else
1349 make install DESTDIR=$RPM_BUILD_ROOT
1350 %if %{build_java}
1351 make -C gcc java.uninstall DESTDIR=$RPM_BUILD_ROOT
1352 make -C gcc java.install-info DESTDIR=$RPM_BUILD_ROOT
1353 rm $RPM_BUILD_ROOT%{_prefix}/bin/jcf-dump%{binsuffix}
1354 rm $RPM_BUILD_ROOT%{_mandir}/man1/jcf-dump%{binsuffix}.1
1355 rm $RPM_BUILD_ROOT%{libsubdir}/jc1
1356 rm $RPM_BUILD_ROOT%{libsubdir}/jvgenmain
1357 %endif
1358 %endif
1359 %endif
1360
1361 # Remove libffi installed files if we did not want to build it
1362 %if !0%{?building_libffi:1}
1363 rm -f $RPM_BUILD_ROOT%{mainlibdir}/libffi.*
1364 %if %{biarch}
1365   rm -f $RPM_BUILD_ROOT%{mainlibdirbi}/libffi.*
1366 %endif
1367 rm -f $RPM_BUILD_ROOT%{libsubdir}/include/ffi.h
1368 rm -f $RPM_BUILD_ROOT%{libsubdir}/include/ffitarget.h
1369 rm -f $RPM_BUILD_ROOT%{_mandir}/man3/ffi%{binsuffix}.3*
1370 rm -f $RPM_BUILD_ROOT%{_mandir}/man3/ffi_call%{binsuffix}.3*
1371 rm -f $RPM_BUILD_ROOT%{_mandir}/man3/ffi_prep_cif%{binsuffix}.3*
1372 rm -f $RPM_BUILD_ROOT%{_mandir}/man3/ffi_prep_cif_var%{binsuffix}.3*
1373 %endif
1374
1375 # Remove some useless .la files
1376 for lib in libobjc libgfortran libgfortranbegin libquadmath libcaf_single \
1377     libgomp libstdc++ libsupc++ libgcj-tools libgij libgo \
1378     libasan libatomic libitm libtsan libcilkrts liblsan libubsan libvtv; do
1379   rm -f $RPM_BUILD_ROOT%{versmainlibdir}/$lib.la
1380 %if %{biarch}
1381   rm -f $RPM_BUILD_ROOT%{versmainlibdirbi}/$lib.la
1382 %endif
1383 done
1384
1385 mkdir -p $RPM_BUILD_ROOT%{_libdir}
1386 %if %{biarch}
1387 %if %{build_primary_64bit}
1388 mkdir -p $RPM_BUILD_ROOT%{_prefix}/lib
1389 %else
1390 mkdir -p $RPM_BUILD_ROOT%{_prefix}/lib64
1391 %endif
1392 %endif
1393
1394 # LIBFFI-DELETE-BEGIN
1395 # LIBJAVA-DELETE-BEGIN
1396 %if %{build_cp}
1397 # Merge multilib c++config.h to allow omitting the duplicate and
1398 # identical other arch specific headers
1399 dir_ml=
1400 cxxconfig="`find %{GCCDIST}/libstdc++-v3/include -name c++config.h`"
1401 for i in `find %{GCCDIST}/[36]*/libstdc++-v3/include -name c++config.h 2>/dev/null`; do
1402   if ! diff -up $cxxconfig $i; then
1403     file_32=x
1404     file_64=x
1405     case $i in
1406       %{GCCDIST}/32/*)
1407         file_32=$i
1408         file_64=$cxxconfig
1409         dir_ml=32
1410         ;;
1411       %{GCCDIST}/64/*)
1412         file_32=$cxxconfig
1413         file_64=$i
1414         dir_ml=64
1415         ;;
1416     esac
1417     if ! ( test -f "$file_32" && test -f "$file_64" ); then
1418       echo "Urgs?"
1419       exit 1
1420     fi
1421
1422     cat > $RPM_BUILD_ROOT%{_prefix}/include/c++/%{gcc_dir_version}/%{GCCDIST}/bits/c++config.h <<EOF
1423 #ifndef _CPP_CPPCONFIG_WRAPPER
1424 #define _CPP_CPPCONFIG_WRAPPER 1
1425 #include <bits/wordsize.h>
1426 #if __WORDSIZE == 32
1427 `cat $file_32`
1428 #else
1429 `cat $file_64`
1430 #endif
1431 #endif
1432 EOF
1433     break
1434   fi
1435 done
1436 rm -rf $RPM_BUILD_ROOT%{_prefix}/include/c++/%{gcc_dir_version}/%{GCCDIST}/[36]*
1437 if ! test -z "$dir_ml"; then
1438   ln -s . $RPM_BUILD_ROOT%{_prefix}/include/c++/%{gcc_dir_version}/%{GCCDIST}/$dir_ml
1439 fi
1440 %endif
1441 # LIBJAVA-DELETE-END
1442
1443 # move shared libs from versionspecific dir to main libdir
1444 for libname in \
1445 %if 0%{?building_libjava:1}
1446   libgcj libgij libgcj-tools \
1447 %else
1448 %if %{build_fortran}
1449   libgfortran \
1450 %ifarch %quadmath_arch
1451   libquadmath \
1452 %endif
1453 %endif
1454 %if %{build_objc}
1455   libobjc \
1456 %endif
1457 %if %{build_cp}
1458   libstdc++ \
1459 %endif
1460 %if %{build_go}
1461   libgo \
1462 %endif
1463   libgomp \
1464 %ifarch %atomic_arch
1465   libatomic \
1466 %endif
1467 %ifarch %itm_arch
1468   libitm \
1469 %endif
1470 %ifarch %asan_arch
1471   libasan \
1472 %endif
1473 %ifarch %tsan_arch
1474   libtsan \
1475 %endif
1476 %ifarch %cilkrts_arch
1477   libcilkrts \
1478 %endif
1479 %ifarch %lsan_arch
1480   liblsan \
1481 %endif
1482 %ifarch %ubsan_arch
1483   libubsan \
1484 %endif
1485 %ifarch %vtv_arch
1486   libvtv \
1487 %endif
1488 %endif
1489     ; do
1490   for lib in `find $RPM_BUILD_ROOT%{versmainlibdir} -maxdepth 1 -name $libname.so.*`; do
1491     mv $lib $RPM_BUILD_ROOT%{mainlibdir}/
1492   done
1493   ln -sf %{mainlibdir}/`readlink $RPM_BUILD_ROOT%{versmainlibdir}/$libname.so | sed -e 's/\(.*\.so\.[^\.]*\).*/\1/'`  \
1494          $RPM_BUILD_ROOT%{versmainlibdir}/$libname.so
1495 %if %{biarch}
1496   if test -d $RPM_BUILD_ROOT%{versmainlibdirbi}; then
1497     for lib in `find $RPM_BUILD_ROOT%{versmainlibdirbi} -maxdepth 1 -name "$libname.so.*"`; do
1498       mv $lib $RPM_BUILD_ROOT%{mainlibdirbi}/
1499     done
1500     ln -sf %{mainlibdirbi}/`readlink $RPM_BUILD_ROOT%{versmainlibdirbi}/$libname.so | sed -e 's/\(.*\.so\.[^\.]*\).*/\1/'`  \
1501          $RPM_BUILD_ROOT%{versmainlibdirbi}/$libname.so
1502   fi
1503 %endif
1504 done
1505 # FIXME, tsan and lsan are not multilib
1506 %ifarch %tsan_arch
1507 %if %{biarch}
1508 rm -f $RPM_BUILD_ROOT%{versmainlibdirbi}/libtsan.so
1509 %endif
1510 %endif
1511 %ifarch %lsan_arch
1512 %if %{biarch}
1513 rm -f $RPM_BUILD_ROOT%{versmainlibdirbi}/liblsan.so
1514 %endif
1515 %endif
1516 %if %{build_cp}
1517 %if !0%{?building_libjava:1}
1518 # And we want to move the shlib gdb pretty printers to a more sane
1519 # place so ldconfig does not complain
1520 mkdir -p $RPM_BUILD_ROOT%{_datadir}/gdb/auto-load%{mainlibdir}
1521 mv $RPM_BUILD_ROOT%{mainlibdir}/libstdc++.so.*-gdb.py $RPM_BUILD_ROOT%{_datadir}/gdb/auto-load%{mainlibdir}/
1522 sed -i -e '/^libdir/s/\/gcc\/%{GCCDIST}\/%{gcc_dir_version}//g' $RPM_BUILD_ROOT%{_datadir}/gdb/auto-load%{mainlibdir}/libstdc++.so.*-gdb.py
1523 %if %{biarch}
1524   if test -d $RPM_BUILD_ROOT%{versmainlibdirbi}; then
1525     mkdir -p $RPM_BUILD_ROOT%{_datadir}/gdb/auto-load%{mainlibdirbi}
1526     mv $RPM_BUILD_ROOT%{mainlibdirbi}/libstdc++.so.*-gdb.py $RPM_BUILD_ROOT%{_datadir}/gdb/auto-load%{mainlibdirbi}/
1527     sed -i -e '/^libdir/s/\/gcc\/%{GCCDIST}\/%{gcc_dir_version}//g' $RPM_BUILD_ROOT%{_datadir}/gdb/auto-load%{mainlibdirbi}/libstdc++.so.*-gdb.py
1528   fi
1529 %endif
1530 %endif
1531 %endif
1532 %if 0%{?building_libjava:1}
1533 # libgcj_bc is special as the .so file is actually a different
1534 # library as the library refered to by the SONAME which should
1535 # be a simple link to our libgcj.
1536 for lib in `find $RPM_BUILD_ROOT%{versmainlibdir} -maxdepth 1 -name libgcj_bc.so.*`; do
1537   rm $lib
1538 done
1539 ln -s libgcj.so.%{libgcj_sover} $RPM_BUILD_ROOT%{mainlibdir}/libgcj_bc.so.%{libgcj_bc_sover}
1540 %if %{biarch_libjava}
1541 for lib in `find $RPM_BUILD_ROOT%{versmainlibdirbi} -maxdepth 1 -name libgcj_bc.so.*`; do
1542   rm $lib
1543 done
1544 ln -s libgcj.so.%{libgcj_sover} $RPM_BUILD_ROOT%{mainlibdirbi}/libgcj_bc.so.%{libgcj_bc_sover}
1545 %endif
1546 mv $RPM_BUILD_ROOT%{libsubdir}/pkgconfig $RPM_BUILD_ROOT%{_libdir}/
1547 %endif
1548
1549 # LIBJAVA-DELETE-BEGIN
1550 # Move libgcc_s around
1551 %ifarch aarch64
1552 if test -L $RPM_BUILD_ROOT/lib64/libgcc_s.so; then
1553   rm -f $RPM_BUILD_ROOT/lib64/libgcc_s.so
1554   ln -sf /lib64/libgcc_s.so.%{libgcc_s} $RPM_BUILD_ROOT%{versmainlibdir}/libgcc_s.so
1555 else
1556   mv $RPM_BUILD_ROOT/lib64/libgcc_s.so $RPM_BUILD_ROOT%{versmainlibdir}/
1557 fi
1558 chmod a+x $RPM_BUILD_ROOT/lib64/libgcc_s.so.%{libgcc_s}
1559 %else
1560 if test -L $RPM_BUILD_ROOT/%{_lib}/libgcc_s.so; then
1561   rm -f $RPM_BUILD_ROOT/%{_lib}/libgcc_s.so
1562   ln -sf /%{_lib}/libgcc_s.so.%{libgcc_s} $RPM_BUILD_ROOT%{versmainlibdir}/libgcc_s.so
1563 else
1564   mv $RPM_BUILD_ROOT/%{_lib}/libgcc_s.so $RPM_BUILD_ROOT%{versmainlibdir}/
1565 fi
1566 chmod a+x $RPM_BUILD_ROOT/%{_lib}/libgcc_s.so.%{libgcc_s}
1567 %endif
1568
1569 %if %{biarch}
1570 %if %{build_primary_64bit}
1571 if test -L $RPM_BUILD_ROOT/lib/libgcc_s.so; then
1572   rm -f $RPM_BUILD_ROOT/lib/libgcc_s.so
1573   ln -sf /lib/libgcc_s.so.%{libgcc_s} $RPM_BUILD_ROOT%{versmainlibdirbi32}/libgcc_s.so
1574 else
1575   mv $RPM_BUILD_ROOT/lib/libgcc_s.so $RPM_BUILD_ROOT%{versmainlibdirbi32}/
1576 fi
1577 ln -sf %{versmainlibdirbi32}/libgcc_s.so $RPM_BUILD_ROOT%{versmainlibdirbi32}/libgcc_s_32.so
1578 chmod a+x $RPM_BUILD_ROOT/lib/libgcc_s.so.%{libgcc_s}
1579 %else
1580 # 32-bit biarch systems
1581 if test -L $RPM_BUILD_ROOT/lib64/libgcc_s.so; then
1582   rm -f $RPM_BUILD_ROOT/lib64/libgcc_s.so
1583   ln -sf /lib64/libgcc_s.so.%{libgcc_s} $RPM_BUILD_ROOT%{versmainlibdirbi64}/libgcc_s.so
1584 else
1585   mv $RPM_BUILD_ROOT/lib64/libgcc_s.so $RPM_BUILD_ROOT%{versmainlibdirbi64}/
1586 fi
1587 ln -sf %{versmainlibdirbi64}/libgcc_s.so $RPM_BUILD_ROOT%{versmainlibdirbi64}/libgcc_s_64.so
1588 chmod a+x $RPM_BUILD_ROOT/lib64/libgcc_s.so.%{libgcc_s}
1589 %endif
1590 %endif
1591
1592 # LIBJAVA-DELETE-END
1593 # LIBFFI-DELETE-END
1594
1595 %if %{build_ada}
1596 mv $RPM_BUILD_ROOT%{libsubdir}/adalib/lib*-*.so $RPM_BUILD_ROOT%{_libdir}
1597 ln -sf %{_libdir}/libgnarl%{binsuffix}.so $RPM_BUILD_ROOT%{libsubdir}/adalib/libgnarl.so
1598 ln -sf %{_libdir}/libgnat%{binsuffix}.so $RPM_BUILD_ROOT%{libsubdir}/adalib/libgnat.so
1599 chmod a+x $RPM_BUILD_ROOT%{_libdir}/libgna*-*.so
1600 %if %{biarch}
1601 mv $RPM_BUILD_ROOT%{versmainlibdirbi}/adalib/lib*-*.so $RPM_BUILD_ROOT%{mainlibdirbi}/
1602 ln -sf %{mainlibdirbi}/libgnarl%{binsuffix}.so $RPM_BUILD_ROOT%{versmainlibdirbi}/adalib/libgnarl.so
1603 ln -sf %{mainlibdirbi}/libgnat%{binsuffix}.so $RPM_BUILD_ROOT%{versmainlibdirbi}/adalib/libgnarl.so
1604 chmod a+x $RPM_BUILD_ROOT%{mainlibdirbi}/libgna*-*.so
1605 %endif
1606 %endif
1607
1608 rm -f $RPM_BUILD_ROOT%{_prefix}/bin/c++%{binsuffix}
1609
1610 # Remove some crap from the .la files:
1611 for l in `find $RPM_BUILD_ROOT -name '*.la'`; do
1612   echo "changing $l"
1613 # -e '/^dependency_libs/s|%{libsubdir}/\([^.]*\)\.la |%{_libdir}/\1\.la |g'
1614   sed -e '/^dependency_libs/s| -L%{_builddir}/[^ ]*||g' \
1615       -e '/^dependency_libs/s| -L/usr/%{GCCDIST}/bin||g' \
1616       -e '/^dependency_libs/s|-lm \(-lm \)*|-lm |' \
1617       -e '/^dependency_libs/s|-L[^ ]* ||g' \
1618 %if %{biarch}
1619 %if %{build_primary_64bit}
1620       -e '/^libdir/s|%{_libdir}/32|%{_prefix}/lib|' \
1621       -e '/^libdir/s|lib64/\.\./||' \
1622 %else
1623       -e '/^libdir/s|%{_libdir}/64|%{_prefix}/lib64|' \
1624 %endif
1625 %endif
1626       < $l  > $l.new
1627   mv $l.new $l
1628 done
1629
1630 # GCC-TESTSUITE-DELETE-END
1631 %if 0%{?run_tests:1}
1632 cp `find . -name "*.sum"` ../testresults/
1633 cp `find . -name "*.log"  \! -name "config.log" | grep -v 'acats.\?/tests' ` ../testresults/
1634 chmod 644 ../testresults/*
1635 %endif
1636 # GCC-TESTSUITE-DELETE-BEGIN
1637 # LIBFFI-DELETE-BEGIN
1638 %if %{build_cp}
1639 # Find C++ and Java headers
1640 find $RPM_BUILD_ROOT%{_prefix}/include/c++ \
1641   -regex ".*/\(org\|gcj\|gnu\|java\|javax\)" -prune \
1642   -o \( -type d -printf "%%%%dir " , \
1643         -printf "%{_prefix}/include/c++/%%P\n" \) > ../c++-headers
1644 %endif
1645 # LIBFFI-DELETE-END
1646 # Remove files that we do not need to clean up filelist
1647 rm -f $RPM_BUILD_ROOT%{_prefix}/bin/%{GCCDIST}-*
1648 rm -rf $RPM_BUILD_ROOT%{libsubdir}/install-tools
1649 #rm -rf $RPM_BUILD_ROOT%{_libdir}/pkgconfig/libgcj%{binsuffix}.pc
1650 rm -f $RPM_BUILD_ROOT%{libsubdir}/include-fixed/zutil.h
1651 rm -f $RPM_BUILD_ROOT%{libsubdir}/include-fixed/linux/a.out.h
1652 rm -f $RPM_BUILD_ROOT%{libsubdir}/include-fixed/asm-generic/socket.h
1653 # no plugins
1654 rm -rf $RPM_BUILD_ROOT%{libsubdir}/plugin
1655 rm -f  $RPM_BUILD_ROOT%{_infodir}/dir
1656
1657
1658 %if 0%{?building_libjava:1}
1659 # gcj -static doesn't work properly anyway, unless using --whole-archive
1660 # let's save the space instead.
1661 find $RPM_BUILD_ROOT -name libgcj.a \
1662         -o -name libgcj-tools.a \
1663         -o -name libgij.a \
1664         -o -name libjvm.a \
1665         -o -name libgcj_bc.a \
1666   | xargs rm -f
1667
1668 find $RPM_BUILD_ROOT -name libgcj.spec | xargs \
1669   sed -i -e 's/lib: /&%%{static:%%eJava programs cannot be linked statically}/'
1670
1671 # security files have broken install locations, also they cause conflicts
1672 # between libgcj versions.  Simply delete them here, libgcj will use its
1673 # defaults in this case (which is what these files contain anyway).
1674 rm -f $RPM_BUILD_ROOT%{libsubdir}/logging.properties
1675 rm -r $RPM_BUILD_ROOT%{libsubdir}/security
1676 %endif
1677
1678 %if 0%{?building_libffi:1}
1679 # Move libffi headers, remove empty libffi libtool file
1680 mkdir -p $RPM_BUILD_ROOT%{_prefix}/include
1681 mv $RPM_BUILD_ROOT%{libsubdir}/include/ffitarget.h $RPM_BUILD_ROOT%{_prefix}/include/
1682 mv $RPM_BUILD_ROOT%{libsubdir}/include/ffi.h $RPM_BUILD_ROOT%{_prefix}/include/
1683 rm -f $RPM_BUILD_ROOT%{mainlibdir}/libffi.la
1684 %if %{biarch}
1685 rm -f $RPM_BUILD_ROOT%{mainlibdirbi}/libffi.la
1686 %endif
1687 # Generate a simple pkg-config file
1688 mkdir -p $RPM_BUILD_ROOT%{_libdir}/pkgconfig
1689 echo -e 'Name: libffi\nVersion: 3.0.9\nDescription: libffi\nLibs: -lffi' > $RPM_BUILD_ROOT%{_libdir}/pkgconfig/libffi.pc
1690 %endif
1691
1692 %if %{build_java}
1693 %if !%{build_libjava}
1694 rm $RPM_BUILD_ROOT%{_mandir}/man1/jv-convert%{binsuffix}.1
1695 rm $RPM_BUILD_ROOT%{_mandir}/man1/gcj-dbtool%{binsuffix}.1
1696 rm $RPM_BUILD_ROOT%{_mandir}/man1/gij%{binsuffix}.1
1697 rm $RPM_BUILD_ROOT%{_mandir}/man1/grmic%{binsuffix}.1
1698 rm $RPM_BUILD_ROOT%{_mandir}/man1/gc-analyze%{binsuffix}.1
1699 rm $RPM_BUILD_ROOT%{_mandir}/man1/aot-compile%{binsuffix}.1
1700 rm $RPM_BUILD_ROOT%{_mandir}/man1/rebuild-gcj-db%{binsuffix}.1
1701 %endif
1702 rm -f $RPM_BUILD_ROOT%{_datadir}/gcc%{binsuffix}/python/libjava/aotcompile.py
1703 rm -f $RPM_BUILD_ROOT%{_datadir}/gcc%{binsuffix}/python/libjava/classfile.py
1704 %endif
1705 rm -f $RPM_BUILD_ROOT%{_mandir}/man7/fsf-funding.7
1706 rm -f $RPM_BUILD_ROOT%{_mandir}/man7/gfdl.7
1707 rm -f $RPM_BUILD_ROOT%{_mandir}/man7/gpl.7
1708 rm -f $RPM_BUILD_ROOT%{_libdir}/libiberty.a
1709 %if %{biarch}
1710 %if %{build_primary_64bit}
1711 rm -f $RPM_BUILD_ROOT%{_prefix}/lib/libiberty.a
1712 %else
1713 rm -f $RPM_BUILD_ROOT%{_prefix}/lib64/libiberty.a
1714 %endif
1715 %endif
1716 rm -f $RPM_BUILD_ROOT%{libsubdir}/liblto_plugin.a
1717 rm -f $RPM_BUILD_ROOT%{libsubdir}/liblto_plugin.la
1718 %if %{build_go}
1719 # gccgo.info isn't properly versioned
1720 rm $RPM_BUILD_ROOT%{_infodir}/gccgo.info*
1721 %endif
1722
1723 # LIBFFI-DELETE-BEGIN
1724 %if 0%{?building_libjava:1}
1725 # For building libjava only we need to delete other info docs
1726 rm $RPM_BUILD_ROOT%{_infodir}/cp-tools.info*
1727 # Remove stale manpages for binaries we do not build
1728 rm $RPM_BUILD_ROOT%{_mandir}/man1/gjdoc%{binsuffix}.1
1729 # For building the java frontend we need to copy the ecj jar
1730 mkdir -p $RPM_BUILD_ROOT%{libsubdir}
1731 cp $RPM_SOURCE_DIR/ecj.jar $RPM_BUILD_ROOT%{libsubdir}
1732 %else
1733 # For regular build, some info files do not get renamed properly.
1734 # Do so here.
1735 mv $RPM_BUILD_ROOT%{_infodir}/libgomp.info $RPM_BUILD_ROOT%{_infodir}/libgomp%{binsuffix}.info
1736 %ifarch %itm_arch
1737 mv $RPM_BUILD_ROOT%{_infodir}/libitm.info $RPM_BUILD_ROOT%{_infodir}/libitm%{binsuffix}.info
1738 %endif
1739 %if %{build_fortran}
1740 %ifarch %quadmath_arch
1741 mv $RPM_BUILD_ROOT%{_infodir}/libquadmath.info $RPM_BUILD_ROOT%{_infodir}/libquadmath%{binsuffix}.info
1742 %endif
1743 %endif
1744 %if %{build_ada}
1745 mv $RPM_BUILD_ROOT%{_infodir}/gnat-style.info $RPM_BUILD_ROOT%{_infodir}/gnat-style%{binsuffix}.info
1746 mv $RPM_BUILD_ROOT%{_infodir}/gnat_rm.info $RPM_BUILD_ROOT%{_infodir}/gnat_rm%{binsuffix}.info
1747 mv $RPM_BUILD_ROOT%{_infodir}/gnat_ugn.info $RPM_BUILD_ROOT%{_infodir}/gnat_ugn%{binsuffix}.info
1748 %endif
1749 %endif
1750
1751 %ifnarch %quadmath_arch
1752 rm -vf $RPM_BUILD_ROOT%{_infodir}/libquadmath*.info*
1753 %endif
1754
1755 # LIBJAVA-DELETE-BEGIN
1756 cd ..
1757 %find_lang cpplib%{binsuffix}
1758 %find_lang gcc%{binsuffix}
1759 %find_lang libstdc++
1760 cat cpplib%{binsuffix}.lang gcc%{binsuffix}.lang > gcc@base_ver@-locale.lang
1761
1762 %post info
1763 %install_info --info-dir=%{_infodir} %{_infodir}/cpp%{binsuffix}.info.gz
1764 %install_info --info-dir=%{_infodir} %{_infodir}/cppinternals%{binsuffix}.info.gz
1765 %install_info --info-dir=%{_infodir} %{_infodir}/gcc%{binsuffix}.info.gz
1766 %install_info --info-dir=%{_infodir} %{_infodir}/gccint%{binsuffix}.info.gz
1767 %install_info --info-dir=%{_infodir} %{_infodir}/gccinstall%{binsuffix}.info.gz
1768 %install_info --info-dir=%{_infodir} %{_infodir}/libgomp%{binsuffix}.info.gz
1769 %if %{build_fortran}
1770 %install_info --info-dir=%{_infodir} %{_infodir}/gfortran%{binsuffix}.info.gz
1771 %ifarch %quadmath_arch
1772 %install_info --info-dir=%{_infodir} %{_infodir}/libquadmath%{binsuffix}.info.gz
1773 %endif
1774 %endif
1775 %if %{build_java}
1776 %install_info --info-dir=%{_infodir} %{_infodir}/gcj%{binsuffix}.info.gz
1777 %endif
1778 %if %{build_ada}
1779 %install_info --info-dir=%{_infodir} %{_infodir}/gnat-style%{binsuffix}.info.gz
1780 %install_info --info-dir=%{_infodir} %{_infodir}/gnat_rm%{binsuffix}.info.gz
1781 %install_info --info-dir=%{_infodir} %{_infodir}/gnat_ugn%{binsuffix}.info.gz
1782 %endif
1783
1784 %postun info
1785 %install_info_delete --info-dir=%{_infodir} %{_infodir}/cpp%{binsuffix}.info.gz
1786 %install_info_delete --info-dir=%{_infodir} %{_infodir}/cppinternals%{binsuffix}.info.gz
1787 %install_info_delete --info-dir=%{_infodir} %{_infodir}/gcc%{binsuffix}.info.gz
1788 %install_info_delete --info-dir=%{_infodir} %{_infodir}/gccint%{binsuffix}.info.gz
1789 %install_info_delete --info-dir=%{_infodir} %{_infodir}/gccinstall%{binsuffix}.info.gz
1790 %install_info_delete --info-dir=%{_infodir} %{_infodir}/libgomp%{binsuffix}.info.gz
1791 %if %{build_fortran}
1792 %install_info_delete --info-dir=%{_infodir} %{_infodir}/gfortran%{binsuffix}.info.gz
1793 %ifarch %quadmath_arch
1794 %install_info_delete --info-dir=%{_infodir} %{_infodir}/libquadmath%{binsuffix}.info.gz
1795 %endif
1796 %endif
1797 %if %{build_java}
1798 %install_info_delete --info-dir=%{_infodir} %{_infodir}/gcj%{binsuffix}.info.gz
1799 %endif
1800 %if %{build_ada}
1801 %install_info_delete --info-dir=%{_infodir} %{_infodir}/gnat-style%{binsuffix}.info.gz
1802 %install_info_delete --info-dir=%{_infodir} %{_infodir}/gnat_rm%{binsuffix}.info.gz
1803 %install_info_delete --info-dir=%{_infodir} %{_infodir}/gnat_ugn%{binsuffix}.info.gz
1804 %endif
1805
1806 %files
1807 %defattr(-,root,root)
1808 %dir %{_libdir}/gcc
1809 %dir %{_libdir}/gcc/%{GCCDIST}
1810 %dir %{libsubdir}
1811 %dir %{libsubdir}/include
1812 %dir %{libsubdir}/include-fixed
1813 %if %{biarch}
1814 %if %{build_primary_64bit}
1815 %dir %{libsubdir}/32
1816 %else
1817 %dir %{libsubdir}/64
1818 %endif
1819 %endif
1820 %{_prefix}/bin/gcc%{binsuffix}
1821 %{_prefix}/bin/gcov%{binsuffix}
1822 %{_prefix}/bin/gcc-ar%{binsuffix}
1823 %{_prefix}/bin/gcc-nm%{binsuffix}
1824 %{_prefix}/bin/gcc-ranlib%{binsuffix}
1825 %{libsubdir}/collect2
1826 %{libsubdir}/lto1
1827 %{libsubdir}/lto-wrapper
1828 %{libsubdir}/liblto_plugin.so*
1829 %{libsubdir}/include-fixed/README
1830 %{libsubdir}/include-fixed/limits.h
1831 %{libsubdir}/include-fixed/syslimits.h
1832 %{libsubdir}/include/omp.h
1833 %{libsubdir}/include/float.h
1834 %{libsubdir}/include/iso646.h
1835 %{libsubdir}/include/stdarg.h
1836 %{libsubdir}/include/stdbool.h
1837 %{libsubdir}/include/stdfix.h
1838 %{libsubdir}/include/stddef.h
1839 %{libsubdir}/include/unwind.h
1840 %{libsubdir}/include/varargs.h
1841 %{libsubdir}/include/stdint.h
1842 %{libsubdir}/include/stdint-gcc.h
1843 %{libsubdir}/include/stdnoreturn.h
1844 %{libsubdir}/include/stdalign.h
1845 %{libsubdir}/include/stdatomic.h
1846 %ifarch %asan_arch %ubsan_arch %tsan_arch %lsan_arch
1847 %{libsubdir}/include/sanitizer/*.h
1848 %endif
1849 %ifarch %sparc
1850 %{libsubdir}/include/visintrin.h
1851 %endif
1852 %ifarch ppc ppc64 ppc64le
1853 %{libsubdir}/include/altivec.h
1854 %{libsubdir}/include/ppc-asm.h
1855 %{libsubdir}/include/paired.h
1856 %{libsubdir}/include/ppu_intrinsics.h
1857 %{libsubdir}/include/si2vmx.h
1858 %{libsubdir}/include/spe.h
1859 %{libsubdir}/include/spu2vmx.h
1860 %{libsubdir}/include/vec_types.h
1861 %{libsubdir}/include/htmintrin.h
1862 %{libsubdir}/include/htmxlintrin.h
1863 %endif
1864 %ifarch s390 s390x
1865 %{libsubdir}/include/htmintrin.h
1866 %{libsubdir}/include/htmxlintrin.h
1867 %{libsubdir}/include/s390intrin.h
1868 %endif
1869 %ifarch ia64
1870 %{libsubdir}/include/ia64intrin.h
1871 %endif
1872 %ifarch %arm aarch64
1873 %{libsubdir}/include/arm_neon.h
1874 %endif
1875 %ifarch %arm
1876 %{libsubdir}/include/mmintrin.h
1877 %{libsubdir}/include/arm_neon.h
1878 %{libsubdir}/include/unwind-arm-common.h
1879 %{libsubdir}/include/arm_acle.h
1880 %endif
1881 %ifarch %ix86 x86_64
1882 %{libsubdir}/include/cross-stdarg.h
1883 %{libsubdir}/include/cpuid.h
1884 %{libsubdir}/include/mm3dnow.h
1885 %{libsubdir}/include/mmintrin.h
1886 %{libsubdir}/include/ammintrin.h
1887 %{libsubdir}/include/bmmintrin.h
1888 %{libsubdir}/include/emmintrin.h
1889 %{libsubdir}/include/immintrin.h
1890 %{libsubdir}/include/avxintrin.h
1891 %{libsubdir}/include/pmmintrin.h
1892 %{libsubdir}/include/xmmintrin.h
1893 %{libsubdir}/include/tmmintrin.h
1894 %{libsubdir}/include/nmmintrin.h
1895 %{libsubdir}/include/smmintrin.h
1896 %{libsubdir}/include/wmmintrin.h
1897 %{libsubdir}/include/x86intrin.h
1898 %{libsubdir}/include/ia32intrin.h
1899 %{libsubdir}/include/mm_malloc.h
1900 %{libsubdir}/include/fma4intrin.h
1901 %{libsubdir}/include/xopintrin.h
1902 %{libsubdir}/include/lwpintrin.h
1903 %{libsubdir}/include/popcntintrin.h
1904 %{libsubdir}/include/bmiintrin.h
1905 %{libsubdir}/include/tbmintrin.h
1906 %{libsubdir}/include/avx2intrin.h
1907 %{libsubdir}/include/bmi2intrin.h
1908 %{libsubdir}/include/fmaintrin.h
1909 %{libsubdir}/include/lzcntintrin.h
1910 %{libsubdir}/include/f16cintrin.h
1911 %{libsubdir}/include/adxintrin.h
1912 %{libsubdir}/include/fxsrintrin.h
1913 %{libsubdir}/include/prfchwintrin.h
1914 %{libsubdir}/include/rdseedintrin.h
1915 %{libsubdir}/include/rtmintrin.h
1916 %{libsubdir}/include/xsaveintrin.h
1917 %{libsubdir}/include/xsaveoptintrin.h
1918 %{libsubdir}/include/xtestintrin.h
1919 %{libsubdir}/include/avx512cdintrin.h
1920 %{libsubdir}/include/avx512erintrin.h
1921 %{libsubdir}/include/avx512fintrin.h
1922 %{libsubdir}/include/avx512pfintrin.h
1923 %{libsubdir}/include/shaintrin.h
1924 %endif
1925 %ifarch m68k
1926 %{libsubdir}/include/math-68881.h
1927 %endif
1928 %ifarch %cilkrts_arch
1929 %{libsubdir}/include/cilk
1930 %endif
1931 %versmainlib *crt*.o
1932 %versmainlib libgcc*.a
1933 %versmainlib libgcov.a
1934 %versmainlib libgcc_s*.so
1935 %versmainlib libgomp.so
1936 %versmainlib libgomp.a
1937 %versmainlib libgomp.spec
1938 %ifarch %itm_arch
1939 %versmainlib libitm.so
1940 %versmainlib libitm.a
1941 %versmainlib libitm.spec
1942 %endif
1943 %ifarch %atomic_arch
1944 %versmainlib libatomic.so
1945 %versmainlib libatomic.a
1946 %endif
1947 %ifarch %asan_arch
1948 %versmainlib libasan.so
1949 %versmainlib libasan.a
1950 %versmainlib libasan_preinit.o
1951 %endif
1952 %ifarch %tsan_arch
1953 %versmainlib libtsan.so
1954 %versmainlib libtsan.a
1955 %endif
1956 %ifarch %cilkrts_arch
1957 %versmainlib libcilkrts.so
1958 %versmainlib libcilkrts.a
1959 %versmainlib libcilkrts.spec
1960 %endif
1961 %ifarch %lsan_arch
1962 %versmainlib liblsan.so
1963 %versmainlib liblsan.a
1964 %endif
1965 %ifarch %ubsan_arch
1966 %versmainlib libubsan.so
1967 %versmainlib libubsan.a
1968 %endif
1969 %ifarch %asan_arch %ubsan_arch %tsan_arch %lsan_arch
1970 %versmainlib libsanitizer.spec
1971 %endif
1972 %ifarch %vtv_arch
1973 %versmainlib libvtv.so
1974 %versmainlib libvtv.a
1975 %endif
1976 %doc %{_mandir}/man1/gcc%{binsuffix}.1.gz
1977 %doc %{_mandir}/man1/gcov%{binsuffix}.1.gz
1978
1979 %if %{separate_biarch}
1980 %files -n gcc@base_ver@%{separate_biarch_suffix}
1981 %defattr(-,root,root)
1982 %versbiarchlib *crt*.o
1983 %versbiarchlib libgcc*.a
1984 %versbiarchlib libgcov.a
1985 %versbiarchlib libgcc_s*.so
1986 %versbiarchlib libgomp.so
1987 %versbiarchlib libgomp.a
1988 %versbiarchlib libgomp.spec
1989 %ifarch %itm_arch
1990 %versbiarchlib libitm.so
1991 %versbiarchlib libitm.a
1992 %versbiarchlib libitm.spec
1993 %endif
1994 %ifarch %atomic_arch
1995 %versbiarchlib libatomic.a
1996 %versbiarchlib libatomic.so
1997 %endif
1998 %ifarch %asan_arch
1999 %versbiarchlib libasan.a
2000 %versbiarchlib libasan.so
2001 %versbiarchlib libasan_preinit.o
2002 %endif
2003 %ifarch %ubsan_arch
2004 %versbiarchlib libubsan.a
2005 %versbiarchlib libubsan.so
2006 %endif
2007 %ifarch %cilkrts_arch
2008 %versbiarchlib libcilkrts.a
2009 %versbiarchlib libcilkrts.so
2010 %versbiarchlib libcilkrts.spec
2011 %endif
2012 %if 0
2013 %ifarch %tsan_arch
2014 %versbiarchlib libtsan.a
2015 %versbiarchlib libtsan.so
2016 %endif
2017 %ifarch %lsan_arch
2018 %versbiarchlib liblsan.a
2019 %versbiarchlib liblsan.so
2020 %endif
2021 %endif
2022 %ifarch %asan_arch %ubsan_arch %tsan_arch %lsan_arch
2023 %versbiarchlib libsanitizer.spec
2024 %endif
2025 %ifarch %vtv_arch
2026 %versbiarchlib libvtv.a
2027 %versbiarchlib libvtv.so
2028 %endif
2029 %endif
2030
2031 %files locale -f gcc@base_ver@-locale.lang
2032
2033 %files -n libstdc++%{libstdcxx_sover}%{libstdcxx_suffix}-locale -f libstdc++.lang
2034
2035 %if %{build_cp}
2036 %files c++
2037 %defattr(-,root,root)
2038 %dir %{_libdir}/gcc
2039 %dir %{_libdir}/gcc/%{GCCDIST}
2040 %dir %{libsubdir}
2041 %{_prefix}/bin/g++%{binsuffix}
2042 %doc %{_mandir}/man1/g++%{binsuffix}.1.gz
2043 %{libsubdir}/cc1plus
2044
2045 %files -n libstdc++%{libstdcxx_sover}%{libstdcxx_suffix}
2046 %defattr(-,root,root)
2047 %mainlib libstdc++.so.%{libstdcxx_sover}*
2048
2049 %if %{separate_biarch}
2050 %files -n libstdc++%{libstdcxx_sover}%{libstdcxx_suffix}%{separate_biarch_suffix}
2051 %defattr(-,root,root)
2052 %biarchlib libstdc++.so.%{libstdcxx_sover}*
2053 %endif
2054
2055 %files -n libstdc++@base_ver@-devel -f c++-headers
2056 %defattr(-,root,root)
2057 %versmainlib libstdc++.a
2058 %versmainlib libstdc++.so
2059 %versmainlib libsupc++.a
2060 %dir %{_datadir}/gdb
2061 %dir %{_datadir}/gdb/auto-load
2062 %dir %{_datadir}/gdb/auto-load%{_prefix}
2063 %dir %{_datadir}/gdb/auto-load/%{mainlibdir}
2064 %{_datadir}/gdb/auto-load/%{mainlibdir}/libstdc++.so.*-gdb.py
2065 %{_datadir}/gcc%{binsuffix}
2066
2067 %if %{separate_biarch}
2068 %files -n libstdc++@base_ver@-devel%{separate_biarch_suffix}
2069 %defattr(-,root,root)
2070 %versbiarchlib libstdc++.a
2071 %versbiarchlib libstdc++.so
2072 %versbiarchlib libsupc++.a
2073 %dir %{_datadir}/gdb/auto-load/%{mainlibdirbi}
2074 %{_datadir}/gdb/auto-load/%{mainlibdirbi}/libstdc++.so.*-gdb.py
2075 %endif
2076 %endif
2077
2078 %files -n libgcc_s%{libgcc_s}%{libgcc_s_suffix}
2079 %defattr(-,root,root)
2080 /%{_lib}/libgcc_s.so.%{libgcc_s}
2081 %if %{biarch}
2082 %if %{build_primary_64bit}
2083 %if !%{separate_bi32}
2084 /lib/libgcc_s.so.%{libgcc_s}
2085 %endif
2086 %else
2087 %if !%{separate_bi64}
2088 /lib64/libgcc_s.so.%{libgcc_s}
2089 %endif
2090 %endif
2091 %endif
2092
2093 %if %{separate_bi64}
2094 %files -n libgcc_s%{libgcc_s}%{libgcc_s_suffix}-64bit
2095 %defattr(-,root,root)
2096 /lib64/libgcc_s.so.%{libgcc_s}
2097 %endif
2098
2099 %if %{separate_bi32}
2100 %files -n libgcc_s%{libgcc_s}%{libgcc_s_suffix}-32bit
2101 %defattr(-,root,root)
2102 /lib/libgcc_s.so.%{libgcc_s}
2103 %endif
2104
2105
2106 %files -n libgomp%{libgomp_sover}%{libgomp_suffix}
2107 %defattr(-,root,root)
2108 %mainlib libgomp.so.%{libgomp_sover}*
2109
2110 %if %{separate_biarch}
2111 %files -n libgomp%{libgomp_sover}%{libgomp_suffix}%{separate_biarch_suffix}
2112 %defattr(-,root,root)
2113 %biarchlib libgomp.so.%{libgomp_sover}*
2114 %endif
2115
2116
2117 %ifarch %asan_arch
2118 %files -n libasan%{libasan_sover}%{libasan_suffix}
2119 %defattr(-,root,root)
2120 %mainlib libasan.so.%{libasan_sover}*
2121
2122 %if %{separate_biarch}
2123 %files -n libasan%{libasan_sover}%{libasan_suffix}%{separate_biarch_suffix}
2124 %defattr(-,root,root)
2125 %biarchlib libasan.so.%{libasan_sover}*
2126 %endif
2127 %endif
2128
2129
2130 %ifarch %lsan_arch
2131 %files -n liblsan%{liblsan_sover}%{liblsan_suffix}
2132 %defattr(-,root,root)
2133 %mainlib liblsan.so.%{liblsan_sover}*
2134
2135 %if 0
2136 %if %{separate_biarch}
2137 %files -n liblsan%{liblsan_sover}%{liblsan_suffix}%{separate_biarch_suffix}
2138 %defattr(-,root,root)
2139 %biarchlib liblsan.so.%{liblsan_sover}*
2140 %endif
2141 %endif
2142 %endif
2143
2144
2145 %ifarch %tsan_arch
2146 %files -n libtsan%{libtsan_sover}%{libtsan_suffix}
2147 %defattr(-,root,root)
2148 %mainlib libtsan.so.%{libtsan_sover}*
2149
2150 %if 0
2151 %if %{separate_biarch}
2152 %files -n libtsan%{libtsan_sover}%{libtsan_suffix}%{separate_biarch_suffix}
2153 %defattr(-,root,root)
2154 %biarchlib libtsan.so.%{libtsan_sover}*
2155 %endif
2156 %endif
2157 %endif
2158
2159
2160 %ifarch %atomic_arch
2161 %files -n libatomic%{libatomic_sover}%{libatomic_suffix}
2162 %defattr(-,root,root)
2163 %mainlib libatomic.so.%{libatomic_sover}*
2164
2165 %if %{separate_biarch}
2166 %files -n libatomic%{libatomic_sover}%{libatomic_suffix}%{separate_biarch_suffix}
2167 %defattr(-,root,root)
2168 %biarchlib libatomic.so.%{libatomic_sover}*
2169 %endif
2170 %endif
2171
2172
2173 %ifarch %itm_arch
2174 %files -n libitm%{libitm_sover}%{libitm_suffix}
2175 %defattr(-,root,root)
2176 %mainlib libitm.so.%{libitm_sover}*
2177
2178 %if %{separate_biarch}
2179 %files -n libitm%{libitm_sover}%{libitm_suffix}%{separate_biarch_suffix}
2180 %defattr(-,root,root)
2181 %biarchlib libitm.so.%{libitm_sover}*
2182 %endif
2183 %endif
2184
2185
2186 %ifarch %cilkrts_arch
2187 %files -n libcilkrts%{libcilkrts_sover}%{libcilkrts_suffix}
2188 %defattr(-,root,root)
2189 %mainlib libcilkrts.so.%{libcilkrts_sover}*
2190
2191 %if %{separate_biarch}
2192 %files -n libcilkrts%{libcilkrts_sover}%{libcilkrts_suffix}%{separate_biarch_suffix}
2193 %defattr(-,root,root)
2194 %biarchlib libcilkrts.so.%{libcilkrts_sover}*
2195 %endif
2196 %endif
2197
2198
2199 %ifarch %ubsan_arch
2200 %files -n libubsan%{libubsan_sover}%{libubsan_suffix}
2201 %defattr(-,root,root)
2202 %mainlib libubsan.so.%{libubsan_sover}*
2203
2204 %if %{separate_biarch}
2205 %files -n libubsan%{libubsan_sover}%{libubsan_suffix}%{separate_biarch_suffix}
2206 %defattr(-,root,root)
2207 %biarchlib libubsan.so.%{libubsan_sover}*
2208 %endif
2209 %endif
2210
2211
2212 %ifarch %vtv_arch
2213 %files -n libvtv%{libvtv_sover}%{libvtv_suffix}
2214 %defattr(-,root,root)
2215 %mainlib libvtv.so.%{libvtv_sover}*
2216
2217 %if %{separate_biarch}
2218 %files -n libvtv%{libvtv_sover}%{libvtv_suffix}%{separate_biarch_suffix}
2219 %defattr(-,root,root)
2220 %biarchlib libvtv.so.%{libvtv_sover}*
2221 %endif
2222 %endif
2223
2224
2225 %if %{build_fortran}
2226 %files fortran
2227 %defattr(-,root,root)
2228 %dir %{libsubdir}/finclude
2229 %{_prefix}/bin/gfortran%{binsuffix}
2230 %{libsubdir}/f951
2231 %{libsubdir}/finclude/*
2232 %versmainlib libgfortran.a
2233 %versmainlib libgfortran.so
2234 %versmainlib libgfortran.spec
2235 %versmainlib libgfortranbegin.a
2236 %versmainlib libcaf_single.a
2237 %ifarch %quadmath_arch
2238 %{libsubdir}/include/quadmath.h
2239 %{libsubdir}/include/quadmath_weak.h
2240 %versmainlib libquadmath.a
2241 %versmainlib libquadmath.so
2242 %endif
2243 %doc %{_mandir}/man1/gfortran%{binsuffix}.1.gz
2244
2245 %if %{separate_biarch}
2246 %files fortran%{separate_biarch_suffix}
2247 %defattr(-,root,root)
2248 %versbiarchlib libgfortran.a
2249 %versbiarchlib libgfortran.so
2250 %versbiarchlib libgfortran.spec
2251 %versbiarchlib libgfortranbegin.a
2252 %versbiarchlib libcaf_single.a
2253 %ifarch %quadmath_arch
2254 %versbiarchlib libquadmath.a
2255 %versbiarchlib libquadmath.so
2256 %endif
2257 %endif
2258
2259 %files -n libgfortran%{libgfortran_sover}%{libgfortran_suffix}
2260 %defattr(-,root,root)
2261 %mainlib libgfortran.so.%{libgfortran_sover}*
2262
2263 %if %{separate_biarch}
2264 %files -n libgfortran%{libgfortran_sover}%{libgfortran_suffix}%{separate_biarch_suffix}
2265 %defattr(-,root,root)
2266 %biarchlib libgfortran.so.%{libgfortran_sover}*
2267 %endif
2268
2269 %ifarch %quadmath_arch
2270 %files -n libquadmath%{libquadmath_sover}%{libquadmath_suffix}
2271 %defattr(-,root,root)
2272 %mainlib libquadmath.so.%{libquadmath_sover}*
2273
2274 %if %{separate_biarch}
2275 %files -n libquadmath%{libquadmath_sover}%{libquadmath_suffix}%{separate_biarch_suffix}
2276 %defattr(-,root,root)
2277 %biarchlib libquadmath.so.%{libquadmath_sover}*
2278 %endif
2279 %endif
2280 %endif
2281
2282 %files info
2283 %defattr(-,root,root)
2284 %doc %{_infodir}/cpp%{binsuffix}.info*.gz
2285 %doc %{_infodir}/cppinternals%{binsuffix}.info*.gz
2286 %doc %{_infodir}/gcc%{binsuffix}.info*.gz
2287 %doc %{_infodir}/gccint%{binsuffix}.info*.gz
2288 %doc %{_infodir}/gccinstall%{binsuffix}.info*.gz
2289 %doc %{_infodir}/libgomp%{binsuffix}.info*.gz
2290 %ifarch %itm_arch
2291 %doc %{_infodir}/libitm%{binsuffix}.info*.gz
2292 %endif
2293 %if %{build_fortran}
2294 %doc %{_infodir}/gfortran%{binsuffix}.info*.gz
2295 %ifarch %quadmath_arch
2296 %doc %{_infodir}/libquadmath%{binsuffix}.info*.gz
2297 %endif
2298 %endif
2299 %if %{build_java}
2300 %doc %{_infodir}/gcj%{binsuffix}.info*.gz
2301 %endif
2302 %if %{build_ada}
2303 %doc %{_infodir}/gnat-style%{binsuffix}.info*gz
2304 %doc %{_infodir}/gnat_rm%{binsuffix}.info*gz
2305 %doc %{_infodir}/gnat_ugn%{binsuffix}.info*gz
2306 %endif
2307
2308 %files -n cpp@base_ver@
2309 %defattr(-,root,root)
2310 %dir %{_libdir}/gcc
2311 %dir %{_libdir}/gcc/%{GCCDIST}
2312 %dir %{libsubdir}
2313 %{_prefix}/bin/cpp%{binsuffix}
2314 %{libsubdir}/cc1
2315 #%{libsubdir}/specs
2316 %doc %{_mandir}/man1/cpp%{binsuffix}.1.gz
2317
2318 %if %{build_objc}
2319 %files objc
2320 %defattr(-,root,root)
2321 %{libsubdir}/cc1obj
2322 %{libsubdir}/include/objc
2323 %versmainlib libobjc.a
2324 %versmainlib libobjc.so
2325
2326 %if %{separate_biarch}
2327 %files objc%{separate_biarch_suffix}
2328 %defattr(-,root,root)
2329 %versbiarchlib libobjc.a
2330 %versbiarchlib libobjc.so
2331 %endif
2332
2333 %files -n libobjc%{libobjc_sover}%{libobjc_suffix}
2334 %defattr(-,root,root)
2335 %mainlib libobjc.so.%{libobjc_sover}*
2336
2337 %if %{separate_biarch}
2338 %files -n libobjc%{libobjc_sover}%{libobjc_suffix}%{separate_biarch_suffix}
2339 %defattr(-,root,root)
2340 %biarchlib libobjc.so.%{libobjc_sover}*
2341 %endif
2342 %endif
2343
2344
2345 %if %{build_objcp}
2346 %files obj-c++
2347 %defattr(-,root,root)
2348 %{libsubdir}/cc1objplus
2349 %endif
2350
2351
2352 %if %{build_ada}
2353 %files ada
2354 %defattr(-,root,root)
2355 %dir %{_libdir}/gcc
2356 %dir %{_libdir}/gcc/%{GCCDIST}
2357 %dir %{libsubdir}
2358 %{_prefix}/bin/gnat*
2359 %dir %{versmainlibdir}/adalib
2360 %{versmainlibdir}/adainclude
2361 %{versmainlibdir}/adalib/*.ali
2362 %{versmainlibdir}/adalib/*.a
2363 %{versmainlibdir}/adalib/libgnarl.so
2364 %{versmainlibdir}/adalib/libgnat.so
2365 %{versmainlibdir}/gnat1
2366
2367 %if %{separate_biarch}
2368 %files ada%{separate_biarch_suffix}
2369 %defattr(-,root,root)
2370 %dir %{versmainlibdirbi}/adalib
2371 %{versmainlibdirbi}/adainclude
2372 %{versmainlibdirbi}/adalib/*.ali
2373 %{versmainlibdirbi}/adalib/*.a
2374 %{versmainlibdirbi}/adalib/libgnarl.so
2375 %{versmainlibdirbi}/adalib/libgnat.so
2376 %endif
2377
2378 %files -n libada@base_ver@
2379 %defattr(-,root,root)
2380 %mainlib libgnarl-*.so
2381 %mainlib libgnat-*.so
2382
2383 %if %{separate_biarch}
2384 %files -n libada@base_ver@%{separate_biarch_suffix}
2385 %defattr(-,root,root)
2386 %biarchlib libgnarl-*.so
2387 %biarchlib libgnat-*.so
2388 %endif
2389 %endif
2390 # LIBJAVA-DELETE-END
2391
2392
2393 %if %{build_java}
2394 %if 0%{?building_libjava:1}
2395 %files -n gcc@base_ver@-java
2396 %defattr(-,root,root)
2397 %{_prefix}/bin/gcj%{binsuffix}
2398 %{_prefix}/bin/gcjh%{binsuffix}
2399 %{_prefix}/bin/gcj-dbtool%{binsuffix}
2400 %{_prefix}/bin/jcf-dump%{binsuffix}
2401 %{_prefix}/bin/jv-convert%{binsuffix}
2402 %{_prefix}/bin/gc-analyze%{binsuffix}
2403 %{_prefix}/bin/aot-compile%{binsuffix}
2404 %{_prefix}/bin/rebuild-gcj-db%{binsuffix}
2405 %{libsubdir}/jc1
2406 %{libsubdir}/jvgenmain
2407 %{libsubdir}/ecj.jar
2408 %{libsubdir}/ecj1
2409 %doc %{_mandir}/man1/gcj%{binsuffix}.1.gz
2410 %doc %{_mandir}/man1/gcjh%{binsuffix}.1.gz
2411 %doc %{_mandir}/man1/gcj-dbtool%{binsuffix}.1.gz
2412 %doc %{_mandir}/man1/jcf-dump%{binsuffix}.1.gz
2413 %doc %{_mandir}/man1/jv-convert%{binsuffix}.1.gz
2414 %doc %{_mandir}/man1/gc-analyze%{binsuffix}.1.gz
2415 %doc %{_mandir}/man1/aot-compile%{binsuffix}.1.gz
2416 %doc %{_mandir}/man1/rebuild-gcj-db%{binsuffix}.1.gz
2417 %endif
2418 %endif
2419
2420 %if %{build_java}
2421 %if %{build_libjava}
2422 %files -n libgcj@base_ver@
2423 %defattr(-,root,root)
2424 %dir %{libsubdir}/gcj-%{gcc_dir_version}-%{libgcj_sover}
2425 %dir %{_libdir}/gcc
2426 %dir %{_libdir}/gcc/%{GCCDIST}
2427 %dir %{libsubdir}
2428 %{libsubdir}/gcj-%{gcc_dir_version}-%{libgcj_sover}/classmap.db
2429 # We usually do not multilib libjava
2430 %if %{biarch_libjava}
2431 %versbiarchlib libgcj.la
2432 %biarchlib libgcj.so.*
2433 %biarchlib libgij.so.*
2434 %biarchlib libgcj-tools.so.*
2435 %else
2436 %versmainlib libgcj.la
2437 %mainlib libgcj.so.*
2438 %mainlib libgij.so.*
2439 %mainlib libgcj-tools.so.*
2440 %endif
2441 %{libsubdir}/gcj-%{gcc_dir_version}-%{libgcj_sover}/libjvm.la
2442 %{libsubdir}/gcj-%{gcc_dir_version}-%{libgcj_sover}/libjvm.so
2443 %{libsubdir}/gcj-%{gcc_dir_version}-%{libgcj_sover}/libjavamath.la
2444 %{libsubdir}/gcj-%{gcc_dir_version}-%{libgcj_sover}/libjavamath.so
2445
2446 %files -n libgcj_bc%{libgcj_bc_sover}%{libgcj_bc_suffix}
2447 %defattr(-,root,root)
2448 %if %{biarch_libjava}
2449 %biarchlib libgcj_bc.so.%{libgcj_bc_sover}*
2450 %else
2451 %mainlib libgcj_bc.so.%{libgcj_bc_sover}*
2452 %endif
2453
2454 %files -n libgcj@base_ver@-jar
2455 %defattr(-,root,root)
2456 %{_prefix}/share/java/libgcj-%{gcc_dir_version}.jar
2457 %{_prefix}/share/java/libgcj-tools-%{gcc_dir_version}.jar
2458
2459 %files -n libgcj@base_ver@-devel
2460 %defattr(-,root,root)
2461 %dir %{_prefix}/include/c++
2462 %dir %{libsubdir}
2463 %dir %{libsubdir}/include
2464 %dir %{gxxinclude}
2465 %{_libdir}/pkgconfig/libgcj%{binsuffix}.pc
2466 %{libsubdir}/include/jawt.h
2467 %{libsubdir}/include/jawt_md.h
2468 %{libsubdir}/include/jni.h
2469 %{libsubdir}/include/jni_md.h
2470 %{libsubdir}/include/jvmpi.h
2471 %{gxxinclude}/gnu
2472 %{gxxinclude}/gcj
2473 %{gxxinclude}/java
2474 %{gxxinclude}/javax
2475 %{gxxinclude}/org
2476 %{gxxinclude}/sun
2477 %{libsubdir}/include/gcj
2478 %if %{biarch_libjava}
2479 %versbiarchlib libgcj.so
2480 %versbiarchlib libgcj.spec
2481 %versbiarchlib libgcj-tools.so
2482 %versbiarchlib libgij.so
2483 %versbiarchlib libgcj_bc.so
2484 %else
2485 %versmainlib libgcj.so
2486 %versmainlib libgcj.spec
2487 %versmainlib libgcj-tools.so
2488 %versmainlib libgij.so
2489 %versmainlib libgcj_bc.so
2490 %endif
2491
2492 %files -n gcc@base_ver@-gij
2493 %defattr(-,root,root)
2494 %{_prefix}/bin/gij%{binsuffix}
2495 %{_prefix}/bin/gappletviewer%{binsuffix}
2496 %{_prefix}/bin/gjar%{binsuffix}
2497 %{_prefix}/bin/gjarsigner%{binsuffix}
2498 %{_prefix}/bin/gjavah%{binsuffix}
2499 %{_prefix}/bin/gkeytool%{binsuffix}
2500 %{_prefix}/bin/gnative2ascii%{binsuffix}
2501 %{_prefix}/bin/gorbd%{binsuffix}
2502 %{_prefix}/bin/grmic%{binsuffix}
2503 %{_prefix}/bin/grmid%{binsuffix}
2504 %{_prefix}/bin/grmiregistry%{binsuffix}
2505 %{_prefix}/bin/gserialver%{binsuffix}
2506 %{_prefix}/bin/gtnameserv%{binsuffix}
2507 %doc %{_mandir}/man1/gij%{binsuffix}.1.gz
2508 %doc %{_mandir}/man1/gappletviewer%{binsuffix}.1.gz
2509 %doc %{_mandir}/man1/grmic%{binsuffix}.1.gz
2510 %doc %{_mandir}/man1/grmid%{binsuffix}.1.gz
2511 %doc %{_mandir}/man1/grmiregistry%{binsuffix}.1.gz
2512 %doc %{_mandir}/man1/gkeytool%{binsuffix}.1.gz
2513 %doc %{_mandir}/man1/gjar%{binsuffix}.1.gz
2514 %doc %{_mandir}/man1/gjarsigner%{binsuffix}.1.gz
2515 %doc %{_mandir}/man1/gjavah%{binsuffix}.1.gz
2516 %doc %{_mandir}/man1/gnative2ascii%{binsuffix}.1.gz
2517 %doc %{_mandir}/man1/gorbd%{binsuffix}.1.gz
2518 %doc %{_mandir}/man1/gserialver%{binsuffix}.1.gz
2519 %doc %{_mandir}/man1/gtnameserv%{binsuffix}.1.gz
2520 %endif
2521 %endif
2522
2523 %if 0%{?building_libjava:1}
2524 %files -n libstdc++@base_ver@-doc
2525 %defattr(-,root,root)
2526 %doc libstdc++-v3/doc/html
2527 %endif
2528 # LIBFFI-DELETE-END
2529
2530 %if %{build_java}
2531 %if 0%{?building_libffi:1}
2532 %files -n libffi%{libffi_sover}%{libffi_suffix}
2533 %defattr(-,root,root)
2534 %mainlib libffi.so.%{libffi_sover}*
2535
2536 %if %{separate_biarch}
2537 %files -n libffi%{libffi_sover}%{libffi_suffix}%{separate_biarch_suffix}
2538 %defattr(-,root,root)
2539 %biarchlib libffi.so.%{libffi_sover}*
2540 %endif
2541
2542 %post -n libffi@base_ver@-devel
2543 %install_info --info-dir=%{_infodir} %{_infodir}/libffi%{binsuffix}.info.gz
2544 %postun -n libffi@base_ver@-devel
2545 %install_info_delete --info-dir=%{_infodir} %{_infodir}/libffi%{binsuffix}.info.gz
2546
2547 %files -n libffi@base_ver@-devel
2548 %defattr(-,root,root)
2549 %{_prefix}/include/ffi.h
2550 %{_prefix}/include/ffitarget.h
2551 %mainlib libffi.so
2552 %mainlib libffi.a
2553 %{_libdir}/pkgconfig/libffi.pc
2554 %doc %{_infodir}/libffi%{binsuffix}.info.gz
2555 %doc %{_mandir}/man3/ffi%{binsuffix}.3.gz
2556 %doc %{_mandir}/man3/ffi_call%{binsuffix}.3.gz
2557 %doc %{_mandir}/man3/ffi_prep_cif%{binsuffix}.3.gz
2558 %doc %{_mandir}/man3/ffi_prep_cif_var%{binsuffix}.3.gz
2559
2560 %if %{separate_biarch}
2561 %files -n libffi@base_ver@-devel%{separate_biarch_suffix}
2562 %defattr(-,root,root)
2563 %biarchlib libffi.so
2564 %biarchlib libffi.a
2565 %endif
2566 %endif
2567 %endif
2568
2569 %if %{build_go}
2570 %files go
2571 %{_prefix}/bin/gccgo%{binsuffix}
2572 %{libsubdir}/go1
2573 %versmainlib libgo.a
2574 %versmainlib libgo.so
2575 %versmainlib libgobegin.a
2576 %dir %mainlibdir/go
2577 %dir %mainlibdir/go/%{gcc_dir_version}
2578 %mainlibdir/go/%{gcc_dir_version}/%{GCCDIST}
2579 %doc %{_mandir}/man1/gccgo%{binsuffix}.1.gz
2580
2581 %if %{separate_biarch}
2582 %files go%{separate_biarch_suffix}
2583 %versbiarchlib libgo.a
2584 %versbiarchlib libgo.so
2585 %versbiarchlib libgobegin.a
2586 %dir %mainlibdirbi/go
2587 %dir %mainlibdirbi/go/%{gcc_dir_version}
2588 %mainlibdirbi/go/%{gcc_dir_version}/%{GCCDIST}
2589 %endif
2590
2591 %files -n libgo%{libgo_sover}%{libgo_suffix}
2592 %defattr(-,root,root)
2593 %mainlib libgo.so.%{libgo_sover}*
2594
2595 %if %{separate_biarch}
2596 %files -n libgo%{libgo_sover}%{libgo_suffix}%{separate_biarch_suffix}
2597 %defattr(-,root,root)
2598 %biarchlib libgo.so.%{libgo_sover}*
2599 %endif
2600 %endif
2601 # GCC-TESTSUITE-DELETE-END
2602
2603 %if 0%{?run_tests:1}
2604 %files -n gcc@base_ver@-testresults
2605 %defattr(-,root,root)
2606 %doc testresults/test_summary.txt
2607 %doc testresults/*.sum
2608 %doc testresults/*.log
2609 %endif
2610
2611
2612 %changelog