import gcc-toolset-10-gcc-10.2.1-8.2.el8

This commit is contained in:
CentOS Sources 2021-10-06 04:30:18 -04:00 committed by Stepan Oksanichenko
parent a6346e2920
commit 28a33e0cff
1 changed files with 94 additions and 16 deletions

View File

@ -123,7 +123,7 @@
Summary: GCC version 10
Name: %{?scl_prefix}gcc
Version: %{gcc_version}
Release: %{gcc_release}.1%{?dist}
Release: %{gcc_release}.2%{?dist}
# libgcc, libgfortran, libgomp, libstdc++ and crtstuff have
# GCC Runtime Exception.
License: GPLv3+ and GPLv3+ with exceptions and GPLv2+ with exceptions and LGPLv2+ and BSD
@ -172,13 +172,8 @@ BuildRequires: glibc-static
%if 0%{?scl:1}
BuildRequires: %{?scl_prefix}binutils >= 2.31
# For testing
%if 0%{?rhel} >= 6
# FIXME gcc-toolset-10-gdb isn't yet in the buildroot.
BuildRequires: gdb
%else
BuildRequires: %{?scl_prefix}gdb >= 7.4.50
%endif
%endif
BuildRequires: zlib-devel, gettext, dejagnu, bison, flex, sharutils
BuildRequires: texinfo, texinfo-tex, /usr/bin/pod2man
#BuildRequires: systemtap-sdt-devel >= 1.3
@ -235,9 +230,9 @@ Requires: glibc-devel >= 2.2.90-12
# Make sure glibc supports TFmode long double
Requires: glibc >= 2.3.90-35
%endif
BuildRequires: gmp-devel >= 4.1.2-8
BuildRequires: mpfr-devel >= 3.1.0
%if 0%{?rhel} >= 7
BuildRequires: gmp-devel >= 4.3.2
BuildRequires: mpfr-devel >= 3.1.0
BuildRequires: libmpc-devel >= 0.8.1
%endif
%if %{build_libstdcxx_docs}
@ -522,9 +517,9 @@ GNU Transactional Memory library.
%package plugin-devel
Summary: Support for compiling GCC plugins
Requires: %{?scl_prefix}gcc%{!?scl:10} = %{version}-%{release}
Requires: gmp-devel >= 4.1.2-8
Requires: mpfr-devel >= 3.1.0
%if 0%{?rhel} >= 7
Requires: gmp-devel >= 4.3.2
Requires: mpfr-devel >= 3.1.0
Requires: libmpc-devel >= 0.8.1
%endif
@ -563,8 +558,12 @@ which is used for -fsanitize=address instrumented programs.
%package -n %{?scl_prefix}libasan-devel
Summary: The Address Sanitizer static library
%if 0%{?rhel} > 8
Requires: libasan%{_isa} >= 8.3.1
Obsoletes: libasan5
%else
Requires: libasan6%{_isa} >= 10.2.1
%endif
Obsoletes: libasan5 <= 8.3.1
%description -n %{?scl_prefix}libasan-devel
This package contains Address Sanitizer static runtime library.
@ -598,7 +597,7 @@ which is used for -fsanitize=undefined instrumented programs.
Summary: The Undefined Behavior Sanitizer static library
%if 0%{?rhel} > 7
Requires: libubsan%{_isa} >= 8.3.1
Obsoletes: libubsan1
Obsoletes: libubsan1 <= 8.3.1
%else
Requires: libubsan1%{_isa} >= 8.3.1
%endif
@ -1293,6 +1292,23 @@ GROUP ( /lib/libgcc_s.so.1 libgcc.a )' > $FULLPATH/32/libgcc_s.so
mv -f %{buildroot}%{_prefix}/%{_lib}/libgomp.spec $FULLPATH/
cp -a %{gcc_target_platform}/libstdc++-v3/src/.libs/libstdc++_nonshared%{nonsharedver}.a \
$FULLLPATH/libstdc++_nonshared.a
cp -a %{gcc_target_platform}/libgfortran/.libs/libgfortran_nonshared80.a \
$FULLLPATH/libgfortran_nonshared.a
%if 0%{?rhel} <= 7
# Build libgomp_nonshared.a with the system RHEL 7 compiler. Use -O2 to
# get tailcalls.
gcc %{SOURCE4} -O2 -c
ar rcs libgomp_nonshared.a libgomp_nonshared.o
cp -a libgomp_nonshared.a $FULLLPATH
%ifarch x86_64
# Only need this for -m32 on x86_64. devtoolset-N-gcc isn't multilib,
# and we don't have a devtoolset-N-libgomp-devel subpackage.
gcc %{SOURCE4} -O2 -c -m32 -o libgomp_nonshared32.o
ar rcs libgomp_nonshared32.a libgomp_nonshared32.o
cp -a libgomp_nonshared32.a $FULLLPATH/32/libgomp_nonshared.a
%endif
%endif
rm -f $FULLEPATH/libgccjit.so
mkdir -p %{buildroot}%{_prefix}/%{_lib}/
@ -1307,9 +1323,18 @@ gzip -9 %{buildroot}/%{_infodir}/libgccjit.info
pushd $FULLPATH
%if 0%{?rhel} <= 7
echo '/* GNU ld script
Use the shared library, but some functions are only in
the static library, so try that secondarily. */
%{oformat}
INPUT ( %{?scl:%{_root_prefix}}%{!?scl:%{_prefix}}/%{_lib}/libgomp.so.1 -lgomp_nonshared )' > libgomp.so
%else
echo '/* GNU ld script */
%{oformat}
INPUT ( %{?scl:%{_root_prefix}}%{!?scl:%{_prefix}}/%{_lib}/libgomp.so.1 )' > libgomp.so
%endif
%if 0%{?rhel} <= 8
echo '/* GNU ld script
Use the shared library, but some functions are only in
@ -1325,7 +1350,7 @@ echo '/* GNU ld script
Use the shared library, but some functions are only in
the static library, so try that secondarily. */
%{oformat}
INPUT ( %{?scl:%{_root_prefix}}%{!?scl:%{_prefix}}/%{_lib}/libgfortran.so.5 )' > libgfortran.so
INPUT ( %{?scl:%{_root_prefix}}%{!?scl:%{_prefix}}/%{_lib}/libgfortran.so.5 -lgfortran_nonshared )' > libgfortran.so
%if %{build_libquadmath}
rm -f libquadmath.so
echo '/* GNU ld script */
@ -1425,7 +1450,7 @@ echo '/* GNU ld script
Use the shared library, but some functions are only in
the static library, so try that secondarily. */
%{oformat2}
INPUT ( %{?scl:%{_root_prefix}}%{!?scl:%{_prefix}}/lib64/libgfortran.so.5 )' > 64/libgfortran.so
INPUT ( %{?scl:%{_root_prefix}}%{!?scl:%{_prefix}}/lib64/libgfortran.so.5 -lgfortran_nonshared )' > 64/libgfortran.so
echo '/* GNU ld script */
%{oformat2}
INPUT ( %{?scl:%{_root_prefix}}%{!?scl:%{_prefix}}/lib64/libgomp.so.1 )' > 64/libgomp.so
@ -1525,10 +1550,20 @@ echo '/* GNU ld script
Use the shared library, but some functions are only in
the static library, so try that secondarily. */
%{oformat2}
INPUT ( %{?scl:%{_root_prefix}}%{!?scl:%{_prefix}}/lib/libgfortran.so.5 )' > 32/libgfortran.so
INPUT ( %{?scl:%{_root_prefix}}%{!?scl:%{_prefix}}/lib/libgfortran.so.5 -lgfortran_nonshared )' > 32/libgfortran.so
%if 0%{?rhel} <= 7
echo '/* GNU ld script
Use the shared library, but some functions are only in
the static library, so try that secondarily. */
%{oformat2}
INPUT ( %{?scl:%{_root_prefix}}%{!?scl:%{_prefix}}/lib/libgomp.so.1 -lgomp_nonshared )' > 32/libgomp.so
%else
echo '/* GNU ld script */
%{oformat2}
INPUT ( %{?scl:%{_root_prefix}}%{!?scl:%{_prefix}}/lib/libgomp.so.1 )' > 32/libgomp.so
%endif
echo '/* GNU ld script */
%{oformat2}
INPUT ( %{_prefix}/lib/libgccjit.so.0 )' > 32/libgccjit.so
@ -1586,6 +1621,11 @@ ln -sf lib64/libstdc++fs.a libstdc++fs.a
ln -sf ../lib32/libstdc++_nonshared.a 32/libstdc++_nonshared.a
ln -sf lib64/libstdc++_nonshared.a libstdc++_nonshared.a
%endif
%if 0%{?rhel} <= 8
ln -sf ../lib32/libgfortran_nonshared.a 32/libgfortran_nonshared.a
ln -sf lib64/libgfortran_nonshared.a libgfortran_nonshared.a
ln -sf lib64/libgomp_nonshared.a libgomp_nonshared.a
%endif
%if %{build_libquadmath}
ln -sf ../lib32/libquadmath.a 32/libquadmath.a
ln -sf lib64/libquadmath.a libquadmath.a
@ -1615,6 +1655,9 @@ ln -sf ../../../%{multilib_32_arch}-%{_vendor}-%{_target_os}%{?_gnu}/%{gcc_major
%if 0%{?rhel} <= 8
ln -sf ../../../%{multilib_32_arch}-%{_vendor}-%{_target_os}%{?_gnu}/%{gcc_major}/libstdc++_nonshared.a 32/libstdc++_nonshared.a
%endif
%if 0%{?rhel} <= 8
ln -sf ../../../%{multilib_32_arch}-%{_vendor}-%{_target_os}%{?_gnu}/%{gcc_major}/libgfortran_nonshared.a 32/libgfortran_nonshared.a
%endif
%if %{build_libquadmath}
ln -sf ../../../%{multilib_32_arch}-%{_vendor}-%{_target_os}%{?_gnu}/%{gcc_major}/libquadmath.a 32/libquadmath.a
%endif
@ -1651,6 +1694,8 @@ for f in `find $adirs -maxdepth 1 -a \
-o -name liblsan.a \
-o -name libcc1.a \
-o -name libstdc++_nonshared.a \
-o -name libgomp_nonshared.a \
-o -name libgfortran_nonshared.a \
-o -name libsupc++.a \
-o -name libstdc++.a -o -name libcaf_single.a \
-o -name libstdc++fs.a \) -a -type f`; do
@ -1799,7 +1844,6 @@ chmod 755 %{buildroot}%{_prefix}/bin/%{multilib_32_arch}-%{_vendor}-%{_target_os
%endif
# Help plugins find out nvra.
# ??? Fedora uses _arch
echo gcc-%{version}-%{release}.%{arch} > $FULLPATH/rpmver
# Add symlink to lto plugin in the binutils plugin directory.
@ -2171,6 +2215,11 @@ fi
%{_prefix}/lib/gcc/%{gcc_target_platform}/%{gcc_major}/libgomp.spec
%{_prefix}/lib/gcc/%{gcc_target_platform}/%{gcc_major}/libgomp.a
%{_prefix}/lib/gcc/%{gcc_target_platform}/%{gcc_major}/libgomp.so
%if 0%{?rhel} <= 7
%ifnarch ppc
%{_prefix}/lib/gcc/%{gcc_target_platform}/%{gcc_major}/libgomp_nonshared.a
%endif
%endif
%if %{build_libitm}
%{_prefix}/lib/gcc/%{gcc_target_platform}/%{gcc_major}/libitm.spec
%endif
@ -2227,6 +2276,20 @@ fi
%{_prefix}/lib/gcc/%{gcc_target_platform}/%{gcc_major}/32/libgcc_s.so
%{_prefix}/lib/gcc/%{gcc_target_platform}/%{gcc_major}/32/libgomp.a
%{_prefix}/lib/gcc/%{gcc_target_platform}/%{gcc_major}/32/libgomp.so
# Add libgomp_nonshared.a
%if 0%{?rhel} <= 7
%ifarch x86_64
# Need it for -m32.
%{_prefix}/lib/gcc/%{gcc_target_platform}/%{gcc_major}/32/libgomp_nonshared.a
%endif
%ifarch ppc64
# We've created a symlink to lib64/libgomp_nonshared.a, so add it.
%dir %{_prefix}/lib/gcc/%{gcc_target_platform}/%{gcc_major}/lib64
%{_prefix}/lib/gcc/%{gcc_target_platform}/%{gcc_major}/lib64/libgomp_nonshared.a
%endif
%endif
%{_prefix}/lib/gcc/%{gcc_target_platform}/%{gcc_major}/32/libgccjit.so
%if %{build_libquadmath}
%{_prefix}/lib/gcc/%{gcc_target_platform}/%{gcc_major}/32/libquadmath.a
@ -2392,6 +2455,7 @@ fi
%{_prefix}/lib/gcc/%{gcc_target_platform}/%{gcc_major}/libcaf_single.a
%{_prefix}/lib/gcc/%{gcc_target_platform}/%{gcc_major}/libgfortran.a
%{_prefix}/lib/gcc/%{gcc_target_platform}/%{gcc_major}/libgfortran.so
%{_prefix}/lib/gcc/%{gcc_target_platform}/%{gcc_major}/libgfortran_nonshared.a
%ifarch sparcv9 ppc
%dir %{_prefix}/lib/gcc/%{gcc_target_platform}/%{gcc_major}/64
%{_prefix}/lib/gcc/%{gcc_target_platform}/%{gcc_major}/64/libcaf_single.a
@ -2404,8 +2468,13 @@ fi
%{_prefix}/lib/gcc/%{gcc_target_platform}/%{gcc_major}/32/libcaf_single.a
%{_prefix}/lib/gcc/%{gcc_target_platform}/%{gcc_major}/32/libgfortran.a
%{_prefix}/lib/gcc/%{gcc_target_platform}/%{gcc_major}/32/libgfortran.so
%{_prefix}/lib/gcc/%{gcc_target_platform}/%{gcc_major}/32/libgfortran_nonshared.a
%{_prefix}/lib/gcc/%{gcc_target_platform}/%{gcc_major}/32/finclude
%endif
%ifarch ppc64
%dir %{_prefix}/lib/gcc/%{gcc_target_platform}/%{gcc_major}/lib64
%{_prefix}/lib/gcc/%{gcc_target_platform}/%{gcc_major}/lib64/libgfortran_nonshared.a
%endif
%doc rpm.doc/gfortran/*
%if %{build_libquadmath}
@ -2428,6 +2497,11 @@ fi
%{_prefix}/lib/gcc/%{gcc_target_platform}/%{gcc_major}/libquadmath.a
%{_prefix}/lib/gcc/%{gcc_target_platform}/%{gcc_major}/libquadmath.so
%endif
%dir %{_prefix}/lib/gcc/%{gcc_target_platform}/%{gcc_major}
%ifarch %{ix86}
# Need it for -m32.
%{_prefix}/lib/gcc/%{gcc_target_platform}/%{gcc_major}/libgfortran_nonshared.a
%endif
%doc rpm.doc/libquadmath/ChangeLog*
%endif
@ -2607,6 +2681,10 @@ fi
%endif
%changelog
* Tue Mar 16 2021 Marek Polacek <polacek@redhat.com> 10.2.1-8.2
- actually use libgfortran_nonshared.a (#1929375)
- have libasan-devel require libasan6 (#1939638)
* Mon Nov 16 2020 Marek Polacek <polacek@redhat.com> 10.2.1-8.1
- apply fix for -flto=auto with missing make (#1896093, PR lto/97524)