2 # spec file for package gcc48
4 # Copyright (c) 2009 SUSE LINUX Products GmbH, Nuernberg, Germany.
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.
15 # Please submit bugfixes or comments via http://bugs.opensuse.org/
24 %define quadmath_arch %ix86 x86_64 ia64
25 %define tsan_arch x86_64
26 %define asan_arch x86_64 %ix86 ppc ppc64 %arm
27 %define itm_arch x86_64 %ix86 %arm ppc ppc64
28 %define atomic_arch x86_64 %ix86 %arm ppc ppc64 s390 s390x
30 # We don't want to build java
32 %define build_libjava 0
35 %define build_fortran 0%{?building_libjava:1}%{?building_libffi:1}
36 %define build_objc 0%{?building_libjava:1}%{?building_libffi:1}
37 %define build_objcp 0%{?building_libjava:1}%{?building_libffi:1}
38 %define build_with_mudflap 0
49 # For optional compilers only build C, C++ and Fortran
50 %if 0%{?build_optional_compiler_languages:1}
53 %define build_libjava 0
58 # Shared library SONAME versions
60 %define libgcj_sover %{nil}
61 %define libgcj_bc_sover %{nil}
62 %define libffi_sover %{nil}
63 %define libmudflap_sover %{nil}
64 %define libgomp_sover %{nil}
65 %define libstdcxx_sover %{nil}
66 %define libobjc_sover %{nil}
67 %define libgfortran_sover %{nil}
68 %define libquadmath_sover %{nil}
69 %define libasan_sover %{nil}
70 %define libtsan_sover %{nil}
71 %define libatomic_sover %{nil}
72 %define libitm_sover %{nil}
74 # Shared library package suffix
75 # This is used for the "non-standard" set of libraries, the standard
76 # being defined by %product_libs_gcc_ver, the GCC version that should
77 # provide un-suffixed shared library packages following the shared-library
78 # policy. Even suffixed variants should provide the shared-library policy
79 # mandated names and ensure they conflict with each other.
80 # Note that on SONAME changes of any library the %product_libs_gcc_ver
81 # define needs to be either split or the newest GCC version still providing
82 # the old SONAME needs to unconditionally produce an un-suffixed library
83 # if %product_libs_gcc_ver is newer than it. Similar the _oldest_ GCC
84 # version first providing a new SONAME needs to unconditionally produce
85 # an un-suffixed library if %product_libs_gcc_ver is lower that it.
86 %if %{!?product_libs_gcc_ver:@base_ver@}%{?product_libs_gcc_ver} != @base_ver@
89 %define libgcc_s_suffix %{?pne:-gcc@base_ver@}
90 # libgcj SONAME changes with every GCC version
91 %define libgcj_suffix %nil
92 %define libgcj_bc_suffix %{?pne:-gcc@base_ver@}
93 %define libffi_suffix %{?pne:-gcc@base_ver@}
94 %define libmudflap_suffix %{?pne:-gcc@base_ver@}
95 %define libgomp_suffix %{?pne:-gcc@base_ver@}
96 %define libstdcxx_suffix %{?pne:-gcc@base_ver@}
97 %define libobjc_suffix %{?pne:-gcc@base_ver@}
98 %define libgfortran_suffix %{?pne:-gcc@base_ver@}
99 %define libquadmath_suffix %{?pne:-gcc@base_ver@}
100 %define libasan_suffix %{?pne:-gcc@base_ver@}
101 %define libtsan_suffix %{?pne:-gcc@base_ver@}
102 %define libatomic_suffix %{?pne:-gcc@base_ver@}
103 %define libitm_suffix %{?pne:-gcc@base_ver@}
109 BuildRequires: gcc-c++
112 BuildRequires: glibc-devel-32bit
113 BuildRequires: mpc-devel
114 BuildRequires: mpfr-devel
116 BuildRequires: makeinfo
117 BuildRequires: zlib-devel
118 %ifarch %ix86 x86_64 ppc ppc64 s390 s390x ia64 %sparc hppa %arm
119 BuildRequires: cloog-isl-devel
120 BuildRequires: isl-devel
123 %define hostsuffix -4.7
124 BuildRequires: gcc47-ada
126 %if 0%{?building_libjava:1}%{?building_testsuite:1}
127 BuildRequires: fastjar
129 %if 0%{?building_libffi:1}
130 BuildRequires: pkg-config
133 BuildRequires: libunwind-devel
136 BuildRequires: dejagnu
137 BuildRequires: expect
141 %define separate_bi32 0
142 %define separate_bi64 0
144 # Beware, this does _not_ separate libgcj, as for that one multilibing
145 # is inactive for the time being
146 %define separate_bi64 1
148 %ifarch x86_64 s390x ppc64 sparc64
149 %define separate_bi32 1
152 # Define two macros to trigger -32bit or -64bit package variants
153 %define separate_biarch 0
155 %define separate_biarch 1
156 %define separate_biarch_suffix -32bit
159 %define separate_biarch 1
160 %define separate_biarch_suffix -64bit
163 %ifarch x86_64 ia64 s390x alpha ppc64 sparc64
164 # 64-bit is primary build target
165 %define build_primary_64bit 1
167 %define build_primary_64bit 0
170 %define biarch_libjava 0
173 %define biarch_targets x86_64 s390x powerpc64 powerpc sparc sparc64
175 URL: http://gcc.gnu.org/
178 %define gcc_dir_version 4.8
179 %define binsuffix -4.8
182 %if !0%{?building_libjava:1}%{?building_libffi:1}%{?building_testsuite:1}
183 Requires: binutils glibc-devel
184 Requires: cpp@base_ver@ = %{version}-%{release}
185 Requires: libgcc_s%{libgcc_s} >= %{version}-%{release}
186 Requires: libgomp%{libgomp_sover} >= %{version}-%{release}
187 %if %{build_with_mudflap}
188 Requires: libmudflap%{libmudflap_sover} >= %{version}-%{release}
189 Requires: libmudflapth%{libmudflap_sover} >= %{version}-%{release}
192 Requires: libasan%{libasan_sover} >= %{version}-%{release}
195 Requires: libtsan%{libtsan_sover} >= %{version}-%{release}
198 Requires: libatomic%{libatomic_sover} >= %{version}-%{release}
201 Requires: libitm%{libitm_sover} >= %{version}-%{release}
203 Suggests: gcc@base_ver@-info gcc@base_ver@-locale
207 BuildRoot: %{_tmppath}/%{name}-%{version}-build
208 Source: gcc-%{version}.tar.bz2
210 Source3: gcc48-rpmlintrc
212 Source6: baselibs.conf
213 Source1001: gcc.manifest
216 # GCC-TESTSUITE-DELETE-BEGIN
217 # LIBJAVA-DELETE-BEGIN
218 Group: Development/Toolchain
219 Summary: The GNU C Compiler and Support Files
223 Core package for the GNU Compiler Collection, including the C language
226 Language frontends other than C are split to different sub-packages,
227 namely gcc-ada, gcc-c++, gcc-fortran, gcc-java, gcc-objc and
229 # LIBFFI-DELETE-BEGIN
234 %package -n gcc@base_ver@-32bit
235 Summary: The GNU C Compiler 32bit support
236 Requires: gcc@base_ver@ = %{version}-%{release}
237 Requires: libgcc_s%{libgcc_s}-32bit >= %{version}-%{release}
238 Requires: libgomp%{libgomp_sover}-32bit >= %{version}-%{release}
239 %if %{build_with_mudflap}
240 Requires: libmudflap%{libmudflap_sover}-32bit >= %{version}-%{release}
241 Requires: libmudflapth%{libmudflap_sover}-32bit >= %{version}-%{release}
243 Requires: glibc-devel-32bit
245 %description -n gcc@base_ver@-32bit
246 This package contains 32bit support for the GNU Compiler Collection.
248 %package -n gcc@base_ver@-64bit
249 Summary: The GNU C Compiler 64bit support
250 Requires: gcc@base_ver@ = %{version}-%{release}
251 Requires: libgcc_s%{libgcc_s}-64bit >= %{version}-%{release}
252 Requires: libgomp%{libgomp_sover}-64bit >= %{version}-%{release}
253 %if %{build_with_mudflap}
254 Requires: libmudflap%{libmudflap_sover}-64bit >= %{version}-%{release}
255 Requires: libmudflapth%{libmudflap_sover}-64bit >= %{version}-%{release}
257 Requires: glibc-devel-64bit
259 %description -n gcc@base_ver@-64bit
260 This package contains 64bit support for the GNU Compiler Collection.
264 Summary: Locale Data for the GNU Compiler Collection
266 Requires: gcc@base_ver@ = %{version}-%{release}
269 Locale data for the GNU Compiler Collection (GCC) to give error message
270 in the current locale.
274 Summary: The GNU C++ Compiler
276 Requires: gcc@base_ver@ = %{version}-%{release}
277 Requires: libstdc++@base_ver@-devel = %{version}-%{release}
280 This package contains the GNU compiler for C++.
283 %package -n libstdc++@base_ver@-devel@variant@
284 Summary: Include Files and Libraries mandatory for Development
285 License: GPL-3.0-with-GCC-exception
286 Requires: libstdc++%{libstdcxx_sover}@variant@ >= %{version}-%{release}
287 Requires: glibc-devel@variant@
289 Requires: libunwind-devel
292 %description -n libstdc++@base_ver@-devel@variant@
293 This package contains all the headers and libraries of the standard C++
294 library. It is needed for compiling C++ code.
297 %package -n libstdc++@base_ver@-doc
298 Summary: Documentation for the GNU C++ standard library
302 %description -n libstdc++@base_ver@-doc
303 Extensive HTML documentation for the GNU C++ standard library.
307 %package -n libgcc_s%{libgcc_s}%{libgcc_s_suffix}@variant@
308 Summary: C compiler runtime library
309 License: GPL-3.0-with-GCC-exception
310 Group: System/Libraries
311 Provides: libgcc_s%{libgcc_s}@variant@ = %{version}-%{release}
313 %description -n libgcc_s%{libgcc_s}%{libgcc_s_suffix}@variant@
314 Libgcc is needed for dynamically linked C programs.
316 %post -n libgcc_s%{libgcc_s}%{libgcc_s_suffix}@variant@
319 %postun -n libgcc_s%{libgcc_s}%{libgcc_s_suffix}@variant@
324 %package -n libgomp%{libgomp_sover}%{libgomp_suffix}@variant@
325 Summary: The GNU compiler collection OpenMP runtime library
326 License: GPL-3.0-with-GCC-exception
327 Group: System/Libraries
328 Provides: libgomp%{libgomp_sover}@variant@ = %{version}-%{release}
330 %description -n libgomp%{libgomp_sover}%{libgomp_suffix}@variant@
331 This is the OpenMP runtime library needed by OpenMP enabled programs
332 that were built with the -fopenmp compiler option and by programs that
333 were auto-parallelized via the -ftree-parallelize-loops compiler
337 %post -n libgomp%{libgomp_sover}%{libgomp_suffix}@variant@
340 %postun -n libgomp%{libgomp_sover}%{libgomp_suffix}@variant@
345 %package -n libstdc++%{libstdcxx_sover}%{libstdcxx_suffix}@variant@
346 Summary: The standard C++ shared library
347 License: GPL-3.0-with-GCC-exception
348 Group: System/Libraries
349 Suggests: libstdc++%{libstdcxx_sover}-locale
350 Provides: libstdc++%{libstdcxx_sover}@variant@ = %{version}-%{release}
352 %description -n libstdc++%{libstdcxx_sover}%{libstdcxx_suffix}@variant@
353 The standard C++ library, needed for dynamically linked C++ programs.
356 %post -n libstdc++%{libstdcxx_sover}%{libstdcxx_suffix}@variant@
359 %postun -n libstdc++%{libstdcxx_sover}%{libstdcxx_suffix}@variant@
363 %package -n libstdc++%{libstdcxx_sover}%{libstdcxx_suffix}-locale
364 Summary: Locale Data for the standard C++ shared library
365 License: GPL-3.0-with-GCC-exception
366 Group: System/Libraries
367 Provides: libstdc++%{libstdcxx_sover}-locale = %{version}-%{release}
369 %description -n libstdc++%{libstdcxx_sover}%{libstdcxx_suffix}-locale
370 The standard C++ library locale data.
374 Summary: Documentation for the GNU compiler collection
379 GNU info-pages for the GNU compiler collection covering both user-level
380 and internals documentation.
384 %package objc@variant@
385 Summary: GNU Objective C Compiler
387 Requires: gcc@base_ver@ = %{version}-%{release}
388 Requires: libobjc%{libobjc_sover}@variant@ >= %{version}-%{release}
390 %description objc@variant@
391 This package contains the GNU Objective C compiler. Objective C is an
392 object oriented language, created by Next Inc. and used in their
393 Nextstep OS. The source code is available in the gcc package.
397 %package -n libobjc%{libobjc_sover}%{libobjc_suffix}@variant@
398 Summary: Library for the GNU Objective C Compiler
399 License: GPL-3.0-with-GCC-exception
400 Provides: libobjc%{libobjc_sover}@variant@ = %{version}-%{release}
402 %description -n libobjc%{libobjc_sover}%{libobjc_suffix}@variant@
403 The library for the GNU Objective C compiler.
405 %post -n libobjc%{libobjc_sover}%{libobjc_suffix}@variant@
408 %postun -n libobjc%{libobjc_sover}%{libobjc_suffix}@variant@
413 Summary: GNU Objective C++ Compiler
415 Requires: gcc@base_ver@-objc = %{version}-%{release}
416 Requires: gcc@base_ver@-c++ = %{version}-%{release}
419 This package contains the GNU Objective C++ compiler. Objective C++ is an
420 object oriented language, created by Next Inc. and used in their
421 Nextstep OS. The source code is available in the gcc package.
424 %package -n cpp@base_ver@
425 Summary: The GCC Preprocessor
428 %description -n cpp@base_ver@
429 This Package contains just the preprocessor that is used by the X11
434 %package ada@variant@
435 Summary: GNU Ada95 Compiler Based on GCC (GNAT)
437 Requires: gcc@base_ver@@variant@ = %{version}-%{release}
438 Requires: libada@base_ver@@variant@ = %{version}-%{release}
440 %description ada@variant@
441 This package contains an Ada95 compiler and associated development
442 tools based on the GNU GCC technology. Ada95 is the object oriented
443 successor of the Ada83 language. To build this package from source you
444 must have installed a binary version to bootstrap the compiler.
448 %package -n libada@base_ver@@variant@
449 Summary: GNU Ada Runtime Libraries
450 License: GPL-3.0-with-GCC-exception
451 %description -n libada@base_ver@@variant@
452 This package contains the shared libraries required to run programs
453 compiled with the GNU Ada compiler (GNAT) if they are compiled to use
454 shared libraries. It also contains the shared libraries for the
455 Implementation of the Ada Semantic Interface Specification (ASIS), the
456 implementation of Distributed Systems Programming (GLADE) and the Posix
457 1003.5 Binding (Florist).
459 %post -n libada@base_ver@@variant@
462 %postun -n libada@base_ver@@variant@
467 %package fortran@variant@
468 Summary: The GNU Fortran Compiler and Support Files
470 Requires: gcc@base_ver@ = %{version}-%{release}
471 Requires: libgfortran%{libgfortran_sover}@variant@ >= %{version}-%{release}
472 %ifarch %quadmath_arch
473 Requires: libquadmath%{libquadmath_sover}@variant@ >= %{version}-%{release}
476 %description fortran@variant@
477 This is the Fortran compiler of the GNU Compiler Collection (GCC).
481 %package -n libgfortran%{libgfortran_sover}%{libgfortran_suffix}@variant@
482 Summary: The GNU Fortran Compiler Runtime Library
483 License: GPL-3.0-with-GCC-exception
484 %ifarch %quadmath_arch
485 Requires: libquadmath%{libquadmath_sover}@variant@ >= %{version}-%{release}
487 Provides: libgfortran%{libgfortran_sover}@variant@ = %{version}-%{release}
489 %description -n libgfortran%{libgfortran_sover}%{libgfortran_suffix}@variant@
490 The runtime library needed to run programs compiled with the Fortran compiler
491 of the GNU Compiler Collection (GCC).
493 %post -n libgfortran%{libgfortran_sover}%{libgfortran_suffix}@variant@
496 %postun -n libgfortran%{libgfortran_sover}%{libgfortran_suffix}@variant@
501 %package -n libquadmath%{libquadmath_sover}%{libquadmath_suffix}@variant@
502 Summary: The GNU Fortran Compiler Quadmath Runtime Library
504 Provides: libquadmath%{libquadmath_sover}@variant@ = %{version}-%{release}
506 %description -n libquadmath%{libquadmath_sover}%{libquadmath_suffix}@variant@
507 The runtime library needed to run programs compiled with the Fortran compiler
508 of the GNU Compiler Collection (GCC) and quadruple precision floating point
511 %post -n libquadmath%{libquadmath_sover}%{libquadmath_suffix}@variant@
514 %postun -n libquadmath%{libquadmath_sover}%{libquadmath_suffix}@variant@
519 %package -n libmudflap@base_ver@@variant@
520 Summary: The Mudflap Extension Runtime Library
521 License: GPL-3.0-with-GCC-exception
523 %description -n libmudflap@base_ver@@variant@
524 This is the Mudflap Extension Runtime Library.
526 %post -n libmudflap@base_ver@@variant@
529 %postun -n libmudflap@base_ver@@variant@
534 %package -n libitm%{libitm_sover}%{libitm_suffix}@variant@
535 Summary: The GNU Compiler Transactional Memory Runtime Library
538 %description -n libitm%{libitm_sover}%{libitm_suffix}@variant@
539 The runtime library needed to run programs compiled with the
540 -fgnu-tm option of the GNU Compiler Collection (GCC).
542 %post -n libitm%{libitm_sover}%{libitm_suffix}@variant@
545 %postun -n libitm%{libitm_sover}%{libitm_suffix}@variant@
550 %package -n libasan%{libasan_sover}%{libasan_suffix}@variant@
551 Summary: The GNU Compiler Address Sanitizer Runtime Library
554 %description -n libasan%{libasan_sover}%{libasan_suffix}@variant@
555 The runtime library needed to run programs compiled with the
556 -fsanitize=address option of the GNU Compiler Collection (GCC).
558 %post -n libasan%{libasan_sover}%{libasan_suffix}@variant@
561 %postun -n libasan%{libasan_sover}%{libasan_suffix}@variant@
566 %package -n libtsan%{libtsan_sover}%{libtsan_suffix}@variant@
567 Summary: The GNU Compiler Thread Sanitizer Runtime Library
570 %description -n libtsan%{libtsan_sover}%{libtsan_suffix}@variant@
571 The runtime library needed to run programs compiled with the
572 -fsanitize=thread option of the GNU Compiler Collection (GCC).
574 %post -n libtsan%{libtsan_sover}%{libtsan_suffix}@variant@
577 %postun -n libtsan%{libtsan_sover}%{libtsan_suffix}@variant@
582 %package -n libatomic%{libatomic_sover}%{libatomic_suffix}@variant@
583 Summary: The GNU Compiler Atomic Operations Runtime Library
584 License: GPL-3.0-with-GCC-exception
586 %description -n libatomic%{libatomic_sover}%{libatomic_suffix}@variant@
587 The runtime library for atomic operations of the GNU Compiler Collection (GCC).
589 %post -n libatomic%{libatomic_sover}%{libatomic_suffix}@variant@
592 %postun -n libatomic%{libatomic_sover}%{libatomic_suffix}@variant@
597 %package -n libgcj@base_ver@
599 Summary: Java Runtime Library for gcc
600 License: GPL-2.0-with-classpath-exception
601 Group: System/Libraries
603 %description -n libgcj@base_ver@
604 This library is needed if you want to use the GNU Java compiler, gcj.
605 Source code for this package is in gcc.
607 %post -n libgcj@base_ver@
610 %postun -n libgcj@base_ver@
614 %package -n gcc@base_ver@-java
615 Summary: The GNU Java Compiler
617 Requires: gcc@base_ver@ = %{version}
618 Requires: libgcj@base_ver@-devel = %{version}-%{release}
620 %description -n gcc@base_ver@-java
621 The Java compiler from the GCC-tools-suite.
624 %package -n libgcj_bc%{libgcj_bc_sover}%{libgcj_bc_suffix}
625 Summary: Fake library for BC-ABI compatibility.
626 License: GPL-2.0-with-classpath-exception
627 # libgcj_bc is special in that it just contains a symlink to
628 # a proper libgcj version. So require that library and add
629 # provides for the shlib version as created at link time
630 Requires: libgcj%{libgcj_sover} >= %{version}-%{release}
631 %ifarch x86_64 ia64 ppc64 s390x sparc64 aarch64
632 Provides: libgcj_bc.so.%{libgcj_bc_sover}()(64bit)
634 Provides: libgcj_bc.so.%{libgcj_bc_sover}
637 %description -n libgcj_bc%{libgcj_bc_sover}%{libgcj_bc_suffix}
638 A fake library that is used at link time only. It ensures that
639 binaries built with the BC-ABI link against a constant SONAME.
640 This way, BC-ABI binaries continue to work if the SONAME underlying
644 %package -n libgcj@base_ver@-jar
645 Summary: Java runtime library (jar files).
646 License: GPL-2.0-with-classpath-exception
648 %description -n libgcj@base_ver@-jar
649 These are the jar files that go along with the gcj front end to gcc.
652 %package -n libgcj@base_ver@-devel
653 Summary: Include Files and Libraries mandatory for Development.
654 License: GPL-2.0-with-classpath-exception
655 Requires: libstdc++@base_ver@-devel = %{version}
656 Requires: libgcj%{libgcj_sover} >= %{version}-%{release}
657 Requires: libgcj_bc%{libgcj_bc_sover} >= %{version}-%{release}
658 Requires: libgcj@base_ver@-jar = %{version}-%{release}
660 Requires: libart_lgpl-devel
661 Requires: glibc-devel
664 Requires: libunwind-devel
667 %description -n libgcj@base_ver@-devel
668 This package contains all necessary include files and libraries needed
669 to develop applications that require these.
672 %package -n gcc@base_ver@-gij
673 Summary: Java Bytecode Interpreter for gcc
674 License: GPL-2.0-with-classpath-exception
675 Requires: libgcj%{libgcj_sover} >= %{version}-%{release}
677 %description -n gcc@base_ver@-gij
678 This package contains the java bytecode interpreter gij and related tools.
682 %package -n libffi%{libffi_sover}%{libffi_suffix}@variant@
683 Summary: Foreign Function Interface library
684 License: BSD-3-Clause
686 %description -n libffi%{libffi_sover}%{libffi_suffix}@variant@
687 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.
689 %post -n libffi%{libffi_sover}%{libffi_suffix}@variant@
692 %postun -n libffi%{libffi_sover}%{libffi_suffix}@variant@
697 %package -n libffi@base_ver@-devel@variant@
698 Summary: Foreign Function Interface library development files
699 License: BSD 3-Clause
700 Requires: libffi%{libffi_sover}@variant@ >= %{version}-%{release}
702 %description -n libffi@base_ver@-devel@variant@
703 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.
706 %package -n gcc@base_ver@-testresults
707 # GCC-TESTSUITE-DELETE-END
708 Summary: Testsuite results
709 License: SUSE-Public-Domain
711 %description -n gcc@base_ver@-testresults
712 Results from running the gcc and target library testsuites.
717 # Define the canonical target and host architecture
718 # %gcc_target_arch is supposed to be the full target triple
719 # %TARGET_ARCH is the canonicalized CPU part
720 # %CONFIGURE_TARGET is the target triple used for --target=
721 %if 0%{?gcc_target_arch:1}
722 %define CONFIGURE_TARGET %{gcc_target_arch}
723 %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/;")
724 %if 0%{?gcc_icecream:1} && %{TARGET_ARCH} == "powerpc"
725 %define CONFIGURE_TARGET powerpc64-tizen-linux
727 %if 0%{?gcc_icecream:1} && %{TARGET_ARCH} == "powerpc64"
728 %define CONFIGURE_TARGET powerpc64-tizen-linux
730 %if 0%{?gcc_icecream:1} && %{TARGET_ARCH} == "i586"
731 %define CONFIGURE_TARGET i586-tizen-linux
733 %if 0%{?gcc_icecream:1} && %{TARGET_ARCH} == "armv7l"
734 %define CONFIGURE_TARGET armv7l-tizen-linux-gnueabi
736 %if 0%{?gcc_icecream:1} && %{TARGET_ARCH} == "armv7hl"
737 %define CONFIGURE_TARGET armv7hl-tizen-linux-gnueabi
739 %if 0%{?gcc_icecream:1} && %{TARGET_ARCH} == "armv5tel"
740 %define CONFIGURE_TARGET armv5tel-tizen-linux-gnueabi
743 %define TARGET_ARCH %(echo %{_target_cpu} | sed -e "s/i.86/i586/;s/ppc/powerpc/;s/sparc64.*/sparc64/;s/sparcv.*/sparc/;")
745 %define HOST_ARCH %(echo %{_host_cpu} | sed -e "s/i.86/i586/;s/ppc/powerpc/;s/sparc64.*/sparc64/;s/sparcv.*/sparc/;")
747 %define biarch %(case " %{biarch_targets} " in (*" %{TARGET_ARCH} "*) echo 1;; (*) echo 0;; esac)
750 %define GCCDIST powerpc64-tizen-linux
753 %define GCCDIST sparc64-tizen-linux
756 %define GCCDIST %{HOST_ARCH}-tizen-linux-gnueabi
758 %define GCCDIST %{HOST_ARCH}-tizen-linux
763 %define libsubdir %{_libdir}/gcc/%{GCCDIST}/%{gcc_dir_version}
764 %define gxxinclude %{_prefix}/include/c++/%{gcc_dir_version}
768 # Versionspecific directories
769 %define versmainlibdir %{libsubdir}
770 %define versmainlibdirbi32 %{libsubdir}/32
771 %define versmainlibdirbi64 %{libsubdir}/64
773 %define versmainlibdirbi32 %{libsubdir}
774 %define versmainlibdirbi64 %{libsubdir}/64
776 %if %{build_primary_64bit}
777 %define versmainlibdirbi %{versmainlibdirbi32}
779 %define versmainlibdirbi %{versmainlibdirbi64}
782 %define mainlibdir %{_libdir}
783 %define mainlibdirbi32 %{_prefix}/lib
784 %define mainlibdirbi64 %{_prefix}/lib64
785 %if %{build_primary_64bit}
786 %define mainlibdirbi %{mainlibdirbi32}
788 %define mainlibdirbi %{mainlibdirbi64}
792 # Now define a few macros that make it easy to package libs and
793 # related files just to the right package, without caring for the
794 # exact path the files are in.
795 # %mainlib package X from all dirs that belong to the main package
796 # %biarchlib package X from all dirs that belong to the -32/64bit package
797 %define mainlib() %{mainlibdir}/%1\
799 %define biarchlib() %{nil}
801 %if !%{separate_biarch}
802 %define mainlib() %{mainlibdir}/%1\
806 %define biarchlib() %{mainlibdirbi}/%1\
811 %define versmainlib() %{versmainlibdir}/%1\
813 %define versbiarchlib() %{nil}
815 %if !%{separate_biarch}
816 %define versmainlib() %{versmainlibdir}/%1\
817 %{versmainlibdirbi}/%1\
820 %define versbiarchlib() %{versmainlibdirbi}/%1\
829 %setup -q -n gcc-%{version}
833 # We are configuring ppc as ppc64 but with switched multilibs. Adjust
834 # the libstdc++ abi testsuite baseline files accordingly
836 if [ -d libstdc++-v3/config/abi/post/powerpc64-linux-gnu ]; then
837 mkdir -p libstdc++-v3/config/abi/post/powerpc64-linux-gnu/64
838 mv libstdc++-v3/config/abi/post/powerpc64-linux-gnu/baseline_symbols.txt \
839 libstdc++-v3/config/abi/post/powerpc64-linux-gnu/64/
840 mv libstdc++-v3/config/abi/post/powerpc64-linux-gnu/32/baseline_symbols.txt \
841 libstdc++-v3/config/abi/post/powerpc64-linux-gnu/
846 # Avoid rebuilding of generated files
847 contrib/gcc_update --touch
848 # Avoid fucking up testsuite results with Java and indirect dispatch
849 export LD_AS_NEEDED=0
850 # Split version file into version used for directories (X.Y) and
851 # version to report with --version (X.Y.Z).
852 # See also gcc-dir-version.patch.
853 # Also decrement the patchlevel version by one
854 if test `cat gcc/DEV-PHASE` == "prerelease"; then
855 ( 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
857 mv gcc/BASE-VER gcc/FULL-VER
859 cat gcc/FULL-VER | cut -d '.' -f 1-2 > gcc/BASE-VER
861 rm -rf obj-%{GCCDIST}
864 RPM_OPT_FLAGS="$RPM_OPT_FLAGS -U_FORTIFY_SOURCE"
865 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'`
867 # -mcpu is superceded by -mtune but -mtune is not supported by
868 # our bootstrap compiler. -mcpu gives a warning that stops
869 # the build process, so remove it for now. Also remove all other
870 # -march and -mtune flags. They are superseeded by proper
871 # default compiler settings now.
872 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'`
875 RPM_OPT_FLAGS=`echo $RPM_OPT_FLAGS|sed -e 's/-fsigned-char//g'`
876 RPM_OPT_FLAGS=`echo $RPM_OPT_FLAGS|sed -e 's/-O1/-O2/g'`
878 %if 0%{?gcc_target_arch:1} && 0%{!?gcc_icecream:1}
879 # Kill all -march/tune/cpu because that screws building the target libs
880 RPM_OPT_FLAGS=`echo $RPM_OPT_FLAGS|sed -e 's/-m\(arch\|tune\|cpu\)=[^ ]*//g'`
882 # Replace 2 spaces by one finally
883 RPM_OPT_FLAGS=`echo $RPM_OPT_FLAGS|sed -e 's/ / /g'`
887 languages=$languages,c++
890 languages=$languages,objc
893 languages=$languages,fortran
896 languages=$languages,obj-c++
899 languages=$languages,java
902 languages=$languages,ada
906 if test -z "$J"; then
907 J=$(getconf _NPROCESSORS_CONF)
910 test 1 -gt "$J" && J=1
911 JL=$(($(getconf _NPROCESSORS_CONF)*2))
913 if test "$J" == "0"; then
916 if test "$JL" == "0"; then
919 PARALLEL="-j$J -l$JL"
921 # we don't want some miscompiles in the testsuite, or some fault in
922 # the compiler to kill the machine. Hence we limit the amount of memory
923 # by the physical RAM plus half of swap
924 #MEM=$(free -m | awk '/^Mem:/ {print $2}')
925 #SWAP=$(free -m | awk '/^Swap:/ {print $2}')
926 #ulimit -v $(((MEM + SWAP/2)*1024))
928 # In general we want to ship release checking enabled compilers
929 # and run BETA with checking enabled.
930 #ENABLE_CHECKING="--enable-checking=yes"
931 ENABLE_CHECKING="--enable-checking=release"
933 # Work around tail/head -1 changes
934 export _POSIX2_VERSION=199209
936 # configure tries to parse include/features.h to detect
937 # if glibc supports SSP. When cross compiling we would need
938 # to install a cross glibc, which we don't, or make the whole
939 # thing point to the native glibc, which is in /, hence the
940 # --with-build-sysroot=/
943 # Using the host gnatmake like
944 # CC="gcc%{hostsuffix}" GNATBIND="gnatbind%{hostsuffix}"
945 # GNATMAKE="gnatmake%{hostsuffix}"
946 # doesn't work due to PR33857, so an un-suffixed gnatmake has to be
948 mkdir -p host-tools/bin
949 cp -a /usr/bin/gnatmake%{hostsuffix} host-tools/bin/gnatmake
950 cp -a /usr/bin/gnatlink%{hostsuffix} host-tools/bin/gnatlink
951 cp -a /usr/bin/gnatbind%{hostsuffix} host-tools/bin/gnatbind
952 cp -a /usr/bin/gcc%{hostsuffix} host-tools/bin/gcc
953 ln -sf /usr/%{_lib} host-tools/%{_lib}
954 export PATH="`pwd`/host-tools/bin:$PATH"
956 #%if 0%{?gcc_target_arch:1} && 0%{!?gcc_icecream:1}
958 # --enable-threads=posix \
961 %if "%{TARGET_ARCH}" == "armv7l" || "%{TARGET_ARCH}" == "armv7hl"
962 # temporary workaround for a miscompilation of hash functions in java code
963 GCJ_EXTRA_FLAGS="-marm"
965 CFLAGS="$RPM_OPT_FLAGS" CXXFLAGS="$RPM_OPT_FLAGS" XCFLAGS="$RPM_OPT_FLAGS" \
966 TCFLAGS="$RPM_OPT_FLAGS" GCJFLAGS="$RPM_OPT_FLAGS $GCJ_EXTRA_FLAGS" \
968 --prefix=%{_prefix} \
969 --infodir=%{_infodir} \
970 --mandir=%{_mandir} \
971 --libdir=%{_libdir} \
972 --libexecdir=%{_libdir} \
973 --disable-bootstrap \
974 --enable-languages=$languages \
976 --with-gxx-include-dir=%{_prefix}/include/c++/%{gcc_dir_version} \
980 --with-bugurl="http://bugs.tizen.org/" \
981 --with-pkgversion="Tizen" \
982 %if !%{build_fortran}
983 --disable-libquadmath \
985 %if !%{build_libjava}
988 --with-java-home=%{_libdir}/jvm/java-1.5.0-gcj%{binsuffix}-1.5.0.0/jre \
989 --with-ecj-jar=%{libsubdir}/ecj.jar \
991 %if !%{biarch_libjava}
992 --disable-libjava-multilib \
995 %if !%{build_with_mudflap}
996 --disable-libmudflap \
998 --with-slibdir=/%{_lib} \
1000 --enable-__cxa_atexit \
1001 --enable-libstdcxx-allocator=new \
1002 --disable-libstdcxx-pch \
1003 --enable-version-specific-runtime-libs \
1004 --enable-linker-build-id \
1005 %if 0%{?gcc_target_arch:1}
1006 %if 0%{?gcc_icecream:1}
1008 --with-gxx-include-dir=%{_prefix}/%{gcc_target_arch}%{?canonical_target_abi:%canonical_target_abi}/include/c++/%{gcc_dir_version} \
1009 --enable-linux-futex \
1011 %if 0%{?canonical_target:1}
1012 --with-build-time-tools=/usr/%{canonical_target}-tizen-linux%{?canonical_target_abi:%canonical_target_abi}/bin \
1015 --with-sysroot=%sysroot \
1017 %if 0%{?build_static:1}
1020 %if "%{TARGET_ARCH}" == "spu"
1021 --with-gxx-include-dir=%sysroot/include/c++/%{gcc_dir_version} \
1025 --target=%{CONFIGURE_TARGET} \
1027 --program-suffix=%{binsuffix} \
1028 --enable-linux-futex \
1030 --with-system-libunwind \
1032 --without-system-libunwind \
1035 %if "%{TARGET_ARCH}" == "armv5tel"
1036 --with-arch=armv5te \
1039 --with-abi=aapcs-linux \
1040 --disable-sjlj-exceptions \
1042 %if "%{TARGET_ARCH}" == "armv7l"
1043 --with-arch=armv7-a \
1044 --with-tune=cortex-a8 \
1045 --with-float=softfp \
1048 --disable-sjlj-exceptions \
1050 %if "%{TARGET_ARCH}" == "armv7hl"
1051 --with-arch=armv7-a \
1052 --with-tune=cortex-a9 \
1054 --with-abi=aapcs-linux \
1055 --with-fpu=vfpv3-d16 \
1056 --disable-sjlj-exceptions \
1058 %if "%{TARGET_ARCH}" == "powerpc" || "%{TARGET_ARCH}" == "powerpc64"
1059 %if "%{TARGET_ARCH}" == "powerpc"
1060 --with-cpu=default32 \
1062 --with-cpu-64=power4 \
1063 --enable-secureplt \
1064 --with-long-double-128 \
1066 %if "%{TARGET_ARCH}" == "sparc64"
1067 --with-cpu=ultrasparc \
1068 --with-long-double-128 \
1070 %if "%{TARGET_ARCH}" == "sparc"
1072 --with-long-double-128 \
1074 %if "%{TARGET_ARCH}" == "i586"
1075 --with-arch-32=i586 \
1076 --with-tune=generic \
1078 %if "%{TARGET_ARCH}" == "x86_64"
1079 --with-arch-32=i586 \
1080 --with-tune=generic \
1082 %if "%{TARGET_ARCH}" == "s390"
1083 --with-tune=z196 --with-arch=z10 \
1084 --with-long-double-128 \
1085 --enable-decimal-float \
1087 %if "%{TARGET_ARCH}" == "s390x"
1088 --with-tune=z196 --with-arch=z10 \
1089 --with-long-double-128 \
1090 --enable-decimal-float \
1096 %if 0%{?building_libffi:1}
1097 make stage1-bubble $PARALLEL
1098 make all-target-libffi $PARALLEL
1101 # Only run profiled bootstrap on archs where it works
1102 #%ifarch %ix86 x86_64 ppc ppc64 ia64
1103 #make profiledbootstrap-lean STAGE1_CFLAGS="$STAGE1_FLAGS" BOOT_CFLAGS="$RPM_OPT_FLAGS" $PARALLEL
1105 #make bootstrap-lean STAGE1_CFLAGS="$STAGE1_FLAGS" BOOT_CFLAGS="$RPM_OPT_FLAGS" $PARALLEL
1106 make STAGE1_CFLAGS="$STAGE1_FLAGS" BOOT_CFLAGS="$RPM_OPT_FLAGS" $PARALLEL
1110 %if 0%{?run_tests:1}
1111 echo "Run testsuite"
1112 (make -C %{GCCDIST}/libstdc++-v3 check-abi || true)
1113 mv %{GCCDIST}/libstdc++-v3/testsuite/libstdc++.log %{GCCDIST}/libstdc++-v3/testsuite/libstdc++-abi.log
1114 mv %{GCCDIST}/libstdc++-v3/testsuite/libstdc++.sum %{GCCDIST}/libstdc++-v3/testsuite/libstdc++-abi.sum
1115 # asan needs a whole shadow address space
1116 ulimit -v unlimited || true
1117 make -k check $PARALLEL || true
1118 mkdir ../testresults
1119 ../contrib/test_summary | tee ../testresults/test_summary.txt
1124 export NO_BRP_CHECK_BYTECODE_VERSION=true
1126 # GCC-TESTSUITE-DELETE-BEGIN
1127 # Work around tail/head -1 changes
1128 export _POSIX2_VERSION=199209
1129 export LIBRARY_PATH=$RPM_BUILD_ROOT%{libsubdir}:$RPM_BUILD_ROOT%{mainlibdirbi}
1130 %if 0%{?building_libffi:1}
1131 make -C %{GCCDIST}/libffi install DESTDIR=$RPM_BUILD_ROOT
1133 %if 0%{?building_libjava:1}
1134 make -C %{GCCDIST}/libjava install DESTDIR=$RPM_BUILD_ROOT
1135 make -C gcc java.install-man DESTDIR=$RPM_BUILD_ROOT
1136 make -C gcc java.install-common DESTDIR=$RPM_BUILD_ROOT
1137 make -C gcc install-common DESTDIR=$RPM_BUILD_ROOT COMPILERS='jc1$(exeext) jvgenmain$(exeext)'
1138 # install-common also installs collect2, gcov and the g++ and gfortran driver
1140 rm $RPM_BUILD_ROOT%{_prefix}/bin/g++%{binsuffix}
1142 %if %{build_fortran}
1143 rm $RPM_BUILD_ROOT%{_prefix}/bin/gfortran%{binsuffix}
1145 rm $RPM_BUILD_ROOT%{_prefix}/bin/gcov%{binsuffix}
1146 rm $RPM_BUILD_ROOT%{libsubdir}/collect2
1148 make install DESTDIR=$RPM_BUILD_ROOT
1150 make -C gcc java.uninstall DESTDIR=$RPM_BUILD_ROOT
1151 make -C gcc java.install-info DESTDIR=$RPM_BUILD_ROOT
1152 rm $RPM_BUILD_ROOT%{_prefix}/bin/jcf-dump%{binsuffix}
1153 rm $RPM_BUILD_ROOT%{_mandir}/man1/jcf-dump%{binsuffix}.1
1154 rm $RPM_BUILD_ROOT%{libsubdir}/jc1
1155 rm $RPM_BUILD_ROOT%{libsubdir}/jvgenmain
1160 # Remove libffi installed files if we did not want to build it
1161 %if !0%{?building_libffi:1}
1162 rm -f $RPM_BUILD_ROOT%{mainlibdir}/libffi.*
1164 rm -f $RPM_BUILD_ROOT%{mainlibdirbi}/libffi.*
1166 rm -f $RPM_BUILD_ROOT%{libsubdir}/include/ffi.h
1167 rm -f $RPM_BUILD_ROOT%{libsubdir}/include/ffitarget.h
1168 rm -f $RPM_BUILD_ROOT%{_mandir}/man3/ffi%{binsuffix}.3*
1169 rm -f $RPM_BUILD_ROOT%{_mandir}/man3/ffi_call%{binsuffix}.3*
1170 rm -f $RPM_BUILD_ROOT%{_mandir}/man3/ffi_prep_cif%{binsuffix}.3*
1171 rm -f $RPM_BUILD_ROOT%{_mandir}/man3/ffi_prep_cif_var%{binsuffix}.3*
1174 # Remove some useless .la files
1175 for lib in libobjc libgfortran libgfortranbegin libquadmath libcaf_single \
1176 libmudflap libmudflapth libgomp libstdc++ libsupc++ libgcj-tools libgij \
1177 libasan libatomic libitm libtsan; do
1178 rm -f $RPM_BUILD_ROOT%{versmainlibdir}/$lib.la
1180 rm -f $RPM_BUILD_ROOT%{versmainlibdirbi}/$lib.la
1184 mkdir -p $RPM_BUILD_ROOT%{_libdir}
1186 %if %{build_primary_64bit}
1187 mkdir -p $RPM_BUILD_ROOT%{_prefix}/lib
1189 mkdir -p $RPM_BUILD_ROOT%{_prefix}/lib64
1193 # LIBFFI-DELETE-BEGIN
1194 # LIBJAVA-DELETE-BEGIN
1196 # Merge multilib c++config.h to allow omitting the duplicate and
1197 # identical other arch specific headers
1199 cxxconfig="`find %{GCCDIST}/libstdc++-v3/include -name c++config.h`"
1200 for i in `find %{GCCDIST}/[36]*/libstdc++-v3/include -name c++config.h 2>/dev/null`; do
1201 if ! diff -up $cxxconfig $i; then
1216 if ! ( test -f "$file_32" && test -f "$file_64" ); then
1221 cat > $RPM_BUILD_ROOT%{_prefix}/include/c++/%{gcc_dir_version}/%{GCCDIST}/bits/c++config.h <<EOF
1222 #ifndef _CPP_CPPCONFIG_WRAPPER
1223 #define _CPP_CPPCONFIG_WRAPPER 1
1224 #include <bits/wordsize.h>
1225 #if __WORDSIZE == 32
1235 rm -rf $RPM_BUILD_ROOT%{_prefix}/include/c++/%{gcc_dir_version}/%{GCCDIST}/[36]*
1236 if ! test -z "$dir_ml"; then
1237 ln -s . $RPM_BUILD_ROOT%{_prefix}/include/c++/%{gcc_dir_version}/%{GCCDIST}/$dir_ml
1240 # LIBJAVA-DELETE-END
1242 # move shared libs from versionspecific dir to main libdir
1244 %if 0%{?building_libjava:1}
1245 libgcj libgij libgcj-tools \
1247 %if %{build_fortran}
1249 %ifarch %quadmath_arch
1260 %ifarch %atomic_arch
1272 %if %{build_with_mudflap}
1273 libmudflap libmudflapth \
1277 for lib in `find $RPM_BUILD_ROOT%{versmainlibdir} -maxdepth 1 -name $libname.so.*`; do
1278 mv $lib $RPM_BUILD_ROOT%{mainlibdir}/
1280 ln -sf %{mainlibdir}/`readlink $RPM_BUILD_ROOT%{versmainlibdir}/$libname.so | sed -e 's/\(.*\.so\.[^\.]*\).*/\1/'` \
1281 $RPM_BUILD_ROOT%{versmainlibdir}/$libname.so
1283 if test -d $RPM_BUILD_ROOT%{versmainlibdirbi}; then
1284 for lib in `find $RPM_BUILD_ROOT%{versmainlibdirbi} -maxdepth 1 -name "$libname.so.*"`; do
1285 mv $lib $RPM_BUILD_ROOT%{mainlibdirbi}/
1287 ln -sf %{mainlibdirbi}/`readlink $RPM_BUILD_ROOT%{versmainlibdirbi}/$libname.so | sed -e 's/\(.*\.so\.[^\.]*\).*/\1/'` \
1288 $RPM_BUILD_ROOT%{versmainlibdirbi}/$libname.so
1292 # FIXME, tsan is not multilib
1295 rm -f $RPM_BUILD_ROOT%{versmainlibdirbi}/libtsan.so
1299 %if !0%{?building_libjava:1}
1300 # And we want to move the shlib gdb pretty printers to a more sane
1301 # place so ldconfig does not complain
1302 mkdir -p $RPM_BUILD_ROOT%{_datadir}/gdb/auto-load%{mainlibdir}
1303 mv $RPM_BUILD_ROOT%{mainlibdir}/libstdc++.so.*-gdb.py $RPM_BUILD_ROOT%{_datadir}/gdb/auto-load%{mainlibdir}/
1304 sed -i -e '/^libdir/s/\/gcc\/%{GCCDIST}\/%{gcc_dir_version}//g' $RPM_BUILD_ROOT%{_datadir}/gdb/auto-load%{mainlibdir}/libstdc++.so.*-gdb.py
1306 if test -d $RPM_BUILD_ROOT%{versmainlibdirbi}; then
1307 mkdir -p $RPM_BUILD_ROOT%{_datadir}/gdb/auto-load%{mainlibdirbi}
1308 mv $RPM_BUILD_ROOT%{mainlibdirbi}/libstdc++.so.*-gdb.py $RPM_BUILD_ROOT%{_datadir}/gdb/auto-load%{mainlibdirbi}/
1309 sed -i -e '/^libdir/s/\/gcc\/%{GCCDIST}\/%{gcc_dir_version}//g' $RPM_BUILD_ROOT%{_datadir}/gdb/auto-load%{mainlibdirbi}/libstdc++.so.*-gdb.py
1314 %if 0%{?building_libjava:1}
1315 # libgcj_bc is special as the .so file is actually a different
1316 # library as the library refered to by the SONAME which should
1317 # be a simple link to our libgcj.
1318 for lib in `find $RPM_BUILD_ROOT%{versmainlibdir} -maxdepth 1 -name libgcj_bc.so.*`; do
1321 ln -s libgcj.so.%{libgcj_sover} $RPM_BUILD_ROOT%{mainlibdir}/libgcj_bc.so.%{libgcj_bc_sover}
1322 %if %{biarch_libjava}
1323 for lib in `find $RPM_BUILD_ROOT%{versmainlibdirbi} -maxdepth 1 -name libgcj_bc.so.*`; do
1326 ln -s libgcj.so.%{libgcj_sover} $RPM_BUILD_ROOT%{mainlibdirbi}/libgcj_bc.so.%{libgcj_bc_sover}
1330 # LIBJAVA-DELETE-BEGIN
1331 # Move libgcc_s around
1332 if test -L $RPM_BUILD_ROOT/%{_lib}/libgcc_s.so; then
1333 rm -f $RPM_BUILD_ROOT/%{_lib}/libgcc_s.so
1334 ln -sf /%{_lib}/libgcc_s.so.%{libgcc_s} $RPM_BUILD_ROOT%{versmainlibdir}/libgcc_s.so
1336 mv $RPM_BUILD_ROOT/%{_lib}/libgcc_s.so $RPM_BUILD_ROOT%{versmainlibdir}/
1338 chmod a+x $RPM_BUILD_ROOT/%{_lib}/libgcc_s.so.%{libgcc_s}
1340 %if %{build_primary_64bit}
1341 if test -L $RPM_BUILD_ROOT/lib/libgcc_s.so; then
1342 rm -f $RPM_BUILD_ROOT/lib/libgcc_s.so
1343 ln -sf /lib/libgcc_s.so.%{libgcc_s} $RPM_BUILD_ROOT%{versmainlibdirbi32}/libgcc_s.so
1345 mv $RPM_BUILD_ROOT/lib/libgcc_s.so $RPM_BUILD_ROOT%{versmainlibdirbi32}/
1347 ln -sf %{versmainlibdirbi32}/libgcc_s.so $RPM_BUILD_ROOT%{versmainlibdirbi32}/libgcc_s_32.so
1348 chmod a+x $RPM_BUILD_ROOT/lib/libgcc_s.so.%{libgcc_s}
1350 # 32-bit biarch systems
1351 if test -L $RPM_BUILD_ROOT/lib64/libgcc_s.so; then
1352 rm -f $RPM_BUILD_ROOT/lib64/libgcc_s.so
1353 ln -sf /lib64/libgcc_s.so.%{libgcc_s} $RPM_BUILD_ROOT%{versmainlibdirbi64}/libgcc_s.so
1355 mv $RPM_BUILD_ROOT/lib64/libgcc_s.so $RPM_BUILD_ROOT%{versmainlibdirbi64}/
1357 ln -sf %{versmainlibdirbi64}/libgcc_s.so $RPM_BUILD_ROOT%{versmainlibdirbi64}/libgcc_s_64.so
1358 chmod a+x $RPM_BUILD_ROOT/lib64/libgcc_s.so.%{libgcc_s}
1362 # LIBJAVA-DELETE-END
1366 mv $RPM_BUILD_ROOT%{libsubdir}/adalib/lib*-*.so $RPM_BUILD_ROOT%{_libdir}
1367 ln -sf %{_libdir}/libgnarl%{binsuffix}.so $RPM_BUILD_ROOT%{libsubdir}/adalib/libgnarl.so
1368 ln -sf %{_libdir}/libgnat%{binsuffix}.so $RPM_BUILD_ROOT%{libsubdir}/adalib/libgnat.so
1369 chmod a+x $RPM_BUILD_ROOT%{_libdir}/libgna*-*.so
1371 mv $RPM_BUILD_ROOT%{versmainlibdirbi}/adalib/lib*-*.so $RPM_BUILD_ROOT%{mainlibdirbi}/
1372 ln -sf %{mainlibdirbi}/libgnarl%{binsuffix}.so $RPM_BUILD_ROOT%{versmainlibdirbi}/adalib/libgnarl.so
1373 ln -sf %{mainlibdirbi}/libgnat%{binsuffix}.so $RPM_BUILD_ROOT%{versmainlibdirbi}/adalib/libgnarl.so
1374 chmod a+x $RPM_BUILD_ROOT%{mainlibdirbi}/libgna*-*.so
1378 rm -f $RPM_BUILD_ROOT%{_prefix}/bin/c++%{binsuffix}
1380 # Remove some crap from the .la files:
1381 for l in `find $RPM_BUILD_ROOT -name '*.la'`; do
1383 # -e '/^dependency_libs/s|%{libsubdir}/\([^.]*\)\.la |%{_libdir}/\1\.la |g'
1384 sed -e '/^dependency_libs/s| -L%{_builddir}/[^ ]*||g' \
1385 -e '/^dependency_libs/s| -L/usr/%{GCCDIST}/bin||g' \
1386 -e '/^dependency_libs/s|-lm \(-lm \)*|-lm |' \
1387 -e '/^dependency_libs/s|-L[^ ]* ||g' \
1389 %if %{build_primary_64bit}
1390 -e '/^libdir/s|%{_libdir}/32|%{_prefix}/lib|' \
1391 -e '/^libdir/s|lib64/\.\./||' \
1393 -e '/^libdir/s|%{_libdir}/64|%{_prefix}/lib64|' \
1400 # GCC-TESTSUITE-DELETE-END
1401 %if 0%{?run_tests:1}
1402 cp `find . -name "*.sum"` ../testresults/
1403 cp `find . -name "*.log" \! -name "config.log" | grep -v 'acats.\?/tests' ` ../testresults/
1404 chmod 644 ../testresults/*
1406 # GCC-TESTSUITE-DELETE-BEGIN
1407 # LIBFFI-DELETE-BEGIN
1409 # Find C++ and Java headers
1410 find $RPM_BUILD_ROOT%{_prefix}/include/c++ \
1411 -regex ".*/\(org\|gcj\|gnu\|java\|javax\)" -prune \
1412 -o \( -type d -printf "%%%%dir " , \
1413 -printf "%{_prefix}/include/c++/%%P\n" \) > ../c++-headers
1416 # Remove files that we do not need to clean up filelist
1417 rm -f $RPM_BUILD_ROOT%{_prefix}/bin/%{GCCDIST}-*
1418 rm -rf $RPM_BUILD_ROOT%{libsubdir}/install-tools
1419 #rm -rf $RPM_BUILD_ROOT%{_libdir}/pkgconfig/libgcj%{binsuffix}.pc
1420 rm -rf $RPM_BUILD_ROOT%{libsubdir}/include-fixed/root
1421 rm -f $RPM_BUILD_ROOT%{libsubdir}/include-fixed/curses.h
1422 rm -rf $RPM_BUILD_ROOT%{libsubdir}/include-fixed/asm-*
1423 rm -rf $RPM_BUILD_ROOT%{libsubdir}/include-fixed/linux
1424 rm -rf $RPM_BUILD_ROOT%{libsubdir}/include-fixed/sound
1425 rm -rf $RPM_BUILD_ROOT%{libsubdir}/include-fixed/features.h
1426 rm -f $RPM_BUILD_ROOT%{libsubdir}/include-fixed/ncurses.h
1427 rm -f $RPM_BUILD_ROOT%{libsubdir}/include-fixed/stdio.h
1428 rm -f $RPM_BUILD_ROOT%{libsubdir}/include-fixed/zutil.h
1429 rm -rf $RPM_BUILD_ROOT%{libsubdir}/include-fixed/X11
1430 rm -rf $RPM_BUILD_ROOT%{libsubdir}/include-fixed/bits
1431 rm -f $RPM_BUILD_ROOT%{libsubdir}/include-fixed/obstack.h
1432 rm -f $RPM_BUILD_ROOT%{libsubdir}/include-fixed/spe.h
1433 rm -f $RPM_BUILD_ROOT%{libsubdir}/include-fixed/tgmath.h
1434 rm -rf $RPM_BUILD_ROOT%{libsubdir}/include-fixed/bits
1435 rm -rf $RPM_BUILD_ROOT%{libsubdir}/include-fixed/sys
1437 rm -rf $RPM_BUILD_ROOT%{libsubdir}/plugin
1438 rm -f $RPM_BUILD_ROOT%{_infodir}/dir
1439 rm -f $RPM_BUILD_ROOT%{_prefix}/bin/gccbug%{binsuffix}
1441 %if !0%{?building_libjava:1}%{?building_libffi:1}
1442 # delete compile flag tracking from crt files
1443 crt_list=$RPM_BUILD_ROOT%{versmainlibdir}/crt*.o
1445 %if %{build_primary_64bit}
1446 crt32_list=$RPM_BUILD_ROOT%{versmainlibdirbi32}/crt*.o
1448 crt64_list=$RPM_BUILD_ROOT%{versmainlibdirbi64}/crt*.o
1451 for o in $crt_list $crt32_list $crt64_list; do
1452 objcopy -R ".comment.SUSE.OPTs" $o
1456 %if 0%{?building_libjava:1}
1457 # gcj -static doesn't work properly anyway, unless using --whole-archive
1458 # let's save the space instead.
1459 find $RPM_BUILD_ROOT -name libgcj.a \
1460 -o -name libgcj-tools.a \
1463 -o -name libgcj_bc.a \
1466 find $RPM_BUILD_ROOT -name libgcj.spec | xargs \
1467 sed -i -e 's/lib: /&%%{static:%%eJava programs cannot be linked statically}/'
1469 # security files have broken install locations, also they cause conflicts
1470 # between libgcj versions. Simply delete them here, libgcj will use its
1471 # defaults in this case (which is what these files contain anyway).
1472 rm $RPM_BUILD_ROOT%{_libdir}/logging.properties
1473 rm -r $RPM_BUILD_ROOT%{_libdir}/security
1476 %if 0%{?building_libffi:1}
1477 # Move libffi headers, remove empty libffi libtool file
1478 mkdir -p $RPM_BUILD_ROOT%{_prefix}/include
1479 mv $RPM_BUILD_ROOT%{libsubdir}/include/ffitarget.h $RPM_BUILD_ROOT%{_prefix}/include/
1480 mv $RPM_BUILD_ROOT%{libsubdir}/include/ffi.h $RPM_BUILD_ROOT%{_prefix}/include/
1481 rm -f $RPM_BUILD_ROOT%{mainlibdir}/libffi.la
1483 rm -f $RPM_BUILD_ROOT%{mainlibdirbi}/libffi.la
1485 # Generate a simple pkg-config file
1486 mkdir -p $RPM_BUILD_ROOT%{_libdir}/pkgconfig
1487 echo -e 'Name: libffi\nVersion: 3.0.9\nDescription: libffi\nLibs: -lffi' > $RPM_BUILD_ROOT%{_libdir}/pkgconfig/libffi.pc
1491 %if !%{build_libjava}
1492 rm $RPM_BUILD_ROOT%{_mandir}/man1/jv-convert%{binsuffix}.1
1493 rm $RPM_BUILD_ROOT%{_mandir}/man1/gcj-dbtool%{binsuffix}.1
1494 rm $RPM_BUILD_ROOT%{_mandir}/man1/gij%{binsuffix}.1
1495 rm $RPM_BUILD_ROOT%{_mandir}/man1/grmic%{binsuffix}.1
1496 rm $RPM_BUILD_ROOT%{_mandir}/man1/gc-analyze%{binsuffix}.1
1497 rm $RPM_BUILD_ROOT%{_mandir}/man1/aot-compile%{binsuffix}.1
1498 rm $RPM_BUILD_ROOT%{_mandir}/man1/rebuild-gcj-db%{binsuffix}.1
1500 rm -f $RPM_BUILD_ROOT%{_datadir}/gcc%{binsuffix}/python/libjava/aotcompile.py
1501 rm -f $RPM_BUILD_ROOT%{_datadir}/gcc%{binsuffix}/python/libjava/classfile.py
1503 rm -f $RPM_BUILD_ROOT%{_mandir}/man7/fsf-funding.7
1504 rm -f $RPM_BUILD_ROOT%{_mandir}/man7/gfdl.7
1505 rm -f $RPM_BUILD_ROOT%{_mandir}/man7/gpl.7
1506 rm -f $RPM_BUILD_ROOT%{_libdir}/libiberty.a
1508 %if %{build_primary_64bit}
1509 rm -f $RPM_BUILD_ROOT%{_prefix}/lib/libiberty.a
1511 rm -f $RPM_BUILD_ROOT%{_prefix}/lib64/libiberty.a
1514 rm -f $RPM_BUILD_ROOT%{libsubdir}/liblto_plugin.a
1515 rm -f $RPM_BUILD_ROOT%{libsubdir}/liblto_plugin.la
1517 # LIBFFI-DELETE-BEGIN
1518 %if 0%{?building_libjava:1}
1519 # For building libjava only we need to delete other info docs
1520 rm $RPM_BUILD_ROOT%{_infodir}/cp-tools.info*
1521 # Remove stale manpages for binaries we do not build
1522 rm $RPM_BUILD_ROOT%{_mandir}/man1/gjdoc%{binsuffix}.1
1523 # For building the java frontend we need to copy the ecj jar
1524 mkdir -p $RPM_BUILD_ROOT%{libsubdir}
1525 cp $RPM_SOURCE_DIR/ecj.jar $RPM_BUILD_ROOT%{libsubdir}
1527 # For regular build, some info files do not get renamed properly.
1529 mv $RPM_BUILD_ROOT%{_infodir}/libgomp.info $RPM_BUILD_ROOT%{_infodir}/libgomp%{binsuffix}.info
1531 mv $RPM_BUILD_ROOT%{_infodir}/libitm.info $RPM_BUILD_ROOT%{_infodir}/libitm%{binsuffix}.info
1533 %if %{build_fortran}
1534 %ifarch %quadmath_arch
1535 mv $RPM_BUILD_ROOT%{_infodir}/libquadmath.info $RPM_BUILD_ROOT%{_infodir}/libquadmath%{binsuffix}.info
1539 mv $RPM_BUILD_ROOT%{_infodir}/gnat-style.info $RPM_BUILD_ROOT%{_infodir}/gnat-style%{binsuffix}.info
1540 mv $RPM_BUILD_ROOT%{_infodir}/gnat_rm.info $RPM_BUILD_ROOT%{_infodir}/gnat_rm%{binsuffix}.info
1541 mv $RPM_BUILD_ROOT%{_infodir}/gnat_ugn.info $RPM_BUILD_ROOT%{_infodir}/gnat_ugn%{binsuffix}.info
1545 # LIBJAVA-DELETE-BEGIN
1547 %find_lang cpplib%{binsuffix}
1548 %find_lang gcc%{binsuffix}
1549 cat cpplib%{binsuffix}.lang gcc%{binsuffix}.lang > gcc@base_ver@-locale.lang
1553 %install_info --info-dir=%{_infodir} %{_infodir}/cpp%{binsuffix}.info.gz
1554 %install_info --info-dir=%{_infodir} %{_infodir}/cppinternals%{binsuffix}.info.gz
1555 %install_info --info-dir=%{_infodir} %{_infodir}/gcc%{binsuffix}.info.gz
1556 %install_info --info-dir=%{_infodir} %{_infodir}/gccint%{binsuffix}.info.gz
1557 %install_info --info-dir=%{_infodir} %{_infodir}/gccinstall%{binsuffix}.info.gz
1558 %install_info --info-dir=%{_infodir} %{_infodir}/libgomp%{binsuffix}.info.gz
1559 %if %{build_fortran}
1560 %install_info --info-dir=%{_infodir} %{_infodir}/gfortran%{binsuffix}.info.gz
1561 %ifarch %quadmath_arch
1562 %install_info --info-dir=%{_infodir} %{_infodir}/libquadmath%{binsuffix}.info.gz
1566 %install_info --info-dir=%{_infodir} %{_infodir}/gcj%{binsuffix}.info.gz
1569 %install_info --info-dir=%{_infodir} %{_infodir}/gnat-style%{binsuffix}.info.gz
1570 %install_info --info-dir=%{_infodir} %{_infodir}/gnat_rm%{binsuffix}.info.gz
1571 %install_info --info-dir=%{_infodir} %{_infodir}/gnat_ugn%{binsuffix}.info.gz
1575 %install_info_delete --info-dir=%{_infodir} %{_infodir}/cpp%{binsuffix}.info.gz
1576 %install_info_delete --info-dir=%{_infodir} %{_infodir}/cppinternals%{binsuffix}.info.gz
1577 %install_info_delete --info-dir=%{_infodir} %{_infodir}/gcc%{binsuffix}.info.gz
1578 %install_info_delete --info-dir=%{_infodir} %{_infodir}/gccint%{binsuffix}.info.gz
1579 %install_info_delete --info-dir=%{_infodir} %{_infodir}/gccinstall%{binsuffix}.info.gz
1580 %install_info_delete --info-dir=%{_infodir} %{_infodir}/libgomp%{binsuffix}.info.gz
1581 %if %{build_fortran}
1582 %install_info_delete --info-dir=%{_infodir} %{_infodir}/gfortran%{binsuffix}.info.gz
1583 %ifarch %quadmath_arch
1584 %install_info_delete --info-dir=%{_infodir} %{_infodir}/libquadmath%{binsuffix}.info.gz
1588 %install_info_delete --info-dir=%{_infodir} %{_infodir}/gcj%{binsuffix}.info.gz
1591 %install_info_delete --info-dir=%{_infodir} %{_infodir}/gnat-style%{binsuffix}.info.gz
1592 %install_info_delete --info-dir=%{_infodir} %{_infodir}/gnat_rm%{binsuffix}.info.gz
1593 %install_info_delete --info-dir=%{_infodir} %{_infodir}/gnat_ugn%{binsuffix}.info.gz
1597 %manifest gcc.manifest
1598 %defattr(-,root,root)
1600 %dir %{_libdir}/gcc/%{GCCDIST}
1602 %dir %{libsubdir}/include
1603 %dir %{libsubdir}/include-fixed
1605 %if %{build_primary_64bit}
1606 %dir %{libsubdir}/32
1608 %dir %{libsubdir}/64
1611 %{_prefix}/bin/gcc%{binsuffix}
1612 %{_prefix}/bin/gcov%{binsuffix}
1613 %{_prefix}/bin/gcc-ar%{binsuffix}
1614 %{_prefix}/bin/gcc-nm%{binsuffix}
1615 %{_prefix}/bin/gcc-ranlib%{binsuffix}
1616 %{libsubdir}/collect2
1618 %{libsubdir}/lto-wrapper
1619 %{libsubdir}/liblto_plugin.so*
1620 %{libsubdir}/include-fixed/README
1621 %{libsubdir}/include-fixed/limits.h
1622 %{libsubdir}/include-fixed/syslimits.h
1623 %{libsubdir}/include/omp.h
1624 %{libsubdir}/include/float.h
1625 %{libsubdir}/include/iso646.h
1626 %{libsubdir}/include/stdarg.h
1627 %{libsubdir}/include/stdbool.h
1628 %{libsubdir}/include/stdfix.h
1629 %{libsubdir}/include/stddef.h
1630 %{libsubdir}/include/unwind.h
1631 %{libsubdir}/include/varargs.h
1632 %{libsubdir}/include/stdint.h
1633 %{libsubdir}/include/stdint-gcc.h
1634 %{libsubdir}/include/stdnoreturn.h
1635 %{libsubdir}/include/stdalign.h
1637 %{libsubdir}/include/visintrin.h
1640 %{libsubdir}/include/altivec.h
1641 %{libsubdir}/include/ppc-asm.h
1642 %{libsubdir}/include/paired.h
1643 %{libsubdir}/include/ppu_intrinsics.h
1644 %{libsubdir}/include/si2vmx.h
1645 %{libsubdir}/include/spe.h
1646 %{libsubdir}/include/spu2vmx.h
1647 %{libsubdir}/include/vec_types.h
1650 %{libsubdir}/include/ia64intrin.h
1653 %{libsubdir}/include/arm_neon.h
1656 %{libsubdir}/include/mmintrin.h
1657 %{libsubdir}/include/arm_neon.h
1658 %{libsubdir}/include/unwind-arm-common.h
1660 %ifarch %ix86 x86_64
1661 %{libsubdir}/include/cross-stdarg.h
1662 %{libsubdir}/include/cpuid.h
1663 %{libsubdir}/include/mm3dnow.h
1664 %{libsubdir}/include/mmintrin.h
1665 %{libsubdir}/include/ammintrin.h
1666 %{libsubdir}/include/bmmintrin.h
1667 %{libsubdir}/include/emmintrin.h
1668 %{libsubdir}/include/immintrin.h
1669 %{libsubdir}/include/avxintrin.h
1670 %{libsubdir}/include/pmmintrin.h
1671 %{libsubdir}/include/xmmintrin.h
1672 %{libsubdir}/include/tmmintrin.h
1673 %{libsubdir}/include/nmmintrin.h
1674 %{libsubdir}/include/smmintrin.h
1675 %{libsubdir}/include/wmmintrin.h
1676 %{libsubdir}/include/x86intrin.h
1677 %{libsubdir}/include/ia32intrin.h
1678 %{libsubdir}/include/mm_malloc.h
1679 %{libsubdir}/include/fma4intrin.h
1680 %{libsubdir}/include/xopintrin.h
1681 %{libsubdir}/include/lwpintrin.h
1682 %{libsubdir}/include/popcntintrin.h
1683 %{libsubdir}/include/bmiintrin.h
1684 %{libsubdir}/include/tbmintrin.h
1685 %{libsubdir}/include/avx2intrin.h
1686 %{libsubdir}/include/bmi2intrin.h
1687 %{libsubdir}/include/fmaintrin.h
1688 %{libsubdir}/include/lzcntintrin.h
1689 %{libsubdir}/include/f16cintrin.h
1690 %{libsubdir}/include/adxintrin.h
1691 %{libsubdir}/include/fxsrintrin.h
1692 %{libsubdir}/include/prfchwintrin.h
1693 %{libsubdir}/include/rdseedintrin.h
1694 %{libsubdir}/include/rtmintrin.h
1695 %{libsubdir}/include/xsaveintrin.h
1696 %{libsubdir}/include/xsaveoptintrin.h
1697 %{libsubdir}/include/xtestintrin.h
1699 %if %{build_with_mudflap}
1700 %{libsubdir}/include/mf-runtime.h
1702 %versmainlib *crt*.o
1703 %versmainlib libgcc*.a
1704 %versmainlib libgcov.a
1705 %versmainlib libgcc_s*.so
1706 %if %{build_with_mudflap}
1707 %versmainlib libmudflap.a
1708 %versmainlib libmudflap.so
1709 %versmainlib libmudflapth.a
1710 %versmainlib libmudflapth.so
1712 %versmainlib libgomp.so
1713 %versmainlib libgomp.a
1714 %versmainlib libgomp.spec
1716 %versmainlib libitm.so
1717 %versmainlib libitm.a
1718 %versmainlib libitm.spec
1720 %ifarch %atomic_arch
1721 %versmainlib libatomic.so
1722 %versmainlib libatomic.a
1725 %versmainlib libasan.so
1726 %versmainlib libasan.a
1727 %versmainlib libasan_preinit.o
1730 %versmainlib libtsan.so
1731 %versmainlib libtsan.a
1733 %doc %{_mandir}/man1/gcc%{binsuffix}.1.gz
1734 %doc %{_mandir}/man1/gcov%{binsuffix}.1.gz
1736 %if %{separate_biarch}
1737 %files -n gcc@base_ver@%{separate_biarch_suffix}
1738 %manifest gcc.manifest
1739 %defattr(-,root,root)
1740 %versbiarchlib *crt*.o
1741 %versbiarchlib libgcc*.a
1742 %versbiarchlib libgcov.a
1743 %versbiarchlib libgcc_s*.so
1744 %if %{build_with_mudflap}
1745 %versbiarchlib libmudflap.a
1746 %versbiarchlib libmudflap.so
1747 %versbiarchlib libmudflapth.a
1748 %versbiarchlib libmudflapth.so
1750 %versbiarchlib libgomp.so
1751 %versbiarchlib libgomp.a
1752 %versbiarchlib libgomp.spec
1754 %versbiarchlib libitm.so
1755 %versbiarchlib libitm.a
1756 %versbiarchlib libitm.spec
1758 %ifarch %atomic_arch
1759 %versbiarchlib libatomic.a
1760 %versbiarchlib libatomic.so
1763 %versbiarchlib libasan.a
1764 %versbiarchlib libasan.so
1765 %versbiarchlib libasan_preinit.o
1769 %versbiarchlib libtsan.a
1770 %versbiarchlib libtsan.so
1775 %files locale -f gcc@base_ver@-locale.lang
1776 %manifest gcc.manifest
1778 %files -n libstdc++%{libstdcxx_sover}%{libstdcxx_suffix}-locale
1779 %manifest gcc.manifest
1783 %manifest gcc.manifest
1784 %defattr(-,root,root)
1786 %dir %{_libdir}/gcc/%{GCCDIST}
1788 %{_prefix}/bin/g++%{binsuffix}
1789 %doc %{_mandir}/man1/g++%{binsuffix}.1.gz
1790 %{libsubdir}/cc1plus
1792 %files -n libstdc++%{libstdcxx_sover}%{libstdcxx_suffix}
1793 %manifest gcc.manifest
1794 %defattr(-,root,root)
1795 %mainlib libstdc++.so.%{libstdcxx_sover}*
1797 %if %{separate_biarch}
1798 %files -n libstdc++%{libstdcxx_sover}%{libstdcxx_suffix}%{separate_biarch_suffix}
1799 %manifest gcc.manifest
1800 %defattr(-,root,root)
1801 %biarchlib libstdc++.so.%{libstdcxx_sover}*
1804 %files -n libstdc++@base_ver@-devel -f c++-headers
1805 %manifest gcc.manifest
1806 %defattr(-,root,root)
1807 %versmainlib libstdc++.a
1808 %versmainlib libstdc++.so
1809 %versmainlib libsupc++.a
1810 %dir %{_datadir}/gdb
1811 %dir %{_datadir}/gdb/auto-load
1812 %dir %{_datadir}/gdb/auto-load%{_prefix}
1813 %dir %{_datadir}/gdb/auto-load/%{mainlibdir}
1814 %{_datadir}/gdb/auto-load/%{mainlibdir}/libstdc++.so.*-gdb.py
1815 %{_datadir}/gcc%{binsuffix}
1817 %if %{separate_biarch}
1818 %files -n libstdc++@base_ver@-devel%{separate_biarch_suffix}
1819 %manifest gcc.manifest
1820 %defattr(-,root,root)
1821 %versbiarchlib libstdc++.a
1822 %versbiarchlib libstdc++.so
1823 %versbiarchlib libsupc++.a
1824 %dir %{_datadir}/gdb/auto-load/%{mainlibdirbi}
1825 %{_datadir}/gdb/auto-load/%{mainlibdirbi}/libstdc++.so.*-gdb.py
1828 %files -n libstdc++@base_ver@-doc
1829 %manifest gcc.manifest
1830 %defattr(-,root,root)
1831 %doc libstdc++-v3/doc/html
1834 %files -n libgcc_s%{libgcc_s}%{libgcc_s_suffix}
1835 %manifest gcc.manifest
1836 %defattr(-,root,root)
1837 /%{_lib}/libgcc_s.so.%{libgcc_s}
1839 %if %{build_primary_64bit}
1840 %if !%{separate_bi32}
1841 /lib/libgcc_s.so.%{libgcc_s}
1844 %if !%{separate_bi64}
1845 /lib64/libgcc_s.so.%{libgcc_s}
1850 %if %{separate_bi64}
1851 %files -n libgcc_s%{libgcc_s}%{libgcc_s_suffix}-64bit
1852 %manifest gcc.manifest
1853 %defattr(-,root,root)
1854 /lib64/libgcc_s.so.%{libgcc_s}
1857 %if %{separate_bi32}
1858 %files -n libgcc_s%{libgcc_s}%{libgcc_s_suffix}-32bit
1859 %manifest gcc.manifest
1860 %defattr(-,root,root)
1861 /lib/libgcc_s.so.%{libgcc_s}
1865 %files -n libgomp%{libgomp_sover}%{libgomp_suffix}
1866 %manifest gcc.manifest
1867 %defattr(-,root,root)
1868 %mainlib libgomp.so.%{libgomp_sover}*
1870 %if %{separate_biarch}
1871 %files -n libgomp%{libgomp_sover}%{libgomp_suffix}%{separate_biarch_suffix}
1872 %manifest gcc.manifest
1873 %defattr(-,root,root)
1874 %biarchlib libgomp.so.%{libgomp_sover}*
1879 %files -n libasan%{libasan_sover}%{libasan_suffix}
1880 %manifest gcc.manifest
1881 %defattr(-,root,root)
1882 %mainlib libasan.so.%{libasan_sover}*
1884 %if %{separate_biarch}
1885 %files -n libasan%{libasan_sover}%{libasan_suffix}%{separate_biarch_suffix}
1886 %manifest gcc.manifest
1887 %defattr(-,root,root)
1888 %biarchlib libasan.so.%{libasan_sover}*
1894 %files -n libtsan%{libtsan_sover}%{libtsan_suffix}
1895 %manifest gcc.manifest
1896 %defattr(-,root,root)
1897 %mainlib libtsan.so.%{libtsan_sover}*
1900 %if %{separate_biarch}
1901 %files -n libtsan%{libtsan_sover}%{libtsan_suffix}%{separate_biarch_suffix}
1902 %manifest gcc.manifest
1903 %defattr(-,root,root)
1904 %biarchlib libtsan.so.%{libtsan_sover}*
1910 %ifarch %atomic_arch
1911 %files -n libatomic%{libatomic_sover}%{libatomic_suffix}
1912 %manifest gcc.manifest
1913 %defattr(-,root,root)
1914 %mainlib libatomic.so.%{libatomic_sover}*
1916 %if %{separate_biarch}
1917 %files -n libatomic%{libatomic_sover}%{libatomic_suffix}%{separate_biarch_suffix}
1918 %manifest gcc.manifest
1919 %defattr(-,root,root)
1920 %biarchlib libatomic.so.%{libatomic_sover}*
1926 %files -n libitm%{libitm_sover}%{libitm_suffix}
1927 %manifest gcc.manifest
1928 %defattr(-,root,root)
1929 %mainlib libitm.so.%{libitm_sover}*
1931 %if %{separate_biarch}
1932 %files -n libitm%{libitm_sover}%{libitm_suffix}%{separate_biarch_suffix}
1933 %manifest gcc.manifest
1934 %defattr(-,root,root)
1935 %biarchlib libitm.so.%{libitm_sover}*
1941 %if %{build_fortran}
1943 %manifest gcc.manifest
1944 %defattr(-,root,root)
1945 %dir %{libsubdir}/finclude
1946 %{_prefix}/bin/gfortran%{binsuffix}
1948 %{libsubdir}/finclude/*
1949 %versmainlib libgfortran.a
1950 %versmainlib libgfortran.so
1951 %versmainlib libgfortran.spec
1952 %versmainlib libgfortranbegin.a
1953 %versmainlib libcaf_single.a
1954 %ifarch %quadmath_arch
1955 %{libsubdir}/include/quadmath.h
1956 %{libsubdir}/include/quadmath_weak.h
1957 %versmainlib libquadmath.a
1958 %versmainlib libquadmath.so
1960 %doc %{_mandir}/man1/gfortran%{binsuffix}.1.gz
1962 %if %{separate_biarch}
1963 %files fortran%{separate_biarch_suffix}
1964 %manifest gcc.manifest
1965 %defattr(-,root,root)
1966 %versbiarchlib libgfortran.a
1967 %versbiarchlib libgfortran.so
1968 %versbiarchlib libgfortran.spec
1969 %versbiarchlib libgfortranbegin.a
1970 %versbiarchlib libcaf_single.a
1971 %ifarch %quadmath_arch
1972 %versbiarchlib libquadmath.a
1973 %versbiarchlib libquadmath.so
1977 %files -n libgfortran%{libgfortran_sover}%{libgfortran_suffix}
1978 %manifest gcc.manifest
1979 %defattr(-,root,root)
1980 %mainlib libgfortran.so.%{libgfortran_sover}*
1982 %if %{separate_biarch}
1983 %files -n libgfortran%{libgfortran_sover}%{libgfortran_suffix}%{separate_biarch_suffix}
1984 %manifest gcc.manifest
1985 %defattr(-,root,root)
1986 %biarchlib libgfortran.so.%{libgfortran_sover}*
1989 %ifarch %quadmath_arch
1990 %files -n libquadmath%{libquadmath_sover}%{libquadmath_suffix}
1991 %manifest gcc.manifest
1992 %defattr(-,root,root)
1993 %mainlib libquadmath.so.%{libquadmath_sover}*
1995 %if %{separate_biarch}
1996 %files -n libquadmath%{libquadmath_sover}%{libquadmath_suffix}%{separate_biarch_suffix}
1997 %manifest gcc.manifest
1998 %defattr(-,root,root)
1999 %biarchlib libquadmath.so.%{libquadmath_sover}*
2004 %if %{build_with_mudflap}
2005 %files -n libmudflap@base_ver@
2006 %manifest gcc.manifest
2007 %defattr(-,root,root)
2008 %mainlib libmudflap.so.%{libmudflap_sover}*
2009 %mainlib libmudflapth.so.%{libmudflap_sover}*
2011 %if %{separate_biarch}
2012 %files -n libmudflap@base_ver@%{separate_biarch_suffix}
2013 %manifest gcc.manifest
2014 %defattr(-,root,root)
2015 %biarchlib libmudflap.so.%{libmudflap_sover}*
2016 %biarchlib libmudflapth.so.%{libmudflap_sover}*
2021 %manifest gcc.manifest
2022 %defattr(-,root,root)
2023 %doc %{_infodir}/*.gz
2025 %files -n cpp@base_ver@
2026 %manifest gcc.manifest
2027 %defattr(-,root,root)
2029 %dir %{_libdir}/gcc/%{GCCDIST}
2031 %{_prefix}/bin/cpp%{binsuffix}
2034 %doc %{_mandir}/man1/cpp%{binsuffix}.1.gz
2038 %manifest gcc.manifest
2039 %defattr(-,root,root)
2041 %{libsubdir}/include/objc
2042 %versmainlib libobjc.a
2043 %versmainlib libobjc.so
2045 %if %{separate_biarch}
2046 %files objc%{separate_biarch_suffix}
2047 %manifest gcc.manifest
2048 %defattr(-,root,root)
2049 %versbiarchlib libobjc.a
2050 %versbiarchlib libobjc.so
2053 %files -n libobjc%{libobjc_sover}%{libobjc_suffix}
2054 %manifest gcc.manifest
2055 %defattr(-,root,root)
2056 %mainlib libobjc.so.%{libobjc_sover}*
2058 %if %{separate_biarch}
2059 %files -n libobjc%{libobjc_sover}%{libobjc_suffix}%{separate_biarch_suffix}
2060 %manifest gcc.manifest
2061 %defattr(-,root,root)
2062 %biarchlib libobjc.so.%{libobjc_sover}*
2069 %manifest gcc.manifest
2070 %defattr(-,root,root)
2071 %{libsubdir}/cc1objplus
2077 %manifest gcc.manifest
2078 %defattr(-,root,root)
2080 %dir %{_libdir}/gcc/%{GCCDIST}
2082 %{_prefix}/bin/gnat*
2083 %dir %{versmainlibdir}/adainclude
2084 %dir %{versmainlibdir}/adalib
2085 %{versmainlibdir}/adainclude
2086 %{versmainlibdir}/adalib/*.ali
2087 %{versmainlibdir}/adalib/*.a
2088 %{versmainlibdir}/adalib/libgnarl.so
2089 %{versmainlibdir}/adalib/libgnat.so
2090 %{versmainlibdir}/gnat1
2092 %if %{separate_biarch}
2093 %files ada%{separate_biarch_suffix}
2094 %manifest gcc.manifest
2095 %defattr(-,root,root)
2096 %dir %{versmainlibdirbi}/adainclude
2097 %dir %{versmainlibdirbi}/adalib
2098 %{versmainlibdirbi}/adainclude
2099 %{versmainlibdirbi}/adalib/*.ali
2100 %{versmainlibdirbi}/adalib/*.a
2101 %{versmainlibdirbi}/adalib/libgnarl.so
2102 %{versmainlibdirbi}/adalib/libgnat.so
2105 %files -n libada@base_ver@
2106 %manifest gcc.manifest
2107 %defattr(-,root,root)
2108 %mainlib libgnarl-*.so
2109 %mainlib libgnat-*.so
2111 %if %{separate_biarch}
2112 %files -n libada@base_ver@%{separate_biarch_suffix}
2113 %manifest gcc.manifest
2114 %defattr(-,root,root)
2115 %biarchlib libgnarl-*.so
2116 %biarchlib libgnat-*.so
2119 # LIBJAVA-DELETE-END
2123 %if 0%{?building_libjava:1}
2124 %files -n gcc@base_ver@-java
2125 %manifest gcc.manifest
2126 %defattr(-,root,root)
2127 %{_prefix}/bin/gcj%{binsuffix}
2128 %{_prefix}/bin/gcjh%{binsuffix}
2129 %{_prefix}/bin/gcj-dbtool%{binsuffix}
2130 %{_prefix}/bin/jcf-dump%{binsuffix}
2131 %{_prefix}/bin/jv-convert%{binsuffix}
2132 %{_prefix}/bin/gc-analyze%{binsuffix}
2133 %{_prefix}/bin/aot-compile%{binsuffix}
2134 %{_prefix}/bin/rebuild-gcj-db%{binsuffix}
2136 %{libsubdir}/jvgenmain
2137 %{libsubdir}/ecj.jar
2139 %doc %{_mandir}/man1/gcj%{binsuffix}.1.gz
2140 %doc %{_mandir}/man1/gcjh%{binsuffix}.1.gz
2141 %doc %{_mandir}/man1/gcj-dbtool%{binsuffix}.1.gz
2142 %doc %{_mandir}/man1/jcf-dump%{binsuffix}.1.gz
2143 %doc %{_mandir}/man1/jv-convert%{binsuffix}.1.gz
2144 %doc %{_mandir}/man1/gc-analyze%{binsuffix}.1.gz
2145 %doc %{_mandir}/man1/aot-compile%{binsuffix}.1.gz
2146 %doc %{_mandir}/man1/rebuild-gcj-db%{binsuffix}.1.gz
2151 %if %{build_libjava}
2152 %files -n libgcj@base_ver@
2153 %manifest gcc.manifest
2154 %defattr(-,root,root)
2155 %dir %{_libdir}/gcj-%{gcc_dir_version}-%{libgcj_sover}
2157 %dir %{_libdir}/gcc/%{GCCDIST}
2159 %{_libdir}/gcj-%{gcc_dir_version}-%{libgcj_sover}/classmap.db
2160 # We usually do not multilib libjava
2161 %if %{biarch_libjava}
2162 %versbiarchlib libgcj.la
2163 %biarchlib libgcj.so.*
2164 %biarchlib libgij.so.*
2165 %biarchlib libgcj-tools.so.*
2167 %versmainlib libgcj.la
2168 %mainlib libgcj.so.*
2169 %mainlib libgij.so.*
2170 %mainlib libgcj-tools.so.*
2172 %{_libdir}/gcj-%{gcc_dir_version}-%{libgcj_sover}/libjvm.la
2173 %{_libdir}/gcj-%{gcc_dir_version}-%{libgcj_sover}/libjvm.so
2174 %{_libdir}/gcj-%{gcc_dir_version}-%{libgcj_sover}/libjavamath.la
2175 %{_libdir}/gcj-%{gcc_dir_version}-%{libgcj_sover}/libjavamath.so
2177 %files -n libgcj_bc%{libgcj_bc_sover}%{libgcj_bc_suffix}
2178 %manifest gcc.manifest
2179 %defattr(-,root,root)
2180 %if %{biarch_libjava}
2181 %biarchlib libgcj_bc.so.%{libgcj_bc_sover}*
2183 %mainlib libgcj_bc.so.%{libgcj_bc_sover}*
2186 %files -n libgcj@base_ver@-jar
2187 %manifest gcc.manifest
2188 %defattr(-,root,root)
2189 %{_prefix}/share/java/libgcj-%{gcc_dir_version}.jar
2190 %{_prefix}/share/java/libgcj-tools-%{gcc_dir_version}.jar
2192 %files -n libgcj@base_ver@-devel
2193 %manifest gcc.manifest
2194 %defattr(-,root,root)
2195 %dir %{_prefix}/include/c++
2197 %dir %{libsubdir}/include
2199 %{_libdir}/pkgconfig/libgcj%{binsuffix}.pc
2200 %{libsubdir}/include/jawt.h
2201 %{libsubdir}/include/jawt_md.h
2202 %{libsubdir}/include/jni.h
2203 %{libsubdir}/include/jni_md.h
2204 %{libsubdir}/include/jvmpi.h
2211 %{libsubdir}/include/gcj
2212 %if %{biarch_libjava}
2213 %versbiarchlib libgcj.so
2214 %versbiarchlib libgcj.spec
2215 %versbiarchlib libgcj-tools.so
2216 %versbiarchlib libgij.so
2217 %versbiarchlib libgcj_bc.so
2219 %versmainlib libgcj.so
2220 %versmainlib libgcj.spec
2221 %versmainlib libgcj-tools.so
2222 %versmainlib libgij.so
2223 %versmainlib libgcj_bc.so
2226 %files -n gcc@base_ver@-gij
2227 %manifest gcc.manifest
2228 %defattr(-,root,root)
2229 %{_prefix}/bin/gij%{binsuffix}
2230 %{_prefix}/bin/gappletviewer%{binsuffix}
2231 %{_prefix}/bin/gjar%{binsuffix}
2232 %{_prefix}/bin/gjarsigner%{binsuffix}
2233 %{_prefix}/bin/gjavah%{binsuffix}
2234 %{_prefix}/bin/gkeytool%{binsuffix}
2235 %{_prefix}/bin/gnative2ascii%{binsuffix}
2236 %{_prefix}/bin/gorbd%{binsuffix}
2237 %{_prefix}/bin/grmic%{binsuffix}
2238 %{_prefix}/bin/grmid%{binsuffix}
2239 %{_prefix}/bin/grmiregistry%{binsuffix}
2240 %{_prefix}/bin/gserialver%{binsuffix}
2241 %{_prefix}/bin/gtnameserv%{binsuffix}
2242 %doc %{_mandir}/man1/gij%{binsuffix}.1.gz
2243 %doc %{_mandir}/man1/gappletviewer%{binsuffix}.1.gz
2244 %doc %{_mandir}/man1/grmic%{binsuffix}.1.gz
2245 %doc %{_mandir}/man1/grmid%{binsuffix}.1.gz
2246 %doc %{_mandir}/man1/grmiregistry%{binsuffix}.1.gz
2247 %doc %{_mandir}/man1/gkeytool%{binsuffix}.1.gz
2248 %doc %{_mandir}/man1/gjar%{binsuffix}.1.gz
2249 %doc %{_mandir}/man1/gjarsigner%{binsuffix}.1.gz
2250 %doc %{_mandir}/man1/gjavah%{binsuffix}.1.gz
2251 %doc %{_mandir}/man1/gnative2ascii%{binsuffix}.1.gz
2252 %doc %{_mandir}/man1/gorbd%{binsuffix}.1.gz
2253 %doc %{_mandir}/man1/gserialver%{binsuffix}.1.gz
2254 %doc %{_mandir}/man1/gtnameserv%{binsuffix}.1.gz
2260 %if 0%{?building_libffi:1}
2261 %files -n libffi%{libffi_sover}%{libffi_suffix}
2262 %manifest gcc.manifest
2263 %defattr(-,root,root)
2264 %mainlib libffi.so.%{libffi_sover}*
2266 %if %{separate_biarch}
2267 %files -n libffi%{libffi_sover}%{libffi_suffix}%{separate_biarch_suffix}
2268 %manifest gcc.manifest
2269 %defattr(-,root,root)
2270 %biarchlib libffi.so.%{libffi_sover}*
2273 %post -n libffi@base_ver@-devel
2274 %install_info --info-dir=%{_infodir} %{_infodir}/libffi%{binsuffix}.info.gz
2275 %postun -n libffi@base_ver@-devel
2276 %install_info_delete --info-dir=%{_infodir} %{_infodir}/libffi%{binsuffix}.info.gz
2278 %files -n libffi@base_ver@-devel
2279 %manifest gcc.manifest
2280 %defattr(-,root,root)
2281 %{_prefix}/include/ffi.h
2282 %{_prefix}/include/ffitarget.h
2285 %{_libdir}/pkgconfig/libffi.pc
2286 %doc %{_infodir}/libffi%{binsuffix}.info.gz
2287 %doc %{_mandir}/man3/ffi%{binsuffix}.3.gz
2288 %doc %{_mandir}/man3/ffi_call%{binsuffix}.3.gz
2289 %doc %{_mandir}/man3/ffi_prep_cif%{binsuffix}.3.gz
2290 %doc %{_mandir}/man3/ffi_prep_cif_var%{binsuffix}.3.gz
2292 %if %{separate_biarch}
2293 %files -n libffi@base_ver@-devel%{separate_biarch_suffix}
2294 %manifest gcc.manifest
2295 %defattr(-,root,root)
2296 %biarchlib libffi.so
2301 # GCC-TESTSUITE-DELETE-END
2303 %if 0%{?run_tests:1}
2304 %files -n gcc@base_ver@-testresults
2305 %manifest gcc.manifest
2306 %defattr(-,root,root)
2307 %doc testresults/test_summary.txt
2308 %doc testresults/*.sum
2309 %doc testresults/*.log