File gcc6.spec of Package gcc6
#
# spec file for package gcc6
#
# Copyright (c) 2025 SUSE LLC and contributors
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.
# Please submit bugfixes or comments via https://bugs.opensuse.org/
#
# icecream 0
%define _lto_cflags %{nil}
%ifarch riscv64
%global __strip /bin/true
%endif
%define tsan_arch x86_64 aarch64
%define asan_arch x86_64 %ix86 ppc ppc64 ppc64le %sparc %arm aarch64
%define itm_arch x86_64 %ix86 %arm aarch64 ppc ppc64 ppc64le s390 s390x %sparc
%define atomic_arch x86_64 %ix86 %arm aarch64 ppc ppc64 ppc64le s390 s390x %sparc m68k ia64 riscv64
%define lsan_arch x86_64 aarch64
%define ubsan_arch x86_64 %ix86 ppc ppc64 ppc64le %arm aarch64
%define cilkrts_arch x86_64 %ix86
%define mpx_arch x86_64 %ix86
# Shared library SONAME versions
%ifarch hppa
%define libgcc_s 4
%else
%ifarch m68k
%define libgcc_s 2
%else
%define libgcc_s 1
%endif
%endif
%define libgcj_sover 17
%define libgcj_bc_sover 1
%define libgomp_sover 1
%define libgomp_plugin_hsa_sover 1
%define libstdcxx_sover 6
%define libasan_sover 3
%define libtsan_sover 0
%define libatomic_sover 1
%define libitm_sover 1
%define libubsan_sover 0
%define liblsan_sover 0
%define libcilkrts_sover 5
%define libmpx_sover 2
%define libmpxwrappers_sover 2
# Shared library package suffix
# This is used for the "non-standard" set of libraries, the standard
# being defined by %product_libs_gcc_ver, the GCC version that should
# provide un-suffixed shared library packages following the shared-library
# policy. Even suffixed variants should provide the shared-library policy
# mandated names and ensure they conflict with each other.
# Individual shared libraries can be directed to be built from individual
# gcc versions by defining %product_libs_gcc_ver_libgcc_s1 for example,
# generally %product_libs_gcc_ver_%name%sover, similarly.
%define itsme6 1
%define plv_ %{!?product_libs_gcc_ver:6}%{?product_libs_gcc_ver}
%define plv() %{expand:%%{!?itsme%{expand:%%{!?product_libs_gcc_ver_%{1}%{2}:%%{plv_}}%%{?product_libs_gcc_ver_%{1}%{2}}}:-gcc6}}
%define libgcc_s_suffix %{plv libgcc_s %{libgcc_s}}
# libgcj SONAME changes with every GCC version
%define libgcj_suffix %nil
%define libgcj_bc_suffix %{plv libgcj_bc %{libgcj_bc_sover}}
%define libgomp_suffix %{plv libgomp %{libgomp_sover}}
%define libgomp_plugin_hsa_suffix %{plv libgomp-plugin-hsa %{libgomp_plugin_hsa_sover}}
%define libstdcxx_suffix %{plv libstdcxx %{libstdcxx_sover}}
%define libasan_suffix %{plv libasan %{libasan_sover}}
%define libtsan_suffix %{plv libtsan %{libtsan_sover}}
%define libatomic_suffix %{plv libatomic %{libatomic_sover}}
%define libitm_suffix %{plv libitm %{libitm_sover}}
%define libubsan_suffix %{plv libubsan %{libubsan_sover}}
%define liblsan_suffix %{plv liblsan %{liblsan_sover}}
%define libcilkrts_suffix %{plv libcilkrts %{libcilkrts_sover}}
%define libmpx_suffix %{plv libmpx %{libmpx_sover}}
%define libmpxwrappers_suffix %{plv libmpxwrappers %{libmpx_sover}}
# libFOO-devel package suffix
%define libdevel_suffix -gcc6
%define selfconflict() %1
Name: gcc6
# With generated files in src we could drop the following
BuildRequires: bison
BuildRequires: flex
BuildRequires: gettext-devel
BuildRequires: makeinfo
# until here, but at least renaming and patching info files breaks this
BuildRequires: fastjar zip gc-devel >= 8.2.99
BuildRequires: gcc-c++
%ifnarch s390x
BuildRequires: glibc-devel-32bit
%endif
BuildRequires: isl-devel
BuildRequires: mpc-devel
BuildRequires: mpfr-devel
BuildRequires: perl
BuildRequires: zlib-devel
# For building the libstdc++ API reference
BuildRequires: doxygen
BuildRequires: graphviz
%ifarch ia64
BuildRequires: libunwind-devel
%endif
#!BuildIgnore: gcc-PIE
URL: http://gcc.gnu.org/
Version: 6.5.0
Release: 0
%define gcc_version %(echo %version | sed 's/+.*//')
%define gcc_dir_version %(echo %gcc_version | cut -d '.' -f 1)
%define gcc_snapshot_revision %(echo %version | sed 's/[3-9]\.[0-9]\.[0-6]//' | sed 's/+/-/')
%define binsuffix -6
Requires: binutils
Requires: cpp6 = %{version}-%{release}
Requires: glibc-devel
Requires: libgcc_s%{libgcc_s} >= %{version}-%{release}
Requires: libgomp%{libgomp_sover} >= %{version}-%{release}
%ifarch %asan_arch
Requires: libasan%{libasan_sover} >= %{version}-%{release}
%endif
%ifarch %tsan_arch
Requires: libtsan%{libtsan_sover} >= %{version}-%{release}
%endif
%ifarch %atomic_arch
Requires: libatomic%{libatomic_sover} >= %{version}-%{release}
%endif
%ifarch %itm_arch
Requires: libitm%{libitm_sover} >= %{version}-%{release}
%endif
%ifarch %cilkrts_arch
Requires: libcilkrts%{libcilkrts_sover} >= %{version}-%{release}
%endif
%ifarch %lsan_arch
Requires: liblsan%{liblsan_sover} >= %{version}-%{release}
%endif
%ifarch %ubsan_arch
Requires: libubsan%{libubsan_sover} >= %{version}-%{release}
%endif
%ifarch %mpx_arch
Requires: libmpx%{libmpx_sover} >= %{version}-%{release}
Requires: libmpxwrappers%{libmpxwrappers_sover} >= %{version}-%{release}
%endif
BuildRoot: %{_tmppath}/%{name}-%{version}-build
Source: gcc-%{gcc_version}%{gcc_snapshot_revision}.tar.xz
Source1: gcc6-rpmlintrc
# Do not upgrade this one, since it might create incompatibilities
# in bootstrapping of java 7 on some platforms.
Source2: https://sourceware.org/pub/java/ecj-4.9.jar
Source3: baselibs.conf
Source100: config.guess
Source101: config.sub
Source1000: https://sourceware.org/pub/java/ecj-4.9-source.tar.bz2
#testpatch begin
Patch1: gcc-dir-version.patch
Patch2: gcc-add-defaultsspec.diff
Patch4: libjava-no-multilib.diff
Patch6: gcc43-no-unwind-tables.diff
Patch10: gcc5-no-return-gcc43-workaround.patch
Patch13: gcc6-SOURCE_DATE_EPOCH.patch
Patch14: gcc6-pr86751.patch
# A set of patches from the RH srpm
Patch50: gcc41-java-slow_pthread_self.patch
# Some patches taken from Debian
Patch60: gcc44-textdomain.patch
Patch61: gcc44-rename-info-files.patch
Patch70: sanitizer-glibc-2.31.patch
Patch71: sanitizer-linux-5.12.patch
Patch72: isl.patch
Patch73: fixincludes.patch
Patch74: sanitizer-glibc-2.42.patch
Patch80: riscv64.patch
Patch90: system-boehm-gc.patch
#testpatch end
Summary: The GNU C Compiler and Support Files
License: GPL-3.0-or-later
Group: Development/Languages/C and C++
%description
Core package for the GNU Compiler Collection, including the C language
frontend.
Language frontends other than C are split to different sub-packages,
namely gcc-c++ and gcc-java.
%package devel
Summary: Development files for developing GCC plugins
License: GPL-3.0-or-later
Group: Development/Languages/C and C++
Requires: gcc6 = %{version}-%{release}
Requires: gmp-devel
Requires: mpc-devel
%description devel
Development files for developing GCC plugins.
%package locale
Summary: Locale Data for the GNU Compiler Collection
License: GPL-3.0-or-later
Group: Development/Languages/C and C++
Requires: gcc6 = %{version}-%{release}
%description locale
Locale data for the GNU Compiler Collection (GCC) to give error message
in the current locale.
%package c++
Summary: The GNU C++ Compiler
License: GPL-3.0-or-later
Group: Development/Languages/C and C++
Requires: gcc6 = %{version}-%{release}
Requires: gcc6-c++ = %{version}-%{release}
Requires: libstdc++%{libstdcxx_sover}-devel%{libdevel_suffix} = %{version}-%{release}
%description c++
This package contains the GNU compiler for C++.
%package -n libstdc++%{libstdcxx_sover}-devel%{libdevel_suffix}
Summary: Include Files and Libraries mandatory for Development
License: GPL-3.0-only WITH GCC-exception-3.1
Group: Development/Languages/C and C++
Requires: glibc-devel
Requires: libstdc++%{libstdcxx_sover} >= %{version}-%{release}
Obsoletes: libstdc++6-devel < %{version}-%{release}
%ifarch ia64
Requires: libunwind-devel
%endif
%description -n libstdc++%{libstdcxx_sover}-devel%{libdevel_suffix}
This package contains all the headers and libraries of the standard C++
library. It is needed for compiling C++ code.
%package -n libgcc_s%{libgcc_s}%{libgcc_s_suffix}
Summary: C compiler runtime library
License: GPL-3.0-only WITH GCC-exception-3.1
Group: System/Base
Provides: libgcc_s%{libgcc_s} = %{version}-%{release}
# Only one package may provide this - allows multiple gcc versions
# to co-exist without an overly large list of provides/obsoletes
Conflicts: %selfconflict libgcc_s%{libgcc_s}
%description -n libgcc_s%{libgcc_s}%{libgcc_s_suffix}
Libgcc is needed for dynamically linked C programs.
%post -n libgcc_s%{libgcc_s}%{libgcc_s_suffix} -p /sbin/ldconfig
%postun -n libgcc_s%{libgcc_s}%{libgcc_s_suffix} -p /sbin/ldconfig
%package -n libgomp%{libgomp_sover}%{libgomp_suffix}
Summary: The GNU compiler collection OpenMP runtime library
License: GPL-3.0-only WITH GCC-exception-3.1
Group: System/Base
Provides: libgomp%{libgomp_sover} = %{version}-%{release}
# Only one package may provide this - allows multiple gcc versions
# to co-exist without an overly large list of provides/obsoletes
Conflicts: %selfconflict libgomp%{libgomp_sover}
%description -n libgomp%{libgomp_sover}%{libgomp_suffix}
This is the OpenMP runtime library needed by OpenMP enabled programs
that were built with the -fopenmp compiler option and by programs that
were auto-parallelized via the -ftree-parallelize-loops compiler
option.
%post -n libgomp%{libgomp_sover}%{libgomp_suffix} -p /sbin/ldconfig
%postun -n libgomp%{libgomp_sover}%{libgomp_suffix} -p /sbin/ldconfig
%package -n libstdc++%{libstdcxx_sover}%{libstdcxx_suffix}
Summary: The standard C++ shared library
License: GPL-3.0-only WITH GCC-exception-3.1
Group: System/Libraries
Provides: libstdc++%{libstdcxx_sover} = %{version}-%{release}
# Only one package may provide this - allows multiple gcc versions
# to co-exist without an overly large list of provides/obsoletes
Conflicts: %selfconflict libstdc++%{libstdcxx_sover}
%description -n libstdc++%{libstdcxx_sover}%{libstdcxx_suffix}
The standard C++ library, needed for dynamically linked C++ programs.
%post -n libstdc++%{libstdcxx_sover}%{libstdcxx_suffix} -p /sbin/ldconfig
%postun -n libstdc++%{libstdcxx_sover}%{libstdcxx_suffix} -p /sbin/ldconfig
%package -n libstdc++%{libstdcxx_sover}%{libstdcxx_suffix}-locale
Summary: Locale Data for the standard C++ shared library
License: GPL-3.0-only WITH GCC-exception-3.1
Group: System/Libraries
Provides: libstdc++%{libstdcxx_sover}-locale = %{version}-%{release}
# Only one package may provide this - allows multiple gcc versions
# to co-exist without an overly large list of provides/obsoletes
Conflicts: %selfconflict libstdc++%{libstdcxx_sover}-locale
%description -n libstdc++%{libstdcxx_sover}%{libstdcxx_suffix}-locale
The standard C++ library locale data.
%package info
Summary: Documentation for the GNU compiler collection
License: GFDL-1.2-only
Group: Documentation/Other
PreReq: %{install_info_prereq}
BuildArch: noarch
%description info
GNU info-pages for the GNU compiler collection covering both user-level
and internals documentation.
%package -n cpp6
Summary: The GCC Preprocessor
License: GPL-3.0-or-later
Group: Development/Languages/C and C++
%description -n cpp6
This Package contains just the preprocessor that is used by the X11
packages.
%package -n libitm%{libitm_sover}%{libitm_suffix}
Summary: The GNU Compiler Transactional Memory Runtime Library
License: MIT
Group: Development/Languages/C and C++
Provides: libitm%{libitm_sover} = %{version}-%{release}
# Only one package may provide this - allows multiple gcc versions
# to co-exist without an overly large list of provides/obsoletes
Conflicts: %selfconflict libitm%{libitm_sover}
%description -n libitm%{libitm_sover}%{libitm_suffix}
The runtime library needed to run programs compiled with the
-fgnu-tm option of the GNU Compiler Collection (GCC).
%post -n libitm%{libitm_sover}%{libitm_suffix} -p /sbin/ldconfig
%postun -n libitm%{libitm_sover}%{libitm_suffix} -p /sbin/ldconfig
%package -n libasan%{libasan_sover}%{libasan_suffix}
Summary: The GNU Compiler Address Sanitizer Runtime Library
License: MIT
Group: Development/Languages/C and C++
Provides: libasan%{libasan_sover} = %{version}-%{release}
# Only one package may provide this - allows multiple gcc versions
# to co-exist without an overly large list of provides/obsoletes
Conflicts: %selfconflict libasan%{libasan_sover}
%description -n libasan%{libasan_sover}%{libasan_suffix}
The runtime library needed to run programs compiled with the
-fsanitize=address option of the GNU Compiler Collection (GCC).
%post -n libasan%{libasan_sover}%{libasan_suffix} -p /sbin/ldconfig
%postun -n libasan%{libasan_sover}%{libasan_suffix} -p /sbin/ldconfig
%package -n libtsan%{libtsan_sover}%{libtsan_suffix}
Summary: The GNU Compiler Thread Sanitizer Runtime Library
License: MIT
Group: Development/Languages/C and C++
Provides: libtsan%{libtsan_sover} = %{version}-%{release}
# Only one package may provide this - allows multiple gcc versions
# to co-exist without an overly large list of provides/obsoletes
Conflicts: %selfconflict libtsan%{libtsan_sover}
%description -n libtsan%{libtsan_sover}%{libtsan_suffix}
The runtime library needed to run programs compiled with the
-fsanitize=thread option of the GNU Compiler Collection (GCC).
%post -n libtsan%{libtsan_sover}%{libtsan_suffix} -p /sbin/ldconfig
%postun -n libtsan%{libtsan_sover}%{libtsan_suffix} -p /sbin/ldconfig
%package -n libatomic%{libatomic_sover}%{libatomic_suffix}
Summary: The GNU Compiler Atomic Operations Runtime Library
License: GPL-3.0-only WITH GCC-exception-3.1
Group: Development/Languages/C and C++
Provides: libatomic%{libatomic_sover} = %{version}-%{release}
# Only one package may provide this - allows multiple gcc versions
# to co-exist without an overly large list of provides/obsoletes
Conflicts: %selfconflict libatomic%{libatomic_sover}
%description -n libatomic%{libatomic_sover}%{libatomic_suffix}
The runtime library for atomic operations of the GNU Compiler Collection (GCC).
%post -n libatomic%{libatomic_sover}%{libatomic_suffix} -p /sbin/ldconfig
%postun -n libatomic%{libatomic_sover}%{libatomic_suffix} -p /sbin/ldconfig
%package -n libcilkrts%{libcilkrts_sover}%{libcilkrts_suffix}
Summary: The GNU Compiler Cilk+ Runtime Library
License: MIT
Group: Development/Languages/C and C++
Provides: libcilkrts%{libcilkrts_sover} = %{version}-%{release}
# Only one package may provide this - allows multiple gcc versions
# to co-exist without an overly large list of provides/obsoletes
Conflicts: %selfconflict libcilkrts%{libcilkrts_sover}
%description -n libcilkrts%{libcilkrts_sover}%{libcilkrts_suffix}
The runtime library needed to run programs compiled with the
-fcilkplus option of the GNU Compiler Collection (GCC).
%post -n libcilkrts%{libcilkrts_sover}%{libcilkrts_suffix} -p /sbin/ldconfig
%postun -n libcilkrts%{libcilkrts_sover}%{libcilkrts_suffix} -p /sbin/ldconfig
%package -n liblsan%{liblsan_sover}%{liblsan_suffix}
Summary: The GNU Compiler Leak Sanitizer Runtime Library
License: MIT
Group: Development/Languages/C and C++
Provides: liblsan%{liblsan_sover} = %{version}-%{release}
# Only one package may provide this - allows multiple gcc versions
# to co-exist without an overly large list of provides/obsoletes
Conflicts: %selfconflict liblsan%{liblsan_sover}
%description -n liblsan%{liblsan_sover}%{liblsan_suffix}
The runtime library needed to run programs compiled with the
-fsanitize=leak option of the GNU Compiler Collection (GCC).
%post -n liblsan%{liblsan_sover}%{liblsan_suffix} -p /sbin/ldconfig
%postun -n liblsan%{liblsan_sover}%{liblsan_suffix} -p /sbin/ldconfig
%package -n libubsan%{libubsan_sover}%{libubsan_suffix}
Summary: The GNU Compiler Undefined Sanitizer Runtime Library
License: MIT
Group: Development/Languages/C and C++
Provides: libubsan%{libubsan_sover} = %{version}-%{release}
# Only one package may provide this - allows multiple gcc versions
# to co-exist without an overly large list of provides/obsoletes
Conflicts: %selfconflict libubsan%{libubsan_sover}
%description -n libubsan%{libubsan_sover}%{libubsan_suffix}
The runtime library needed to run programs compiled with the
-fsanitize=undefined option of the GNU Compiler Collection (GCC).
%post -n libubsan%{libubsan_sover}%{libubsan_suffix} -p /sbin/ldconfig
%postun -n libubsan%{libubsan_sover}%{libubsan_suffix} -p /sbin/ldconfig
%package -n libmpx%{libmpx_sover}%{libmpx_suffix}
Summary: The GNU Compiler MPX Runtime Library
License: BSD-3-Clause
Group: Development/Languages/C and C++
Provides: libmpx%{libmpx_sover} = %{version}-%{release}
# Only one package may provide this - allows multiple gcc versions
# to co-exist without an overly large list of provides/obsoletes
Conflicts: %selfconflict libmpx%{libmpx_sover}
%description -n libmpx%{libmpx_sover}%{libmpx_suffix}
The runtime library needed to run programs compiled with the
-fcheck-pointer-bounds option of the GNU Compiler Collection (GCC).
%post -n libmpx%{libmpx_sover}%{libmpx_suffix} -p /sbin/ldconfig
%postun -n libmpx%{libmpx_sover}%{libmpx_suffix} -p /sbin/ldconfig
%package -n libmpxwrappers%{libmpxwrappers_sover}%{libmpxwrappers_suffix}
Summary: The GNU Compiler MPX Runtime Library
License: BSD-3-Clause
Group: Development/Languages/C and C++
Provides: libmpxwrappers%{libmpxwrappers_sover} = %{version}-%{release}
# Only one package may provide this - allows multiple gcc versions
# to co-exist without an overly large list of provides/obsoletes
Conflicts: %selfconflict libmpxwrappers%{libmpxwrappers_sover}
%description -n libmpxwrappers%{libmpxwrappers_sover}%{libmpxwrappers_suffix}
The runtime library needed to run programs compiled with the
-fcheck-pointer-bounds option of the GNU Compiler Collection (GCC).
%post -n libmpxwrappers%{libmpxwrappers_sover}%{libmpxwrappers_suffix} -p /sbin/ldconfig
%postun -n libmpxwrappers%{libmpxwrappers_sover}%{libmpxwrappers_suffix} -p /sbin/ldconfig
%package -n libgcj%{libdevel_suffix}
Summary: Java Runtime Library for gcc
License: GPL-2.0-only WITH Classpath-exception-2.0
Group: System/Libraries
Recommends: libgcj-jar%{libdevel_suffix} = %{version}-%{release}
Provides: libgcj%{libgcj_sover} = %{version}-%{release}
Conflicts: %selfconflict libgcj%{libgcj_sover}
Provides: libgij%{libgcj_sover} = %{version}-%{release}
Conflicts: %selfconflict libgij%{libgcj_sover}
Provides: libgcj-tools%{libgcj_sover} = %{version}-%{release}
Conflicts: %selfconflict libgcj-tools%{libgcj_sover}
%description -n libgcj%{libdevel_suffix}
This library is needed if you want to use the GNU Java compiler, gcj.
Source code for this package is in gcc.
%post -n libgcj%{libdevel_suffix} -p /sbin/ldconfig
%postun -n libgcj%{libdevel_suffix} -p /sbin/ldconfig
%package java
Summary: The GNU Java Compiler
License: GPL-3.0-or-later
Group: Development/Languages/Java
Requires: libgcj-devel%{libdevel_suffix} = %{version}-%{release}
%description java
The Java compiler from the GCC-tools-suite.
%package -n libgcj_bc%{libgcj_bc_sover}%{libgcj_bc_suffix}
Summary: Fake library for BC-ABI compatibility.
# libgcj_bc is special in that it just contains a symlink to
# a proper libgcj version. So require that library and add
# provides for the shlib version as created at link time
License: GPL-2.0-only WITH Classpath-exception-2.0
Group: Development/Libraries/Java
Requires: libgcj%{libgcj_sover} >= %{version}-%{release}
%ifarch x86_64 ia64 ppc64 s390x sparc64 aarch64
Provides: libgcj_bc.so.%{libgcj_bc_sover}()(64bit)
%else
Provides: libgcj_bc.so.%{libgcj_bc_sover}
%endif
Provides: libgcj_bc%{libgcj_bc_sover} = %{version}-%{release}
# Only one package may provide this - allows multiple gcc versions
# to co-exist without an overly large list of provides/obsoletes
Conflicts: %selfconflict libgcj_bc%{libgcj_bc_sover}
%description -n libgcj_bc%{libgcj_bc_sover}%{libgcj_bc_suffix}
A fake library that is used at link time only. It ensures that
binaries built with the BC-ABI link against a constant SONAME.
This way, BC-ABI binaries continue to work if the SONAME underlying
libgcj.so changes.
%package -n libgcj-jar%{libdevel_suffix}
Summary: Java runtime library (jar files).
License: GPL-2.0-only WITH Classpath-exception-2.0
Group: Development/Libraries/Java
Obsoletes: libgcj6-jar < %{version}-%{release}
%description -n libgcj-jar%{libdevel_suffix}
These are the jar files that go along with the gcj front end to gcc.
%package -n libgcj-devel%{libdevel_suffix}
Summary: Include Files and Libraries mandatory for Development.
License: GPL-2.0-only WITH Classpath-exception-2.0
Group: Development/Libraries/Java
Requires: libgcj%{libgcj_sover} >= %{version}-%{release}
Requires: libgcj-jar%{libdevel_suffix} = %{version}-%{release}
Requires: libgcj_bc%{libgcj_bc_sover} >= %{version}-%{release}
Obsoletes: libgcj6-devel < %{version}-%{release}
%description -n libgcj-devel%{libdevel_suffix}
This package contains all necessary include files and libraries needed
to develop applications that require these.
%package gij
Summary: Java Bytecode Interpreter for gcc
License: GPL-2.0-only WITH Classpath-exception-2.0
Group: Development/Libraries/Java
Requires: libgcj%{libgcj_sover} >= %{version}-%{release}
%description gij
This package contains the java bytecode interpreter gij and related tools.
%package -n libstdc++%{libstdcxx_sover}%{libdevel_suffix}-doc
Summary: Documentation for the GNU C++ standard library
License: GPL-3.0-or-later
Group: Documentation/HTML
BuildArch: noarch
%description -n libstdc++%{libstdcxx_sover}%{libdevel_suffix}-doc
Extensive HTML documentation for the GNU C++ standard library.
# Define the canonical target and host architecture
# %gcc_target_arch is supposed to be the full target triple
# %cross_arch is supposed to be the rpm target variant arch
# %TARGET_ARCH will be the canonicalized target CPU part
# %HOST_ARCH will be the canonicalized host CPU part
%if 0%{?gcc_target_arch:1}
%define TARGET_ARCH %(echo %{cross_arch} | sed -e "s/i.86/i586/;s/ppc/powerpc/;s/sparc64.*/sparc64/;s/sparcv.*/sparc/;")
%else
%define TARGET_ARCH %(echo %{_target_cpu} | sed -e "s/i.86/i586/;s/ppc/powerpc/;s/sparc64.*/sparc64/;s/sparcv.*/sparc/;")
%endif
%define HOST_ARCH %(echo %{_host_cpu} | sed -e "s/i.86/i586/;s/ppc/powerpc/;s/sparc64.*/sparc64/;s/sparcv.*/sparc/;")
%ifarch ppc
%define GCCDIST powerpc64-suse-linux
%else
%ifarch %sparc
%define GCCDIST sparc64-suse-linux
%else
%ifarch %arm
%define GCCDIST %{HOST_ARCH}-suse-linux-gnueabi
%else
%define GCCDIST %{HOST_ARCH}-suse-linux
%endif
%endif
%endif
%define libsubdir %{_libdir}/gcc/%{GCCDIST}/%{gcc_dir_version}
%define gxxinclude %{_prefix}/include/c++/%{gcc_dir_version}
# Versionspecific directories
%define versmainlibdir %{libsubdir}
%define mainlibdir %{_libdir}
# Now define a few macros that make it easy to package libs and
# related files just to the right package, without caring for the
# exact path the files are in.
# %mainlib package X from all dirs that belong to the main package
%define mainlib() %{mainlibdir}/%1\
%{nil}
%define versmainlib() %{versmainlibdir}/%1\
%{nil}
%prep
%setup -q -n gcc-%{gcc_version}%{gcc_snapshot_revision}
cp %{SOURCE100} .
cp %{SOURCE100} libjava/classpath/
cp %{SOURCE100} libjava/libltdl/
cp %{SOURCE101} .
cp %{SOURCE101} libjava/classpath/
cp %{SOURCE101} libjava/libltdl/
#test patching start
%patch -P 1
%patch -P 2
%patch -P 4
%patch -P 6
%patch -P 10
%patch -P 13
%patch -P 14 -R
%patch -P 50
%patch -P 60
%patch -P 61
%patch -P 70 -p1
%patch -P 71 -p1
%patch -P 72 -p1
%patch -P 73 -p1
%patch -P 74 -p1
%patch -P 80 -p1
%patch -P 90 -p1
rm -rf boehm-gc
#test patching end
# We are configuring ppc as ppc64 but with switched multilibs. Adjust
# the libstdc++ abi testsuite baseline files accordingly
%ifarch ppc
if [ -d libstdc++-v3/config/abi/post/powerpc64-linux-gnu ]; then
mkdir -p libstdc++-v3/config/abi/post/powerpc64-linux-gnu/64
mv libstdc++-v3/config/abi/post/powerpc64-linux-gnu/baseline_symbols.txt \
libstdc++-v3/config/abi/post/powerpc64-linux-gnu/64/
mv libstdc++-v3/config/abi/post/powerpc64-linux-gnu/32/baseline_symbols.txt \
libstdc++-v3/config/abi/post/powerpc64-linux-gnu/
fi
%endif
%build
# Avoid rebuilding of generated files
contrib/gcc_update --touch
# Avoid fucking up testsuite results with Java and indirect dispatch
export SUSE_ASNEEDED=0
# Split version file into version used for directories (X) and
# version to report with --version (X.Y.Z).
# See also gcc-dir-version.patch.
mv gcc/BASE-VER gcc/FULL-VER
cat gcc/FULL-VER | cut -d '.' -f 1 > gcc/BASE-VER
rm -rf obj-%{GCCDIST}
mkdir obj-%{GCCDIST}
cd obj-%{GCCDIST}
RPM_OPT_FLAGS="$RPM_OPT_FLAGS -U_FORTIFY_SOURCE"
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/-fstack-clash-protection//g'`
%ifarch %ix86
# -mcpu is superceded by -mtune but -mtune is not supported by
# our bootstrap compiler. -mcpu gives a warning that stops
# the build process, so remove it for now. Also remove all other
# -march and -mtune flags. They are superseeded by proper
# default compiler settings now.
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'`
%endif
%ifarch s390 s390x
RPM_OPT_FLAGS=`echo $RPM_OPT_FLAGS|sed -e 's/-fsigned-char//g'`
RPM_OPT_FLAGS=`echo $RPM_OPT_FLAGS|sed -e 's/-O1/-O2/g'`
%endif
%ifarch aarch64
RPM_OPT_FLAGS=`echo $RPM_OPT_FLAGS|sed -e 's/-mbranch-protection=standard//g'`
%endif
# Trying to work around the gcc 13 ICE in boehm-gc
%ifarch riscv64
RPM_OPT_FLAGS=`echo $RPM_OPT_FLAGS|sed -e 's/-O2/-O1/g'`
RPM_OPT_FLAGS="$RPM_OPT_FLAGS -DUSE_GENERIC_PUSH_REGS=1"
%endif
%if 0%{?gcc_target_arch:1}
# Kill all -march/tune/cpu because that screws building the target libs
RPM_OPT_FLAGS=`echo $RPM_OPT_FLAGS|sed -e 's/-m\(arch\|tune\|cpu\)=[^ ]*//g'`
%endif
# Replace 2 spaces by one finally
RPM_OPT_FLAGS=`echo $RPM_OPT_FLAGS|sed -e 's/ / /g'`
languages=java
J=%{?jobs:%jobs}
if test -z "$J"; then
J=$(getconf _NPROCESSORS_CONF)
JL=$(($J * 2))
else
test 1 -gt "$J" && J=1
JL=$(($(getconf _NPROCESSORS_CONF)*2))
fi
if test "$J" == "0"; then
J=1
fi
if test "$JL" == "0"; then
JL=1
fi
PARALLEL="-j$J -l$JL"
# we don't want some miscompiles in the testsuite, or some fault in
# the compiler to kill the machine. Hence we limit the amount of memory
# by the physical RAM plus half of swap
#MEM=$(free -m | awk '/^Mem:/ {print $2}')
#SWAP=$(free -m | awk '/^Swap:/ {print $2}')
#ulimit -v $(((MEM + SWAP/2)*1024))
# In general we want to ship release checking enabled compilers
# which is the default for released compilers
#ENABLE_CHECKING="--enable-checking=yes"
ENABLE_CHECKING="--enable-checking=release"
#ENABLE_CHECKING=""
# Work around tail/head -1 changes
export _POSIX2_VERSION=199209
%if "%{TARGET_ARCH}" == "armv7hl"
# temporary workaround for a miscompilation of hash functions in java code
GCJ_EXTRA_FLAGS="-marm"
%endif
CFLAGS="$RPM_OPT_FLAGS" CXXFLAGS="$RPM_OPT_FLAGS" XCFLAGS="$RPM_OPT_FLAGS" \
TCFLAGS="$RPM_OPT_FLAGS" GCJFLAGS="$RPM_OPT_FLAGS $GCJ_EXTRA_FLAGS" \
../configure \
--prefix=%{_prefix} \
--infodir=%{_infodir} \
--mandir=%{_mandir} \
--libdir=%{_libdir} \
--libexecdir=%{_libdir} \
--enable-languages=$languages \
--disable-libquadmath \
$ENABLE_CHECKING \
--with-gxx-include-dir=%{_prefix}/include/c++/%{gcc_dir_version} \
--enable-ssp \
--disable-libssp \
--disable-libvtv \
--disable-bootstrap \
%ifnarch %mpx_arch
--disable-libmpx \
%endif
--disable-libcc1 \
--disable-plugin \
--with-bugurl="http://bugs.opensuse.org/" \
--with-pkgversion="SUSE Linux" \
--with-java-home=%{_libdir}/jvm/java-1.5.0-gcj%{binsuffix}-1.5.0.0/jre \
--with-ecj-jar=%{libsubdir}/ecj.jar \
--disable-java-awt \
--disable-libjava-multilib \
--with-slibdir=/%{_lib} \
--with-system-zlib \
--enable-__cxa_atexit \
--enable-libstdcxx-allocator=new \
--disable-libstdcxx-pch \
--enable-version-specific-runtime-libs \
--enable-linker-build-id \
--enable-linux-futex \
%ifarch %ix86 x86_64 ppc ppc64 ppc64le %arm aarch64 s390 s390x %sparc
--enable-gnu-indirect-function \
%endif
--program-suffix=%{binsuffix} \
--disable-multilib \
%if 0%{!?gcc_target_arch:1}
%ifarch ia64
--with-system-libunwind \
%else
--without-system-libunwind \
%endif
%endif
%if 0%{?gcc_target_arch:1}
--program-prefix=%{gcc_target_arch}- \
--target=%{gcc_target_arch} \
--disable-nls \
%if 0%{?sysroot:1}
--with-sysroot=%sysroot \
%else
--with-sysroot=%{_prefix}/%{gcc_target_arch} \
%endif
%if 0%{?build_sysroot:1}
--with-build-sysroot=%{build_sysroot} \
%else
%if 0%{?sysroot:1}
--with-build-sysroot=%{sysroot} \
%else
--with-build-sysroot=%{_prefix}/%{gcc_target_arch} \
%endif
%endif
%if 0%{?binutils_os:1}
--with-build-time-tools=/usr/%{binutils_os}/bin \
%endif
%if 0%{?gcc_target_newlib}
--with-newlib \
%if 0%{?gcc_libc_bootstrap:1}
--without-headers \
%endif
%endif
%if "%{TARGET_ARCH}" == "spu"
--with-gxx-include-dir=%sysroot/include/c++/%{gcc_dir_version} \
--with-newlib \
%endif
%endif
%if "%{TARGET_ARCH}" == "arm"
--with-arch=armv6zk \
--with-tune=arm1176jzf-s \
--with-float=hard \
--with-abi=aapcs-linux \
--with-fpu=vfp \
--disable-sjlj-exceptions \
%endif
%if "%{TARGET_ARCH}" == "armv5tel"
--with-arch=armv5te \
--with-float=soft \
--with-mode=arm \
--with-abi=aapcs-linux \
--disable-sjlj-exceptions \
%endif
%if "%{TARGET_ARCH}" == "armv6hl"
--with-arch=armv6zk \
--with-tune=arm1176jzf-s \
--with-float=hard \
--with-abi=aapcs-linux \
--with-fpu=vfp \
--disable-sjlj-exceptions \
%endif
%if "%{TARGET_ARCH}" == "armv7hl"
--with-arch=armv7-a \
--with-tune=cortex-a15 \
--with-float=hard \
--with-abi=aapcs-linux \
--with-fpu=vfpv3-d16 \
--disable-sjlj-exceptions \
%endif
%if "%{TARGET_ARCH}" == "powerpc" || "%{TARGET_ARCH}" == "powerpc64" || "%{TARGET_ARCH}" == "powerpc64le"
%if "%{TARGET_ARCH}" == "powerpc"
--with-cpu=default32 \
%endif
%if "%{TARGET_ARCH}" == "powerpc64le"
%if %{suse_version} >= 1315 && %{suse_version} != 1320
--with-cpu=power8 \
--with-tune=power8 \
%else
--with-cpu=power7 \
--with-tune=power7 \
%endif
%else
--with-cpu-64=power4 \
%endif
--enable-secureplt \
--with-long-double-128 \
%if "%{TARGET_ARCH}" == "powerpc64le"
--enable-targets=powerpcle-linux \
%endif
%endif
%if "%{TARGET_ARCH}" == "sparc64"
--with-cpu=ultrasparc \
--with-long-double-128 \
%endif
%if "%{TARGET_ARCH}" == "sparc"
--with-cpu=v8 \
--with-long-double-128 \
%endif
%if "%{TARGET_ARCH}" == "i586"
--with-arch-32=i586 \
--with-tune=generic \
%endif
%if "%{TARGET_ARCH}" == "x86_64"
--with-arch-32=x86-64 \
--with-tune=generic \
%endif
%if "%{TARGET_ARCH}" == "s390"
%if %{suse_version} >= 1310
--with-tune=zEC12 --with-arch=z196 \
%else
--with-tune=z9-109 --with-arch=z900 \
%endif
--with-long-double-128 \
--enable-decimal-float \
%endif
%if "%{TARGET_ARCH}" == "s390x"
%if %{suse_version} >= 1310
--with-tune=zEC12 --with-arch=z196 \
%else
--with-tune=z9-109 --with-arch=z900 \
%endif
--with-long-double-128 \
--enable-decimal-float \
%endif
--build=%{GCCDIST} \
--host=%{GCCDIST}
STAGE1_FLAGS="-O1"
# Only run profiled bootstrap on archs where it works and matters
make STAGE1_CFLAGS="$STAGE1_FLAGS" BOOT_CFLAGS="$RPM_OPT_FLAGS" $PARALLEL
make info
%install
export NO_BRP_CHECK_BYTECODE_VERSION=true
%ifarch riscv64
export DONT_STRIP=1
%endif
cd obj-%{GCCDIST}
# Work around tail/head -1 changes
export _POSIX2_VERSION=199209
export LIBRARY_PATH=%{buildroot}%{libsubdir}
%make_install
# Remove libffi installed files if we did not want to build it
rm -f %{buildroot}%{mainlibdir}/libffi.*
rm -f %{buildroot}%{libsubdir}/include/ffi.h
rm -f %{buildroot}%{libsubdir}/include/ffitarget.h
rm -f %{buildroot}%{_mandir}/man3/ffi%{binsuffix}.3*
rm -f %{buildroot}%{_mandir}/man3/ffi_call%{binsuffix}.3*
rm -f %{buildroot}%{_mandir}/man3/ffi_prep_cif%{binsuffix}.3*
rm -f %{buildroot}%{_mandir}/man3/ffi_prep_cif_var%{binsuffix}.3*
# Remove some useless .la files
for lib in libobjc libgfortran libquadmath libcaf_single \
libgomp libgomp-plugin-hsa libstdc++ libsupc++ libgcj-tools libgij libgo \
libasan libatomic libitm libtsan libcilkrts liblsan libubsan \
libmpx libmpxwrappers libstdc++fs; do
rm -f %{buildroot}%{versmainlibdir}/$lib.la
done
mkdir -p %{buildroot}%{_libdir}
# move shared libs from versionspecific dir to main libdir
for libname in \
libgcj libgij libgcj-tools \
libstdc++ \
libgomp \
%ifarch %atomic_arch
libatomic \
%endif
%ifarch %itm_arch
libitm \
%endif
%ifarch %asan_arch
libasan \
%endif
%ifarch %tsan_arch
libtsan \
%endif
%ifarch %cilkrts_arch
libcilkrts \
%endif
%ifarch %lsan_arch
liblsan \
%endif
%ifarch %ubsan_arch
libubsan \
%endif
%ifarch %mpx_arch
libmpx libmpxwrappers \
%endif
; do
for lib in `find %{buildroot}%{versmainlibdir} -maxdepth 1 -name $libname.so.*`; do
mv $lib %{buildroot}%{mainlibdir}/
done
ln -sf %{mainlibdir}/`readlink %{buildroot}%{versmainlibdir}/$libname.so | sed -e 's/\(.*\.so\.[^\.]*\).*/\1/'` \
%{buildroot}%{versmainlibdir}/$libname.so
done
# And we want to move the shlib gdb pretty printers to a more sane
# place so ldconfig does not complain
mkdir -p %{buildroot}%{_datadir}/gdb/auto-load%{mainlibdir}
mv %{buildroot}%{mainlibdir}/libstdc++.so.*-gdb.py %{buildroot}%{_datadir}/gdb/auto-load%{mainlibdir}/
sed -i -e '/^libdir/s/\/gcc\/%{GCCDIST}\/%{gcc_dir_version}//g' %{buildroot}%{_datadir}/gdb/auto-load%{mainlibdir}/libstdc++.so.*-gdb.py
# libgcj_bc is special as the .so file is actually a different
# library as the library refered to by the SONAME which should
# be a simple link to our libgcj.
for lib in `find %{buildroot}%{versmainlibdir} -maxdepth 1 -name libgcj_bc.so.*`; do
rm $lib
done
ln -s libgcj.so.%{libgcj_sover} %{buildroot}%{mainlibdir}/libgcj_bc.so.%{libgcj_bc_sover}
mv %{buildroot}%{libsubdir}/pkgconfig %{buildroot}%{_libdir}/
# Move libgcc_s around
if test -L %{buildroot}/%{_lib}/libgcc_s.so; then
rm -f %{buildroot}/%{_lib}/libgcc_s.so
ln -sf /%{_lib}/libgcc_s.so.%{libgcc_s} %{buildroot}%{versmainlibdir}/libgcc_s.so
else
mv %{buildroot}/%{_lib}/libgcc_s.so %{buildroot}%{versmainlibdir}/
fi
chmod a+x %{buildroot}/%{_lib}/libgcc_s.so.%{libgcc_s}
rm -f %{buildroot}%{_prefix}/bin/c++%{binsuffix}
# Remove some crap from the .la files:
for l in `find %{buildroot} -name '*.la'`; do
echo "changing $l"
# -e '/^dependency_libs/s|%{libsubdir}/\([^.]*\)\.la |%{_libdir}/\1\.la |g'
sed -e '/^dependency_libs/s| -L%{_builddir}/[^ ]*||g' \
-e '/^dependency_libs/s| -L/usr/%{GCCDIST}/bin||g' \
-e '/^dependency_libs/s|-lm \(-lm \)*|-lm |' \
-e '/^dependency_libs/s|-L[^ ]* ||g' \
< $l > $l.new
mv $l.new $l
done
# Find C++ and Java headers
find %{buildroot}%{_prefix}/include/c++ \
-regex ".*/\(org\|gcj\|gnu\|java\|javax\|sun\)" -prune \
-o \( -type d -printf "%%%%dir " , \
-printf "%{_prefix}/include/c++/%%P\n" \) > ../c++-headers
# Remove files that we do not need to clean up filelist
rm -f %{buildroot}%{_prefix}/bin/%{GCCDIST}-*
rm -rf %{buildroot}%{libsubdir}/install-tools
rm -f %{buildroot}%{libsubdir}/include-fixed/zutil.h
rm -f %{buildroot}%{libsubdir}/include-fixed/linux/a.out.h
rm -f %{buildroot}%{libsubdir}/include-fixed/linux/vt.h
rm -f %{buildroot}%{libsubdir}/include-fixed/asm-generic/socket.h
rm -f %{buildroot}%{libsubdir}/include-fixed/bits/mathdef.h
rm -f %{buildroot}%{libsubdir}/include-fixed/bits/statx.h
rm -f %{buildroot}%{libsubdir}/include-fixed/sys/ucontext.h
# no plugins
rm -rf %{buildroot}%{libsubdir}/plugin
rm -f %{buildroot}%{_infodir}/dir
# gcj -static doesn't work properly anyway, unless using --whole-archive
# let's save the space instead.
find %{buildroot} -name libgcj.a \
-o -name libgcj-tools.a \
-o -name libgij.a \
-o -name libjvm.a \
-o -name libgcj_bc.a \
| xargs rm -f
find %{buildroot} -name libgcj.spec | xargs \
sed -i -e 's/lib: /&%%{static:%%eJava programs cannot be linked statically}/'
# security files have broken install locations, also they cause conflicts
# between libgcj versions. Simply delete them here, libgcj will use its
# defaults in this case (which is what these files contain anyway).
rm -f %{buildroot}%{libsubdir}/logging.properties
rm -r %{buildroot}%{libsubdir}/security
rm -f %{buildroot}%{_datadir}/gcc%{binsuffix}/python/libjava/aotcompile.py
rm -f %{buildroot}%{_datadir}/gcc%{binsuffix}/python/libjava/classfile.py
rm -f %{buildroot}%{_mandir}/man7/fsf-funding.7
rm -f %{buildroot}%{_mandir}/man7/gfdl.7
rm -f %{buildroot}%{_mandir}/man7/gpl.7
rm -f %{buildroot}%{_libdir}/libiberty.a
rm -f %{buildroot}%{libsubdir}/liblto_plugin.a
rm -f %{buildroot}%{libsubdir}/liblto_plugin.la
# For building libjava only we need to delete other info docs
rm %{buildroot}%{_infodir}/cp-tools.info*
# Remove stale manpages for binaries we do not build
rm %{buildroot}%{_mandir}/man1/gjdoc%{binsuffix}.1
# For building the java frontend we need to copy the ecj jar
install -dm 0755 %{buildroot}%{libsubdir}
install -pm 0644 %{SOURCE2} %{buildroot}%{libsubdir}/ecj.jar
# For regular build, some info files do not get renamed properly.
# Do so here.
mv %{buildroot}%{_infodir}/libgomp.info %{buildroot}%{_infodir}/libgomp%{binsuffix}.info
%ifarch %itm_arch
mv %{buildroot}%{_infodir}/libitm.info %{buildroot}%{_infodir}/libitm%{binsuffix}.info
%endif
cd ..
%find_lang cpplib%{binsuffix}
%find_lang gcc%{binsuffix}
%find_lang libstdc++
cat cpplib%{binsuffix}.lang gcc%{binsuffix}.lang > gcc6-locale.lang
%post info
%install_info --info-dir=%{_infodir} %{_infodir}/cpp%{binsuffix}.info.gz
%install_info --info-dir=%{_infodir} %{_infodir}/cppinternals%{binsuffix}.info.gz
%install_info --info-dir=%{_infodir} %{_infodir}/gcc%{binsuffix}.info.gz
%install_info --info-dir=%{_infodir} %{_infodir}/gccint%{binsuffix}.info.gz
%install_info --info-dir=%{_infodir} %{_infodir}/gccinstall%{binsuffix}.info.gz
%install_info --info-dir=%{_infodir} %{_infodir}/libgomp%{binsuffix}.info.gz
%ifarch %itm_arch
%install_info --info-dir=%{_infodir} %{_infodir}/libitm%{binsuffix}.info.gz
%endif
%install_info --info-dir=%{_infodir} %{_infodir}/gcj%{binsuffix}.info.gz
%preun info
%install_info_delete --info-dir=%{_infodir} %{_infodir}/cpp%{binsuffix}.info.gz
%install_info_delete --info-dir=%{_infodir} %{_infodir}/cppinternals%{binsuffix}.info.gz
%install_info_delete --info-dir=%{_infodir} %{_infodir}/gcc%{binsuffix}.info.gz
%install_info_delete --info-dir=%{_infodir} %{_infodir}/gccint%{binsuffix}.info.gz
%install_info_delete --info-dir=%{_infodir} %{_infodir}/gccinstall%{binsuffix}.info.gz
%install_info_delete --info-dir=%{_infodir} %{_infodir}/libgomp%{binsuffix}.info.gz
%ifarch %itm_arch
%install_info_delete --info-dir=%{_infodir} %{_infodir}/libitm%{binsuffix}.info.gz
%endif
%install_info_delete --info-dir=%{_infodir} %{_infodir}/gcj%{binsuffix}.info.gz
%files
%defattr(-,root,root)
%dir %{_libdir}/gcc
%dir %{_libdir}/gcc/%{GCCDIST}
%dir %{libsubdir}
%dir %{libsubdir}/include
%{_prefix}/bin/gcc%{binsuffix}
%{_prefix}/bin/gcov%{binsuffix}
%{_prefix}/bin/gcov-tool%{binsuffix}
%{_prefix}/bin/gcov-dump%{binsuffix}
%{_prefix}/bin/gcc-ar%{binsuffix}
%{_prefix}/bin/gcc-nm%{binsuffix}
%{_prefix}/bin/gcc-ranlib%{binsuffix}
%{libsubdir}/collect2
%{libsubdir}/lto1
%{libsubdir}/lto-wrapper
%{libsubdir}/liblto_plugin.so*
%{libsubdir}/include-fixed
%{libsubdir}/include/omp.h
%{libsubdir}/include/float.h
%{libsubdir}/include/iso646.h
%{libsubdir}/include/stdarg.h
%{libsubdir}/include/stdbool.h
%{libsubdir}/include/stdfix.h
%{libsubdir}/include/stddef.h
%{libsubdir}/include/unwind.h
%{libsubdir}/include/varargs.h
%{libsubdir}/include/stdint.h
%{libsubdir}/include/stdint-gcc.h
%{libsubdir}/include/stdnoreturn.h
%{libsubdir}/include/stdalign.h
%{libsubdir}/include/stdatomic.h
%{libsubdir}/include/openacc.h
%ifarch %sparc
%{libsubdir}/include/visintrin.h
%endif
%ifarch ppc ppc64 ppc64le
%{libsubdir}/include/altivec.h
%{libsubdir}/include/ppc-asm.h
%{libsubdir}/include/paired.h
%{libsubdir}/include/ppu_intrinsics.h
%{libsubdir}/include/si2vmx.h
%{libsubdir}/include/spe.h
%{libsubdir}/include/spu2vmx.h
%{libsubdir}/include/vec_types.h
%{libsubdir}/include/htmintrin.h
%{libsubdir}/include/htmxlintrin.h
%endif
%ifarch s390 s390x
%{libsubdir}/include/htmintrin.h
%{libsubdir}/include/htmxlintrin.h
%{libsubdir}/include/s390intrin.h
%{libsubdir}/include/vecintrin.h
%endif
%ifarch ia64
%{libsubdir}/include/ia64intrin.h
%endif
%ifarch %arm
%{libsubdir}/include/mmintrin.h
%{libsubdir}/include/unwind-arm-common.h
%endif
%ifarch %arm aarch64
%{libsubdir}/include/arm_neon.h
%{libsubdir}/include/arm_acle.h
%endif
%ifarch %ix86 x86_64
%{libsubdir}/include/cross-stdarg.h
%{libsubdir}/include/cpuid.h
%{libsubdir}/include/mm3dnow.h
%{libsubdir}/include/mmintrin.h
%{libsubdir}/include/ammintrin.h
%{libsubdir}/include/bmmintrin.h
%{libsubdir}/include/emmintrin.h
%{libsubdir}/include/immintrin.h
%{libsubdir}/include/avxintrin.h
%{libsubdir}/include/pmmintrin.h
%{libsubdir}/include/xmmintrin.h
%{libsubdir}/include/tmmintrin.h
%{libsubdir}/include/nmmintrin.h
%{libsubdir}/include/smmintrin.h
%{libsubdir}/include/wmmintrin.h
%{libsubdir}/include/x86intrin.h
%{libsubdir}/include/ia32intrin.h
%{libsubdir}/include/mm_malloc.h
%{libsubdir}/include/fma4intrin.h
%{libsubdir}/include/xopintrin.h
%{libsubdir}/include/lwpintrin.h
%{libsubdir}/include/popcntintrin.h
%{libsubdir}/include/bmiintrin.h
%{libsubdir}/include/tbmintrin.h
%{libsubdir}/include/avx2intrin.h
%{libsubdir}/include/bmi2intrin.h
%{libsubdir}/include/fmaintrin.h
%{libsubdir}/include/lzcntintrin.h
%{libsubdir}/include/f16cintrin.h
%{libsubdir}/include/adxintrin.h
%{libsubdir}/include/fxsrintrin.h
%{libsubdir}/include/prfchwintrin.h
%{libsubdir}/include/rdseedintrin.h
%{libsubdir}/include/rtmintrin.h
%{libsubdir}/include/xsaveintrin.h
%{libsubdir}/include/xsaveoptintrin.h
%{libsubdir}/include/xtestintrin.h
%{libsubdir}/include/avx512cdintrin.h
%{libsubdir}/include/avx512erintrin.h
%{libsubdir}/include/avx512fintrin.h
%{libsubdir}/include/avx512pfintrin.h
%{libsubdir}/include/shaintrin.h
%{libsubdir}/include/avx512bwintrin.h
%{libsubdir}/include/avx512dqintrin.h
%{libsubdir}/include/avx512vlbwintrin.h
%{libsubdir}/include/avx512vldqintrin.h
%{libsubdir}/include/avx512vlintrin.h
%{libsubdir}/include/avx512ifmaintrin.h
%{libsubdir}/include/avx512ifmavlintrin.h
%{libsubdir}/include/avx512vbmiintrin.h
%{libsubdir}/include/avx512vbmivlintrin.h
%{libsubdir}/include/clwbintrin.h
%{libsubdir}/include/clflushoptintrin.h
%{libsubdir}/include/xsavecintrin.h
%{libsubdir}/include/xsavesintrin.h
%{libsubdir}/include/mwaitxintrin.h
%{libsubdir}/include/clzerointrin.h
%{libsubdir}/include/pkuintrin.h
%endif
%ifarch m68k
%{libsubdir}/include/math-68881.h
%endif
%ifarch %cilkrts_arch
%{libsubdir}/include/cilk
%endif
%ifarch %asan_arch
%{libsubdir}/include/sanitizer
%endif
%versmainlib *crt*.o
%versmainlib libgcc*.a
%versmainlib libgcov.a
%versmainlib libgcc_s*.so
%versmainlib libgomp.so
%versmainlib libgomp.a
%versmainlib libgomp.spec
%ifarch %itm_arch
%versmainlib libitm.so
%versmainlib libitm.a
%versmainlib libitm.spec
%endif
%ifarch %atomic_arch
%versmainlib libatomic.so
%versmainlib libatomic.a
%endif
%ifarch %asan_arch
%versmainlib libasan.so
%versmainlib libasan.a
%versmainlib libasan_preinit.o
%endif
%ifarch %tsan_arch
%versmainlib libtsan.so
%versmainlib libtsan.a
%endif
%ifarch %cilkrts_arch
%versmainlib libcilkrts.so
%versmainlib libcilkrts.a
%versmainlib libcilkrts.spec
%endif
%ifarch %lsan_arch
%versmainlib liblsan.so
%versmainlib liblsan.a
%endif
%ifarch %ubsan_arch
%versmainlib libubsan.so
%versmainlib libubsan.a
%endif
%ifarch %asan_arch %ubsan_arch %tsan_arch %lsan_arch
%versmainlib libsanitizer.spec
%endif
%ifarch %mpx_arch
%versmainlib libmpx.so
%versmainlib libmpx.a
%versmainlib libmpxwrappers.so
%versmainlib libmpxwrappers.a
%versmainlib libmpx.spec
%endif
%doc %{_mandir}/man1/gcc%{binsuffix}.1.gz
%doc %{_mandir}/man1/gcov%{binsuffix}.1.gz
%doc %{_mandir}/man1/gcov-dump%{binsuffix}.1.gz
%doc %{_mandir}/man1/gcov-tool%{binsuffix}.1.gz
%files locale -f gcc6-locale.lang
%files -n libstdc++%{libstdcxx_sover}%{libstdcxx_suffix}-locale -f libstdc++.lang
%files c++
%defattr(-,root,root)
%dir %{_libdir}/gcc
%dir %{_libdir}/gcc/%{GCCDIST}
%dir %{libsubdir}
%{_prefix}/bin/g++%{binsuffix}
%doc %{_mandir}/man1/g++%{binsuffix}.1.gz
%{libsubdir}/cc1plus
%files -n libstdc++%{libstdcxx_sover}%{libstdcxx_suffix}
%defattr(-,root,root)
%mainlib libstdc++.so.%{libstdcxx_sover}*
%files -n libstdc++%{libstdcxx_sover}-devel%{libdevel_suffix} -f c++-headers
%defattr(-,root,root)
%versmainlib libstdc++.a
%versmainlib libstdc++fs.a
%versmainlib libstdc++.so
%versmainlib libsupc++.a
%dir %{_datadir}/gdb
%dir %{_datadir}/gdb/auto-load
%dir %{_datadir}/gdb/auto-load%{_prefix}
%dir %{_datadir}/gdb/auto-load/%{mainlibdir}
%{_datadir}/gdb/auto-load/%{mainlibdir}/libstdc++.so.*-gdb.py
%{_datadir}/gcc%{binsuffix}
%files -n libgcc_s%{libgcc_s}%{libgcc_s_suffix}
%defattr(-,root,root)
/%{_lib}/libgcc_s.so.%{libgcc_s}
%files -n libgomp%{libgomp_sover}%{libgomp_suffix}
%defattr(-,root,root)
%mainlib libgomp.so.%{libgomp_sover}*
%ifarch %asan_arch
%files -n libasan%{libasan_sover}%{libasan_suffix}
%defattr(-,root,root)
%mainlib libasan.so.%{libasan_sover}*
%endif
%ifarch %lsan_arch
%files -n liblsan%{liblsan_sover}%{liblsan_suffix}
%defattr(-,root,root)
%mainlib liblsan.so.%{liblsan_sover}*
%endif
%ifarch %tsan_arch
%files -n libtsan%{libtsan_sover}%{libtsan_suffix}
%defattr(-,root,root)
%mainlib libtsan.so.%{libtsan_sover}*
%endif
%ifarch %atomic_arch
%files -n libatomic%{libatomic_sover}%{libatomic_suffix}
%defattr(-,root,root)
%mainlib libatomic.so.%{libatomic_sover}*
%endif
%ifarch %itm_arch
%files -n libitm%{libitm_sover}%{libitm_suffix}
%defattr(-,root,root)
%mainlib libitm.so.%{libitm_sover}*
%endif
%ifarch %cilkrts_arch
%files -n libcilkrts%{libcilkrts_sover}%{libcilkrts_suffix}
%defattr(-,root,root)
%mainlib libcilkrts.so.%{libcilkrts_sover}*
%endif
%ifarch %ubsan_arch
%files -n libubsan%{libubsan_sover}%{libubsan_suffix}
%defattr(-,root,root)
%mainlib libubsan.so.%{libubsan_sover}*
%endif
%ifarch %mpx_arch
%files -n libmpx%{libmpx_sover}%{libmpx_suffix}
%defattr(-,root,root)
%mainlib libmpx.so.%{libmpx_sover}*
%files -n libmpxwrappers%{libmpxwrappers_sover}%{libmpxwrappers_suffix}
%defattr(-,root,root)
%mainlib libmpxwrappers.so.%{libmpxwrappers_sover}*
%endif
%files info
%defattr(-,root,root)
%doc %{_infodir}/cpp%{binsuffix}.info*.gz
%doc %{_infodir}/cppinternals%{binsuffix}.info*.gz
%doc %{_infodir}/gcc%{binsuffix}.info*.gz
%doc %{_infodir}/gccint%{binsuffix}.info*.gz
%doc %{_infodir}/gccinstall%{binsuffix}.info*.gz
%doc %{_infodir}/libgomp%{binsuffix}.info*.gz
%ifarch %itm_arch
%doc %{_infodir}/libitm%{binsuffix}.info*.gz
%endif
%doc %{_infodir}/gcj%{binsuffix}.info*.gz
%files -n cpp6
%defattr(-,root,root)
%dir %{_libdir}/gcc
%dir %{_libdir}/gcc/%{GCCDIST}
%dir %{libsubdir}
%{_prefix}/bin/cpp%{binsuffix}
%{libsubdir}/cc1
%doc %{_mandir}/man1/cpp%{binsuffix}.1.gz
%files java
%defattr(-,root,root)
%{_prefix}/bin/gcj%{binsuffix}
%{_prefix}/bin/gcjh%{binsuffix}
%{_prefix}/bin/gcj-dbtool%{binsuffix}
%{_prefix}/bin/jcf-dump%{binsuffix}
%{_prefix}/bin/jv-convert%{binsuffix}
%{_prefix}/bin/gc-analyze%{binsuffix}
%{_prefix}/bin/aot-compile%{binsuffix}
%{_prefix}/bin/rebuild-gcj-db%{binsuffix}
%{libsubdir}/jc1
%{libsubdir}/jvgenmain
%{libsubdir}/ecj.jar
%{libsubdir}/ecj1
%doc %{_mandir}/man1/gcj%{binsuffix}.1.gz
%doc %{_mandir}/man1/gcjh%{binsuffix}.1.gz
%doc %{_mandir}/man1/gcj-dbtool%{binsuffix}.1.gz
%doc %{_mandir}/man1/jcf-dump%{binsuffix}.1.gz
%doc %{_mandir}/man1/jv-convert%{binsuffix}.1.gz
%doc %{_mandir}/man1/gc-analyze%{binsuffix}.1.gz
%doc %{_mandir}/man1/aot-compile%{binsuffix}.1.gz
%doc %{_mandir}/man1/rebuild-gcj-db%{binsuffix}.1.gz
%files -n libgcj%{libdevel_suffix}
%defattr(-,root,root)
%dir %{libsubdir}/gcj-%{gcc_dir_version}-%{libgcj_sover}
%dir %{_libdir}/gcc
%dir %{_libdir}/gcc/%{GCCDIST}
%dir %{libsubdir}
%{libsubdir}/gcj-%{gcc_dir_version}-%{libgcj_sover}/classmap.db
%versmainlib libgcj.la
%mainlib libgcj.so.*
%mainlib libgij.so.*
%mainlib libgcj-tools.so.*
%{libsubdir}/gcj-%{gcc_dir_version}-%{libgcj_sover}/libjvm.la
%{libsubdir}/gcj-%{gcc_dir_version}-%{libgcj_sover}/libjvm.so
%{libsubdir}/gcj-%{gcc_dir_version}-%{libgcj_sover}/libjavamath.la
%{libsubdir}/gcj-%{gcc_dir_version}-%{libgcj_sover}/libjavamath.so
%files -n libgcj_bc%{libgcj_bc_sover}%{libgcj_bc_suffix}
%defattr(-,root,root)
%mainlib libgcj_bc.so.%{libgcj_bc_sover}*
%files -n libgcj-jar%{libdevel_suffix}
%defattr(-,root,root)
%dir %{_prefix}/share/java
%{_prefix}/share/java/libgcj-%{gcc_dir_version}.jar
%{_prefix}/share/java/libgcj-tools-%{gcc_dir_version}.jar
%files -n libgcj-devel%{libdevel_suffix}
%defattr(-,root,root)
%dir %{_prefix}/include/c++
%dir %{libsubdir}
%dir %{libsubdir}/include
%dir %{gxxinclude}
%{_libdir}/pkgconfig/libgcj%{binsuffix}.pc
%{libsubdir}/include/jawt.h
%{libsubdir}/include/jawt_md.h
%{libsubdir}/include/jni.h
%{libsubdir}/include/jni_md.h
%{libsubdir}/include/jvmpi.h
%{gxxinclude}/gnu
%{gxxinclude}/gcj
%{gxxinclude}/java
%{gxxinclude}/javax
%{gxxinclude}/org
%{gxxinclude}/sun
%{libsubdir}/include/gcj
%versmainlib libgcj.so
%versmainlib libgcj.spec
%versmainlib libgcj-tools.so
%versmainlib libgij.so
%versmainlib libgcj_bc.so
%files gij
%defattr(-,root,root)
%{_prefix}/bin/gij%{binsuffix}
%{_prefix}/bin/gappletviewer%{binsuffix}
%{_prefix}/bin/gjar%{binsuffix}
%{_prefix}/bin/gjarsigner%{binsuffix}
%{_prefix}/bin/gjavah%{binsuffix}
%{_prefix}/bin/gkeytool%{binsuffix}
%{_prefix}/bin/gnative2ascii%{binsuffix}
%{_prefix}/bin/gorbd%{binsuffix}
%{_prefix}/bin/grmic%{binsuffix}
%{_prefix}/bin/grmid%{binsuffix}
%{_prefix}/bin/grmiregistry%{binsuffix}
%{_prefix}/bin/gserialver%{binsuffix}
%{_prefix}/bin/gtnameserv%{binsuffix}
%doc %{_mandir}/man1/gij%{binsuffix}.1.gz
%doc %{_mandir}/man1/gappletviewer%{binsuffix}.1.gz
%doc %{_mandir}/man1/grmic%{binsuffix}.1.gz
%doc %{_mandir}/man1/grmid%{binsuffix}.1.gz
%doc %{_mandir}/man1/grmiregistry%{binsuffix}.1.gz
%doc %{_mandir}/man1/gkeytool%{binsuffix}.1.gz
%doc %{_mandir}/man1/gjar%{binsuffix}.1.gz
%doc %{_mandir}/man1/gjarsigner%{binsuffix}.1.gz
%doc %{_mandir}/man1/gjavah%{binsuffix}.1.gz
%doc %{_mandir}/man1/gnative2ascii%{binsuffix}.1.gz
%doc %{_mandir}/man1/gorbd%{binsuffix}.1.gz
%doc %{_mandir}/man1/gserialver%{binsuffix}.1.gz
%doc %{_mandir}/man1/gtnameserv%{binsuffix}.1.gz
%changelog