7
0
forked from pool/gcc13

3 Commits

Author SHA256 Message Date
7b0a1683b7 Sync changes to SLFO-1.2 branch 2025-08-20 09:16:32 +02:00
b0f0d01f4f Accepting request 1290114 from devel:gcc
- Tune for power10 for SLES 16.  [jsc#PED-12029]
- Tune for z15 for SLES 16.  [jsc#PED-253]

OBS-URL: https://build.opensuse.org/request/show/1290114
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/gcc13?expand=0&rev=37
2025-07-06 15:06:11 +00:00
004424c6c3 - Tune for power10 for SLES 16. [jsc#PED-12029]
- Tune for z15 for SLES 16.  [jsc#PED-253]

OBS-URL: https://build.opensuse.org/package/show/devel:gcc/gcc13?expand=0&rev=144
2025-07-03 07:26:32 +00:00
36 changed files with 731 additions and 4730 deletions

View File

@@ -14,11 +14,7 @@
<flavor>cross-pru-gcc13-bootstrap</flavor> <flavor>cross-pru-gcc13-bootstrap</flavor>
<flavor>cross-pru-gcc13</flavor> <flavor>cross-pru-gcc13</flavor>
<flavor>cross-x86_64-gcc13</flavor> <flavor>cross-x86_64-gcc13</flavor>
<flavor>cross-sparc-gcc13</flavor>
<flavor>cross-sparc64-gcc13</flavor>
<flavor>cross-ppc64-gcc13</flavor> <flavor>cross-ppc64-gcc13</flavor>
<flavor>cross-m68k-gcc13</flavor>
<flavor>cross-mips-gcc13</flavor>
<flavor>cross-hppa-gcc13-bootstrap</flavor> <flavor>cross-hppa-gcc13-bootstrap</flavor>
<flavor>cross-arm-none-gcc13-bootstrap</flavor> <flavor>cross-arm-none-gcc13-bootstrap</flavor>
<flavor>cross-arm-none-gcc13</flavor> <flavor>cross-arm-none-gcc13</flavor>

View File

@@ -87,10 +87,16 @@ add_newlib_cross() {
} }
add_glibc_cross() { add_glibc_cross() {
add_cross $1-bootstrap $2 $3 "%define gcc_libc_bootstrap 1" add_cross $1-bootstrap $2 $3 "%define gcc_target_glibc 1
%define gcc_libc_bootstrap 1"
add_cross $1 $2 $3 "%define gcc_target_glibc 1" add_cross $1 $2 $3 "%define gcc_target_glibc 1"
} }
add_glibc_bootstrap_cross() {
add_cross $1 $2 $3 "%define gcc_target_glibc 1
%define gcc_libc_bootstrap 1"
}
# We now support "proper" cross-compilers to suse targets via a # We now support "proper" cross-compilers to suse targets via a
# cross-glibc package, enable that via for example # cross-glibc package, enable that via for example
# #
@@ -102,16 +108,16 @@ add_glibc_cross cross-aarch64-gcc$base_ver aarch64 aarch64-suse-linux
add_glibc_cross cross-riscv64-gcc$base_ver riscv64 riscv64-suse-linux add_glibc_cross cross-riscv64-gcc$base_ver riscv64 riscv64-suse-linux
add_glibc_cross cross-s390x-gcc$base_ver s390x s390x-suse-linux add_glibc_cross cross-s390x-gcc$base_ver s390x s390x-suse-linux
add_glibc_cross cross-ppc64le-gcc$base_ver ppc64le powerpc64le-suse-linux add_glibc_cross cross-ppc64le-gcc$base_ver ppc64le powerpc64le-suse-linux
add_cross cross-arm-gcc$base_ver arm arm-suse-linux-gnueabi %define gcc_icecream 1 add_glibc_bootstrap_cross cross-arm-gcc$base_ver arm arm-suse-linux-gnueabi
add_cross cross-avr-gcc$base_ver-bootstrap avr avr "%define gcc_libc_bootstrap 1" add_cross cross-avr-gcc$base_ver-bootstrap avr avr "%define gcc_libc_bootstrap 1"
add_cross cross-avr-gcc$base_ver avr avr add_cross cross-avr-gcc$base_ver avr avr
add_newlib_cross cross-pru-gcc$base_ver pru pru add_newlib_cross cross-pru-gcc$base_ver pru pru
add_cross cross-x86_64-gcc$base_ver x86_64 x86_64-suse-linux %define gcc_icecream 1 add_glibc_bootstrap_cross cross-x86_64-gcc$base_ver x86_64 x86_64-suse-linux
add_cross cross-sparc-gcc$base_ver sparcv9 sparc-suse-linux %define gcc_icecream 1 #add_cross cross-sparc-gcc$base_ver sparcv9 sparc-suse-linux %define gcc_icecream 1
add_cross cross-sparc64-gcc$base_ver sparc64 sparc64-suse-linux %define gcc_icecream 1 #add_cross cross-sparc64-gcc$base_ver sparc64 sparc64-suse-linux %define gcc_icecream 1
add_cross cross-ppc64-gcc$base_ver ppc64 powerpc64-suse-linux %define gcc_icecream 1 add_glibc_bootstrap_cross cross-ppc64-gcc$base_ver ppc64 powerpc64-suse-linux
add_cross cross-m68k-gcc$base_ver m68k m68k-suse-linux %define gcc_icecream 1 #add_cross cross-m68k-gcc$base_ver m68k m68k-suse-linux %define gcc_icecream 1
add_cross cross-mips-gcc$base_ver mips mips-suse-linux %define gcc_icecream 1 #add_cross cross-mips-gcc$base_ver mips mips-suse-linux %define gcc_icecream 1
add_cross cross-hppa-gcc$base_ver-bootstrap hppa hppa-suse-linux %define gcc_libc_bootstrap 1 add_cross cross-hppa-gcc$base_ver-bootstrap hppa hppa-suse-linux %define gcc_libc_bootstrap 1
add_newlib_cross cross-arm-none-gcc$base_ver arm-none arm-none-eabi add_newlib_cross cross-arm-none-gcc$base_ver arm-none arm-none-eabi
#add_newlib_cross cross-epiphany-gcc$base_ver epiphany epiphany-elf #add_newlib_cross cross-epiphany-gcc$base_ver epiphany epiphany-elf

View File

@@ -19,6 +19,7 @@
%define pkgname cross-aarch64-gcc13-bootstrap %define pkgname cross-aarch64-gcc13-bootstrap
%define cross_arch aarch64 %define cross_arch aarch64
%define gcc_target_arch aarch64-suse-linux %define gcc_target_arch aarch64-suse-linux
%define gcc_target_glibc 1
%define gcc_libc_bootstrap 1 %define gcc_libc_bootstrap 1
# nospeccleaner # nospeccleaner
@@ -292,26 +293,24 @@ ExclusiveArch: i586 ppc64le ppc64 x86_64 s390x riscv64
%if "%pkgname" == "cross-ppc64-gcc49" %if "%pkgname" == "cross-ppc64-gcc49"
Obsoletes: cross-ppc-gcc49 <= 4.9.0+r209354 Obsoletes: cross-ppc-gcc49 <= 4.9.0+r209354
%endif %endif
%if 0%{?gcc_target_newlib:1}%{?gcc_target_glibc:1} || "%{cross_arch}" == "avr" %if 0%{!?gcc_accel:1}
# Generally only one cross for the same target triplet can be installed # Generally only one cross for the same target triplet can be installed
# at the same time as we are populating a non-version-specific sysroot # at the same time as we are populating a non-version-specific sysroot
Provides: %{gcc_target_arch}-gcc
Conflicts: %selfconflict %{gcc_target_arch}-gcc
%endif
%if 0%{?gcc_libc_bootstrap:1}
# The -bootstrap packages file-conflict with the non-bootstrap variants. # The -bootstrap packages file-conflict with the non-bootstrap variants.
# Even if we don't actually (want to) distribute the bootstrap variants # Even if we don't actually (want to) distribute the bootstrap variants
# the following avoids repo-checker spamming us endlessly. # the following avoids repo-checker spamming us endlessly.
Provides: %{gcc_target_arch}-gcc
Conflicts: %{gcc_target_arch}-gcc Conflicts: %{gcc_target_arch}-gcc
Conflicts: %{pkgname}-bootstrap
%endif %endif
#!BuildIgnore: gcc-PIE #!BuildIgnore: gcc-PIE
%if 0%{build_cp:1} %if %{build_cp}
# The cross compiler only packages the arch specific c++ headers, so # The cross compiler only packages the arch specific c++ headers, so
# we need to depend on the host libstdc++ devel headers (we wouldn't need # we need to depend on the host libstdc++ devel headers (we wouldn't need
# the libs, though) # the libs, though)
Requires: libstdc++6-devel-gcc13 Requires: libstdc++6-devel-gcc13
%endif %endif
%if 0%{!?gcc_accel:1} %if 0%{!?gcc_accel:1} && %{suse_version} < 1600
BuildRequires: update-alternatives BuildRequires: update-alternatives
Requires(post): update-alternatives Requires(post): update-alternatives
Requires(preun): update-alternatives Requires(preun): update-alternatives
@@ -587,11 +586,11 @@ amdgcn-amdhsa,\
--enable-gnu-indirect-function \ --enable-gnu-indirect-function \
%endif %endif
%endif %endif
--program-suffix=%{binsuffix} \
%ifarch %{disable_multilib_arch} %ifarch %{disable_multilib_arch}
--disable-multilib \ --disable-multilib \
%endif %endif
%if 0%{!?gcc_target_arch:1} %if 0%{!?gcc_target_arch:1}
--program-suffix=%{binsuffix} \
%ifarch ia64 %ifarch ia64
--with-system-libunwind \ --with-system-libunwind \
%else %else
@@ -599,6 +598,9 @@ amdgcn-amdhsa,\
%endif %endif
%endif %endif
%if 0%{?gcc_target_arch:1} %if 0%{?gcc_target_arch:1}
%if 0%{?gcc_accel:1} || %{suse_version} < 1600
--program-suffix=%{binsuffix} \
%endif
--program-prefix=%{gcc_target_arch}- \ --program-prefix=%{gcc_target_arch}- \
--target=%{gcc_target_arch} \ --target=%{gcc_target_arch} \
--disable-nls \ --disable-nls \
@@ -686,7 +688,7 @@ amdgcn-amdhsa,\
%endif %endif
%if %{suse_version} >= 1600 && !0%{?is_opensuse} %if %{suse_version} >= 1600 && !0%{?is_opensuse}
--with-cpu=power9 \ --with-cpu=power9 \
--with-tune=power9 \ --with-tune=power10 \
%else %else
%if %{suse_version} >= 1350 %if %{suse_version} >= 1350
--with-cpu=power8 \ --with-cpu=power8 \
@@ -755,7 +757,7 @@ amdgcn-amdhsa,\
%endif %endif
%if "%{TARGET_ARCH}" == "s390" || "%{TARGET_ARCH}" == "s390x" %if "%{TARGET_ARCH}" == "s390" || "%{TARGET_ARCH}" == "s390x"
%if %{suse_version} >= 1600 && !0%{?is_opensuse} %if %{suse_version} >= 1600 && !0%{?is_opensuse}
--with-tune=z14 --with-arch=z14 \ --with-tune=z15 --with-arch=z14 \
%else %else
%if %{suse_version} >= 1310 %if %{suse_version} >= 1310
--with-tune=zEC12 --with-arch=z196 \ --with-tune=zEC12 --with-arch=z196 \
@@ -861,7 +863,7 @@ rm -f $RPM_BUILD_ROOT%{_libdir}/libiberty.a
mkdir -p $RPM_BUILD_ROOT/%{?sysroot:%sysroot} mkdir -p $RPM_BUILD_ROOT/%{?sysroot:%sysroot}
make DESTDIR=$RPM_BUILD_ROOT install-target make DESTDIR=$RPM_BUILD_ROOT install-target
%if %{build_cp} %if %{build_cp}
# So we installed libstdc++ headers into %prefix where they conflict # So we installed libstdc++ headers into %%prefix where they conflict
# with other host compilers. Rip out the non-target specific parts # with other host compilers. Rip out the non-target specific parts
# again. Note not all cross targets support libstdc++, so create the # again. Note not all cross targets support libstdc++, so create the
# directory to make things easier. # directory to make things easier.
@@ -886,6 +888,7 @@ rm -rf $RPM_BUILD_ROOT%{_infodir}
# for accelerators remove all frontends but lto1 and also install-tools # for accelerators remove all frontends but lto1 and also install-tools
%if 0%{?gcc_accel:1} %if 0%{?gcc_accel:1}
rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1 rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1
rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/f951
rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1plus rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1plus
rm -rf $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/install-tools rm -rf $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/install-tools
rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}/install-tools rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}/install-tools
@@ -893,6 +896,8 @@ rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}/install-tools
# that is the place where we later search for (only) # that is the place where we later search for (only)
( cd $RPM_BUILD_ROOT%{targetlibsubdir} && tar cf - . ) | ( cd $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch} && tar xf - ) ( cd $RPM_BUILD_ROOT%{targetlibsubdir} && tar cf - . ) | ( cd $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch} && tar xf - )
rm -rf $RPM_BUILD_ROOT%{targetlibsubdir} rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}
# also remove installed libstdc++ headers
rm -rf $RPM_BUILD_ROOT%{_prefix}/include/c++
%endif %endif
# for amdgcn install the symlinks to the llvm tools # for amdgcn install the symlinks to the llvm tools
# follow alternatives symlinks to the hardcoded version requirement # follow alternatives symlinks to the hardcoded version requirement
@@ -957,7 +962,7 @@ rm -r env
# we provide update-alternatives for selecting a compiler version for # we provide update-alternatives for selecting a compiler version for
# crosses # crosses
%if 0%{!?gcc_accel:1} %if 0%{!?gcc_accel:1} && %{suse_version} < 1600
mkdir -p %{buildroot}%{_sysconfdir}/alternatives mkdir -p %{buildroot}%{_sysconfdir}/alternatives
for ex in gcc cpp \ for ex in gcc cpp \
%if %{build_cp} %if %{build_cp}
@@ -1013,15 +1018,19 @@ fi
%endif %endif
%else %else
%{_prefix}/bin/%{gcc_target_arch}-gcc%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc%{binsuffix}
%if %{suse_version} < 1600
%{_prefix}/bin/%{gcc_target_arch}-cpp%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-cpp%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcc-ar%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc-ar%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcc-nm%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc-nm%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-lto-dump%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-lto-dump%{binsuffix}
%endif
%if 0%{!?gcc_libc_bootstrap:1} && "%{cross_arch}" != "bpf" %if 0%{!?gcc_libc_bootstrap:1} && "%{cross_arch}" != "bpf"
%if %{suse_version} < 1600
%{_prefix}/bin/%{gcc_target_arch}-gcov%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcov%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcov-dump%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcov-dump%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcov-tool%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcov-tool%{binsuffix}
%endif
%{_prefix}/bin/%{gcc_target_arch}-gcov %{_prefix}/bin/%{gcc_target_arch}-gcov
%{_prefix}/bin/%{gcc_target_arch}-gcov-dump %{_prefix}/bin/%{gcc_target_arch}-gcov-dump
%{_prefix}/bin/%{gcc_target_arch}-gcov-tool %{_prefix}/bin/%{gcc_target_arch}-gcov-tool
@@ -1032,6 +1041,7 @@ fi
%{_prefix}/bin/%{gcc_target_arch}-gcc-nm %{_prefix}/bin/%{gcc_target_arch}-gcc-nm
%{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib %{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib
%{_prefix}/bin/%{gcc_target_arch}-lto-dump %{_prefix}/bin/%{gcc_target_arch}-lto-dump
%if %{suse_version} < 1600
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-cpp %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-cpp
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc-ar %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc-ar
@@ -1043,13 +1053,16 @@ fi
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-dump %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-dump
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-tool %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-tool
%endif %endif
%endif
%if %{build_cp} %if %{build_cp}
%{_prefix}/bin/%{gcc_target_arch}-c++%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-g++%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-c++ %{_prefix}/bin/%{gcc_target_arch}-c++
%{_prefix}/bin/%{gcc_target_arch}-g++ %{_prefix}/bin/%{gcc_target_arch}-g++
%if %{suse_version} < 1600
%{_prefix}/bin/%{gcc_target_arch}-c++%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-g++%{binsuffix}
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-c++ %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-c++
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-g++ %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-g++
%endif
%if 0%{!?gcc_libc_bootstrap:1} %if 0%{!?gcc_libc_bootstrap:1}
%if "%{cross_arch}" == "avr" || 0%{?gcc_target_newlib:1} || 0%{?gcc_target_glibc:1} %if "%{cross_arch}" == "avr" || 0%{?gcc_target_newlib:1} || 0%{?gcc_target_glibc:1}
%{_prefix}/include/c++ %{_prefix}/include/c++

View File

@@ -292,26 +292,24 @@ ExclusiveArch: i586 ppc64le ppc64 x86_64 s390x riscv64
%if "%pkgname" == "cross-ppc64-gcc49" %if "%pkgname" == "cross-ppc64-gcc49"
Obsoletes: cross-ppc-gcc49 <= 4.9.0+r209354 Obsoletes: cross-ppc-gcc49 <= 4.9.0+r209354
%endif %endif
%if 0%{?gcc_target_newlib:1}%{?gcc_target_glibc:1} || "%{cross_arch}" == "avr" %if 0%{!?gcc_accel:1}
# Generally only one cross for the same target triplet can be installed # Generally only one cross for the same target triplet can be installed
# at the same time as we are populating a non-version-specific sysroot # at the same time as we are populating a non-version-specific sysroot
Provides: %{gcc_target_arch}-gcc
Conflicts: %selfconflict %{gcc_target_arch}-gcc
%endif
%if 0%{?gcc_libc_bootstrap:1}
# The -bootstrap packages file-conflict with the non-bootstrap variants. # The -bootstrap packages file-conflict with the non-bootstrap variants.
# Even if we don't actually (want to) distribute the bootstrap variants # Even if we don't actually (want to) distribute the bootstrap variants
# the following avoids repo-checker spamming us endlessly. # the following avoids repo-checker spamming us endlessly.
Provides: %{gcc_target_arch}-gcc
Conflicts: %{gcc_target_arch}-gcc Conflicts: %{gcc_target_arch}-gcc
Conflicts: %{pkgname}-bootstrap
%endif %endif
#!BuildIgnore: gcc-PIE #!BuildIgnore: gcc-PIE
%if 0%{build_cp:1} %if %{build_cp}
# The cross compiler only packages the arch specific c++ headers, so # The cross compiler only packages the arch specific c++ headers, so
# we need to depend on the host libstdc++ devel headers (we wouldn't need # we need to depend on the host libstdc++ devel headers (we wouldn't need
# the libs, though) # the libs, though)
Requires: libstdc++6-devel-gcc13 Requires: libstdc++6-devel-gcc13
%endif %endif
%if 0%{!?gcc_accel:1} %if 0%{!?gcc_accel:1} && %{suse_version} < 1600
BuildRequires: update-alternatives BuildRequires: update-alternatives
Requires(post): update-alternatives Requires(post): update-alternatives
Requires(preun): update-alternatives Requires(preun): update-alternatives
@@ -587,11 +585,11 @@ amdgcn-amdhsa,\
--enable-gnu-indirect-function \ --enable-gnu-indirect-function \
%endif %endif
%endif %endif
--program-suffix=%{binsuffix} \
%ifarch %{disable_multilib_arch} %ifarch %{disable_multilib_arch}
--disable-multilib \ --disable-multilib \
%endif %endif
%if 0%{!?gcc_target_arch:1} %if 0%{!?gcc_target_arch:1}
--program-suffix=%{binsuffix} \
%ifarch ia64 %ifarch ia64
--with-system-libunwind \ --with-system-libunwind \
%else %else
@@ -599,6 +597,9 @@ amdgcn-amdhsa,\
%endif %endif
%endif %endif
%if 0%{?gcc_target_arch:1} %if 0%{?gcc_target_arch:1}
%if 0%{?gcc_accel:1} || %{suse_version} < 1600
--program-suffix=%{binsuffix} \
%endif
--program-prefix=%{gcc_target_arch}- \ --program-prefix=%{gcc_target_arch}- \
--target=%{gcc_target_arch} \ --target=%{gcc_target_arch} \
--disable-nls \ --disable-nls \
@@ -686,7 +687,7 @@ amdgcn-amdhsa,\
%endif %endif
%if %{suse_version} >= 1600 && !0%{?is_opensuse} %if %{suse_version} >= 1600 && !0%{?is_opensuse}
--with-cpu=power9 \ --with-cpu=power9 \
--with-tune=power9 \ --with-tune=power10 \
%else %else
%if %{suse_version} >= 1350 %if %{suse_version} >= 1350
--with-cpu=power8 \ --with-cpu=power8 \
@@ -755,7 +756,7 @@ amdgcn-amdhsa,\
%endif %endif
%if "%{TARGET_ARCH}" == "s390" || "%{TARGET_ARCH}" == "s390x" %if "%{TARGET_ARCH}" == "s390" || "%{TARGET_ARCH}" == "s390x"
%if %{suse_version} >= 1600 && !0%{?is_opensuse} %if %{suse_version} >= 1600 && !0%{?is_opensuse}
--with-tune=z14 --with-arch=z14 \ --with-tune=z15 --with-arch=z14 \
%else %else
%if %{suse_version} >= 1310 %if %{suse_version} >= 1310
--with-tune=zEC12 --with-arch=z196 \ --with-tune=zEC12 --with-arch=z196 \
@@ -861,7 +862,7 @@ rm -f $RPM_BUILD_ROOT%{_libdir}/libiberty.a
mkdir -p $RPM_BUILD_ROOT/%{?sysroot:%sysroot} mkdir -p $RPM_BUILD_ROOT/%{?sysroot:%sysroot}
make DESTDIR=$RPM_BUILD_ROOT install-target make DESTDIR=$RPM_BUILD_ROOT install-target
%if %{build_cp} %if %{build_cp}
# So we installed libstdc++ headers into %prefix where they conflict # So we installed libstdc++ headers into %%prefix where they conflict
# with other host compilers. Rip out the non-target specific parts # with other host compilers. Rip out the non-target specific parts
# again. Note not all cross targets support libstdc++, so create the # again. Note not all cross targets support libstdc++, so create the
# directory to make things easier. # directory to make things easier.
@@ -886,6 +887,7 @@ rm -rf $RPM_BUILD_ROOT%{_infodir}
# for accelerators remove all frontends but lto1 and also install-tools # for accelerators remove all frontends but lto1 and also install-tools
%if 0%{?gcc_accel:1} %if 0%{?gcc_accel:1}
rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1 rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1
rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/f951
rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1plus rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1plus
rm -rf $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/install-tools rm -rf $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/install-tools
rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}/install-tools rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}/install-tools
@@ -893,6 +895,8 @@ rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}/install-tools
# that is the place where we later search for (only) # that is the place where we later search for (only)
( cd $RPM_BUILD_ROOT%{targetlibsubdir} && tar cf - . ) | ( cd $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch} && tar xf - ) ( cd $RPM_BUILD_ROOT%{targetlibsubdir} && tar cf - . ) | ( cd $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch} && tar xf - )
rm -rf $RPM_BUILD_ROOT%{targetlibsubdir} rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}
# also remove installed libstdc++ headers
rm -rf $RPM_BUILD_ROOT%{_prefix}/include/c++
%endif %endif
# for amdgcn install the symlinks to the llvm tools # for amdgcn install the symlinks to the llvm tools
# follow alternatives symlinks to the hardcoded version requirement # follow alternatives symlinks to the hardcoded version requirement
@@ -957,7 +961,7 @@ rm -r env
# we provide update-alternatives for selecting a compiler version for # we provide update-alternatives for selecting a compiler version for
# crosses # crosses
%if 0%{!?gcc_accel:1} %if 0%{!?gcc_accel:1} && %{suse_version} < 1600
mkdir -p %{buildroot}%{_sysconfdir}/alternatives mkdir -p %{buildroot}%{_sysconfdir}/alternatives
for ex in gcc cpp \ for ex in gcc cpp \
%if %{build_cp} %if %{build_cp}
@@ -1013,15 +1017,19 @@ fi
%endif %endif
%else %else
%{_prefix}/bin/%{gcc_target_arch}-gcc%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc%{binsuffix}
%if %{suse_version} < 1600
%{_prefix}/bin/%{gcc_target_arch}-cpp%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-cpp%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcc-ar%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc-ar%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcc-nm%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc-nm%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-lto-dump%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-lto-dump%{binsuffix}
%endif
%if 0%{!?gcc_libc_bootstrap:1} && "%{cross_arch}" != "bpf" %if 0%{!?gcc_libc_bootstrap:1} && "%{cross_arch}" != "bpf"
%if %{suse_version} < 1600
%{_prefix}/bin/%{gcc_target_arch}-gcov%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcov%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcov-dump%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcov-dump%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcov-tool%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcov-tool%{binsuffix}
%endif
%{_prefix}/bin/%{gcc_target_arch}-gcov %{_prefix}/bin/%{gcc_target_arch}-gcov
%{_prefix}/bin/%{gcc_target_arch}-gcov-dump %{_prefix}/bin/%{gcc_target_arch}-gcov-dump
%{_prefix}/bin/%{gcc_target_arch}-gcov-tool %{_prefix}/bin/%{gcc_target_arch}-gcov-tool
@@ -1032,6 +1040,7 @@ fi
%{_prefix}/bin/%{gcc_target_arch}-gcc-nm %{_prefix}/bin/%{gcc_target_arch}-gcc-nm
%{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib %{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib
%{_prefix}/bin/%{gcc_target_arch}-lto-dump %{_prefix}/bin/%{gcc_target_arch}-lto-dump
%if %{suse_version} < 1600
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-cpp %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-cpp
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc-ar %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc-ar
@@ -1043,13 +1052,16 @@ fi
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-dump %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-dump
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-tool %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-tool
%endif %endif
%endif
%if %{build_cp} %if %{build_cp}
%{_prefix}/bin/%{gcc_target_arch}-c++%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-g++%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-c++ %{_prefix}/bin/%{gcc_target_arch}-c++
%{_prefix}/bin/%{gcc_target_arch}-g++ %{_prefix}/bin/%{gcc_target_arch}-g++
%if %{suse_version} < 1600
%{_prefix}/bin/%{gcc_target_arch}-c++%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-g++%{binsuffix}
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-c++ %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-c++
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-g++ %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-g++
%endif
%if 0%{!?gcc_libc_bootstrap:1} %if 0%{!?gcc_libc_bootstrap:1}
%if "%{cross_arch}" == "avr" || 0%{?gcc_target_newlib:1} || 0%{?gcc_target_glibc:1} %if "%{cross_arch}" == "avr" || 0%{?gcc_target_newlib:1} || 0%{?gcc_target_glibc:1}
%{_prefix}/include/c++ %{_prefix}/include/c++

View File

@@ -292,26 +292,24 @@ ExclusiveArch: i586 ppc64le ppc64 x86_64 s390x aarch64 riscv64
%if "%pkgname" == "cross-ppc64-gcc49" %if "%pkgname" == "cross-ppc64-gcc49"
Obsoletes: cross-ppc-gcc49 <= 4.9.0+r209354 Obsoletes: cross-ppc-gcc49 <= 4.9.0+r209354
%endif %endif
%if 0%{?gcc_target_newlib:1}%{?gcc_target_glibc:1} || "%{cross_arch}" == "avr" %if 0%{!?gcc_accel:1}
# Generally only one cross for the same target triplet can be installed # Generally only one cross for the same target triplet can be installed
# at the same time as we are populating a non-version-specific sysroot # at the same time as we are populating a non-version-specific sysroot
Provides: %{gcc_target_arch}-gcc
Conflicts: %selfconflict %{gcc_target_arch}-gcc
%endif
%if 0%{?gcc_libc_bootstrap:1}
# The -bootstrap packages file-conflict with the non-bootstrap variants. # The -bootstrap packages file-conflict with the non-bootstrap variants.
# Even if we don't actually (want to) distribute the bootstrap variants # Even if we don't actually (want to) distribute the bootstrap variants
# the following avoids repo-checker spamming us endlessly. # the following avoids repo-checker spamming us endlessly.
Provides: %{gcc_target_arch}-gcc
Conflicts: %{gcc_target_arch}-gcc Conflicts: %{gcc_target_arch}-gcc
Conflicts: %{pkgname}-bootstrap
%endif %endif
#!BuildIgnore: gcc-PIE #!BuildIgnore: gcc-PIE
%if 0%{build_cp:1} %if %{build_cp}
# The cross compiler only packages the arch specific c++ headers, so # The cross compiler only packages the arch specific c++ headers, so
# we need to depend on the host libstdc++ devel headers (we wouldn't need # we need to depend on the host libstdc++ devel headers (we wouldn't need
# the libs, though) # the libs, though)
Requires: libstdc++6-devel-gcc13 Requires: libstdc++6-devel-gcc13
%endif %endif
%if 0%{!?gcc_accel:1} %if 0%{!?gcc_accel:1} && %{suse_version} < 1600
BuildRequires: update-alternatives BuildRequires: update-alternatives
Requires(post): update-alternatives Requires(post): update-alternatives
Requires(preun): update-alternatives Requires(preun): update-alternatives
@@ -587,11 +585,11 @@ amdgcn-amdhsa,\
--enable-gnu-indirect-function \ --enable-gnu-indirect-function \
%endif %endif
%endif %endif
--program-suffix=%{binsuffix} \
%ifarch %{disable_multilib_arch} %ifarch %{disable_multilib_arch}
--disable-multilib \ --disable-multilib \
%endif %endif
%if 0%{!?gcc_target_arch:1} %if 0%{!?gcc_target_arch:1}
--program-suffix=%{binsuffix} \
%ifarch ia64 %ifarch ia64
--with-system-libunwind \ --with-system-libunwind \
%else %else
@@ -599,6 +597,9 @@ amdgcn-amdhsa,\
%endif %endif
%endif %endif
%if 0%{?gcc_target_arch:1} %if 0%{?gcc_target_arch:1}
%if 0%{?gcc_accel:1} || %{suse_version} < 1600
--program-suffix=%{binsuffix} \
%endif
--program-prefix=%{gcc_target_arch}- \ --program-prefix=%{gcc_target_arch}- \
--target=%{gcc_target_arch} \ --target=%{gcc_target_arch} \
--disable-nls \ --disable-nls \
@@ -686,7 +687,7 @@ amdgcn-amdhsa,\
%endif %endif
%if %{suse_version} >= 1600 && !0%{?is_opensuse} %if %{suse_version} >= 1600 && !0%{?is_opensuse}
--with-cpu=power9 \ --with-cpu=power9 \
--with-tune=power9 \ --with-tune=power10 \
%else %else
%if %{suse_version} >= 1350 %if %{suse_version} >= 1350
--with-cpu=power8 \ --with-cpu=power8 \
@@ -755,7 +756,7 @@ amdgcn-amdhsa,\
%endif %endif
%if "%{TARGET_ARCH}" == "s390" || "%{TARGET_ARCH}" == "s390x" %if "%{TARGET_ARCH}" == "s390" || "%{TARGET_ARCH}" == "s390x"
%if %{suse_version} >= 1600 && !0%{?is_opensuse} %if %{suse_version} >= 1600 && !0%{?is_opensuse}
--with-tune=z14 --with-arch=z14 \ --with-tune=z15 --with-arch=z14 \
%else %else
%if %{suse_version} >= 1310 %if %{suse_version} >= 1310
--with-tune=zEC12 --with-arch=z196 \ --with-tune=zEC12 --with-arch=z196 \
@@ -861,7 +862,7 @@ rm -f $RPM_BUILD_ROOT%{_libdir}/libiberty.a
mkdir -p $RPM_BUILD_ROOT/%{?sysroot:%sysroot} mkdir -p $RPM_BUILD_ROOT/%{?sysroot:%sysroot}
make DESTDIR=$RPM_BUILD_ROOT install-target make DESTDIR=$RPM_BUILD_ROOT install-target
%if %{build_cp} %if %{build_cp}
# So we installed libstdc++ headers into %prefix where they conflict # So we installed libstdc++ headers into %%prefix where they conflict
# with other host compilers. Rip out the non-target specific parts # with other host compilers. Rip out the non-target specific parts
# again. Note not all cross targets support libstdc++, so create the # again. Note not all cross targets support libstdc++, so create the
# directory to make things easier. # directory to make things easier.
@@ -886,6 +887,7 @@ rm -rf $RPM_BUILD_ROOT%{_infodir}
# for accelerators remove all frontends but lto1 and also install-tools # for accelerators remove all frontends but lto1 and also install-tools
%if 0%{?gcc_accel:1} %if 0%{?gcc_accel:1}
rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1 rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1
rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/f951
rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1plus rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1plus
rm -rf $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/install-tools rm -rf $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/install-tools
rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}/install-tools rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}/install-tools
@@ -893,6 +895,8 @@ rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}/install-tools
# that is the place where we later search for (only) # that is the place where we later search for (only)
( cd $RPM_BUILD_ROOT%{targetlibsubdir} && tar cf - . ) | ( cd $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch} && tar xf - ) ( cd $RPM_BUILD_ROOT%{targetlibsubdir} && tar cf - . ) | ( cd $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch} && tar xf - )
rm -rf $RPM_BUILD_ROOT%{targetlibsubdir} rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}
# also remove installed libstdc++ headers
rm -rf $RPM_BUILD_ROOT%{_prefix}/include/c++
%endif %endif
# for amdgcn install the symlinks to the llvm tools # for amdgcn install the symlinks to the llvm tools
# follow alternatives symlinks to the hardcoded version requirement # follow alternatives symlinks to the hardcoded version requirement
@@ -957,7 +961,7 @@ rm -r env
# we provide update-alternatives for selecting a compiler version for # we provide update-alternatives for selecting a compiler version for
# crosses # crosses
%if 0%{!?gcc_accel:1} %if 0%{!?gcc_accel:1} && %{suse_version} < 1600
mkdir -p %{buildroot}%{_sysconfdir}/alternatives mkdir -p %{buildroot}%{_sysconfdir}/alternatives
for ex in gcc cpp \ for ex in gcc cpp \
%if %{build_cp} %if %{build_cp}
@@ -1013,15 +1017,19 @@ fi
%endif %endif
%else %else
%{_prefix}/bin/%{gcc_target_arch}-gcc%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc%{binsuffix}
%if %{suse_version} < 1600
%{_prefix}/bin/%{gcc_target_arch}-cpp%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-cpp%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcc-ar%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc-ar%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcc-nm%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc-nm%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-lto-dump%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-lto-dump%{binsuffix}
%endif
%if 0%{!?gcc_libc_bootstrap:1} && "%{cross_arch}" != "bpf" %if 0%{!?gcc_libc_bootstrap:1} && "%{cross_arch}" != "bpf"
%if %{suse_version} < 1600
%{_prefix}/bin/%{gcc_target_arch}-gcov%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcov%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcov-dump%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcov-dump%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcov-tool%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcov-tool%{binsuffix}
%endif
%{_prefix}/bin/%{gcc_target_arch}-gcov %{_prefix}/bin/%{gcc_target_arch}-gcov
%{_prefix}/bin/%{gcc_target_arch}-gcov-dump %{_prefix}/bin/%{gcc_target_arch}-gcov-dump
%{_prefix}/bin/%{gcc_target_arch}-gcov-tool %{_prefix}/bin/%{gcc_target_arch}-gcov-tool
@@ -1032,6 +1040,7 @@ fi
%{_prefix}/bin/%{gcc_target_arch}-gcc-nm %{_prefix}/bin/%{gcc_target_arch}-gcc-nm
%{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib %{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib
%{_prefix}/bin/%{gcc_target_arch}-lto-dump %{_prefix}/bin/%{gcc_target_arch}-lto-dump
%if %{suse_version} < 1600
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-cpp %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-cpp
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc-ar %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc-ar
@@ -1043,13 +1052,16 @@ fi
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-dump %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-dump
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-tool %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-tool
%endif %endif
%endif
%if %{build_cp} %if %{build_cp}
%{_prefix}/bin/%{gcc_target_arch}-c++%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-g++%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-c++ %{_prefix}/bin/%{gcc_target_arch}-c++
%{_prefix}/bin/%{gcc_target_arch}-g++ %{_prefix}/bin/%{gcc_target_arch}-g++
%if %{suse_version} < 1600
%{_prefix}/bin/%{gcc_target_arch}-c++%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-g++%{binsuffix}
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-c++ %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-c++
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-g++ %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-g++
%endif
%if 0%{!?gcc_libc_bootstrap:1} %if 0%{!?gcc_libc_bootstrap:1}
%if "%{cross_arch}" == "avr" || 0%{?gcc_target_newlib:1} || 0%{?gcc_target_glibc:1} %if "%{cross_arch}" == "avr" || 0%{?gcc_target_newlib:1} || 0%{?gcc_target_glibc:1}
%{_prefix}/include/c++ %{_prefix}/include/c++

View File

@@ -19,7 +19,8 @@
%define pkgname cross-arm-gcc13 %define pkgname cross-arm-gcc13
%define cross_arch arm %define cross_arch arm
%define gcc_target_arch arm-suse-linux-gnueabi %define gcc_target_arch arm-suse-linux-gnueabi
%define gcc_icecream 1 %define gcc_target_glibc 1
%define gcc_libc_bootstrap 1
# nospeccleaner # nospeccleaner
%define build_cp 0%{!?gcc_accel:1} %define build_cp 0%{!?gcc_accel:1}
@@ -292,26 +293,24 @@ ExclusiveArch: i586 ppc64le ppc64 x86_64 s390x aarch64 riscv64
%if "%pkgname" == "cross-ppc64-gcc49" %if "%pkgname" == "cross-ppc64-gcc49"
Obsoletes: cross-ppc-gcc49 <= 4.9.0+r209354 Obsoletes: cross-ppc-gcc49 <= 4.9.0+r209354
%endif %endif
%if 0%{?gcc_target_newlib:1}%{?gcc_target_glibc:1} || "%{cross_arch}" == "avr" %if 0%{!?gcc_accel:1}
# Generally only one cross for the same target triplet can be installed # Generally only one cross for the same target triplet can be installed
# at the same time as we are populating a non-version-specific sysroot # at the same time as we are populating a non-version-specific sysroot
Provides: %{gcc_target_arch}-gcc
Conflicts: %selfconflict %{gcc_target_arch}-gcc
%endif
%if 0%{?gcc_libc_bootstrap:1}
# The -bootstrap packages file-conflict with the non-bootstrap variants. # The -bootstrap packages file-conflict with the non-bootstrap variants.
# Even if we don't actually (want to) distribute the bootstrap variants # Even if we don't actually (want to) distribute the bootstrap variants
# the following avoids repo-checker spamming us endlessly. # the following avoids repo-checker spamming us endlessly.
Provides: %{gcc_target_arch}-gcc
Conflicts: %{gcc_target_arch}-gcc Conflicts: %{gcc_target_arch}-gcc
Conflicts: %{pkgname}-bootstrap
%endif %endif
#!BuildIgnore: gcc-PIE #!BuildIgnore: gcc-PIE
%if 0%{build_cp:1} %if %{build_cp}
# The cross compiler only packages the arch specific c++ headers, so # The cross compiler only packages the arch specific c++ headers, so
# we need to depend on the host libstdc++ devel headers (we wouldn't need # we need to depend on the host libstdc++ devel headers (we wouldn't need
# the libs, though) # the libs, though)
Requires: libstdc++6-devel-gcc13 Requires: libstdc++6-devel-gcc13
%endif %endif
%if 0%{!?gcc_accel:1} %if 0%{!?gcc_accel:1} && %{suse_version} < 1600
BuildRequires: update-alternatives BuildRequires: update-alternatives
Requires(post): update-alternatives Requires(post): update-alternatives
Requires(preun): update-alternatives Requires(preun): update-alternatives
@@ -587,11 +586,11 @@ amdgcn-amdhsa,\
--enable-gnu-indirect-function \ --enable-gnu-indirect-function \
%endif %endif
%endif %endif
--program-suffix=%{binsuffix} \
%ifarch %{disable_multilib_arch} %ifarch %{disable_multilib_arch}
--disable-multilib \ --disable-multilib \
%endif %endif
%if 0%{!?gcc_target_arch:1} %if 0%{!?gcc_target_arch:1}
--program-suffix=%{binsuffix} \
%ifarch ia64 %ifarch ia64
--with-system-libunwind \ --with-system-libunwind \
%else %else
@@ -599,6 +598,9 @@ amdgcn-amdhsa,\
%endif %endif
%endif %endif
%if 0%{?gcc_target_arch:1} %if 0%{?gcc_target_arch:1}
%if 0%{?gcc_accel:1} || %{suse_version} < 1600
--program-suffix=%{binsuffix} \
%endif
--program-prefix=%{gcc_target_arch}- \ --program-prefix=%{gcc_target_arch}- \
--target=%{gcc_target_arch} \ --target=%{gcc_target_arch} \
--disable-nls \ --disable-nls \
@@ -686,7 +688,7 @@ amdgcn-amdhsa,\
%endif %endif
%if %{suse_version} >= 1600 && !0%{?is_opensuse} %if %{suse_version} >= 1600 && !0%{?is_opensuse}
--with-cpu=power9 \ --with-cpu=power9 \
--with-tune=power9 \ --with-tune=power10 \
%else %else
%if %{suse_version} >= 1350 %if %{suse_version} >= 1350
--with-cpu=power8 \ --with-cpu=power8 \
@@ -755,7 +757,7 @@ amdgcn-amdhsa,\
%endif %endif
%if "%{TARGET_ARCH}" == "s390" || "%{TARGET_ARCH}" == "s390x" %if "%{TARGET_ARCH}" == "s390" || "%{TARGET_ARCH}" == "s390x"
%if %{suse_version} >= 1600 && !0%{?is_opensuse} %if %{suse_version} >= 1600 && !0%{?is_opensuse}
--with-tune=z14 --with-arch=z14 \ --with-tune=z15 --with-arch=z14 \
%else %else
%if %{suse_version} >= 1310 %if %{suse_version} >= 1310
--with-tune=zEC12 --with-arch=z196 \ --with-tune=zEC12 --with-arch=z196 \
@@ -861,7 +863,7 @@ rm -f $RPM_BUILD_ROOT%{_libdir}/libiberty.a
mkdir -p $RPM_BUILD_ROOT/%{?sysroot:%sysroot} mkdir -p $RPM_BUILD_ROOT/%{?sysroot:%sysroot}
make DESTDIR=$RPM_BUILD_ROOT install-target make DESTDIR=$RPM_BUILD_ROOT install-target
%if %{build_cp} %if %{build_cp}
# So we installed libstdc++ headers into %prefix where they conflict # So we installed libstdc++ headers into %%prefix where they conflict
# with other host compilers. Rip out the non-target specific parts # with other host compilers. Rip out the non-target specific parts
# again. Note not all cross targets support libstdc++, so create the # again. Note not all cross targets support libstdc++, so create the
# directory to make things easier. # directory to make things easier.
@@ -886,6 +888,7 @@ rm -rf $RPM_BUILD_ROOT%{_infodir}
# for accelerators remove all frontends but lto1 and also install-tools # for accelerators remove all frontends but lto1 and also install-tools
%if 0%{?gcc_accel:1} %if 0%{?gcc_accel:1}
rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1 rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1
rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/f951
rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1plus rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1plus
rm -rf $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/install-tools rm -rf $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/install-tools
rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}/install-tools rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}/install-tools
@@ -893,6 +896,8 @@ rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}/install-tools
# that is the place where we later search for (only) # that is the place where we later search for (only)
( cd $RPM_BUILD_ROOT%{targetlibsubdir} && tar cf - . ) | ( cd $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch} && tar xf - ) ( cd $RPM_BUILD_ROOT%{targetlibsubdir} && tar cf - . ) | ( cd $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch} && tar xf - )
rm -rf $RPM_BUILD_ROOT%{targetlibsubdir} rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}
# also remove installed libstdc++ headers
rm -rf $RPM_BUILD_ROOT%{_prefix}/include/c++
%endif %endif
# for amdgcn install the symlinks to the llvm tools # for amdgcn install the symlinks to the llvm tools
# follow alternatives symlinks to the hardcoded version requirement # follow alternatives symlinks to the hardcoded version requirement
@@ -957,7 +962,7 @@ rm -r env
# we provide update-alternatives for selecting a compiler version for # we provide update-alternatives for selecting a compiler version for
# crosses # crosses
%if 0%{!?gcc_accel:1} %if 0%{!?gcc_accel:1} && %{suse_version} < 1600
mkdir -p %{buildroot}%{_sysconfdir}/alternatives mkdir -p %{buildroot}%{_sysconfdir}/alternatives
for ex in gcc cpp \ for ex in gcc cpp \
%if %{build_cp} %if %{build_cp}
@@ -1013,15 +1018,19 @@ fi
%endif %endif
%else %else
%{_prefix}/bin/%{gcc_target_arch}-gcc%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc%{binsuffix}
%if %{suse_version} < 1600
%{_prefix}/bin/%{gcc_target_arch}-cpp%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-cpp%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcc-ar%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc-ar%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcc-nm%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc-nm%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-lto-dump%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-lto-dump%{binsuffix}
%endif
%if 0%{!?gcc_libc_bootstrap:1} && "%{cross_arch}" != "bpf" %if 0%{!?gcc_libc_bootstrap:1} && "%{cross_arch}" != "bpf"
%if %{suse_version} < 1600
%{_prefix}/bin/%{gcc_target_arch}-gcov%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcov%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcov-dump%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcov-dump%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcov-tool%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcov-tool%{binsuffix}
%endif
%{_prefix}/bin/%{gcc_target_arch}-gcov %{_prefix}/bin/%{gcc_target_arch}-gcov
%{_prefix}/bin/%{gcc_target_arch}-gcov-dump %{_prefix}/bin/%{gcc_target_arch}-gcov-dump
%{_prefix}/bin/%{gcc_target_arch}-gcov-tool %{_prefix}/bin/%{gcc_target_arch}-gcov-tool
@@ -1032,6 +1041,7 @@ fi
%{_prefix}/bin/%{gcc_target_arch}-gcc-nm %{_prefix}/bin/%{gcc_target_arch}-gcc-nm
%{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib %{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib
%{_prefix}/bin/%{gcc_target_arch}-lto-dump %{_prefix}/bin/%{gcc_target_arch}-lto-dump
%if %{suse_version} < 1600
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-cpp %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-cpp
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc-ar %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc-ar
@@ -1043,13 +1053,16 @@ fi
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-dump %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-dump
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-tool %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-tool
%endif %endif
%endif
%if %{build_cp} %if %{build_cp}
%{_prefix}/bin/%{gcc_target_arch}-c++%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-g++%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-c++ %{_prefix}/bin/%{gcc_target_arch}-c++
%{_prefix}/bin/%{gcc_target_arch}-g++ %{_prefix}/bin/%{gcc_target_arch}-g++
%if %{suse_version} < 1600
%{_prefix}/bin/%{gcc_target_arch}-c++%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-g++%{binsuffix}
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-c++ %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-c++
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-g++ %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-g++
%endif
%if 0%{!?gcc_libc_bootstrap:1} %if 0%{!?gcc_libc_bootstrap:1}
%if "%{cross_arch}" == "avr" || 0%{?gcc_target_newlib:1} || 0%{?gcc_target_glibc:1} %if "%{cross_arch}" == "avr" || 0%{?gcc_target_newlib:1} || 0%{?gcc_target_glibc:1}
%{_prefix}/include/c++ %{_prefix}/include/c++

View File

@@ -293,26 +293,24 @@ ExclusiveArch: i586 ppc64le ppc64 x86_64 s390x aarch64 riscv64
%if "%pkgname" == "cross-ppc64-gcc49" %if "%pkgname" == "cross-ppc64-gcc49"
Obsoletes: cross-ppc-gcc49 <= 4.9.0+r209354 Obsoletes: cross-ppc-gcc49 <= 4.9.0+r209354
%endif %endif
%if 0%{?gcc_target_newlib:1}%{?gcc_target_glibc:1} || "%{cross_arch}" == "avr" %if 0%{!?gcc_accel:1}
# Generally only one cross for the same target triplet can be installed # Generally only one cross for the same target triplet can be installed
# at the same time as we are populating a non-version-specific sysroot # at the same time as we are populating a non-version-specific sysroot
Provides: %{gcc_target_arch}-gcc
Conflicts: %selfconflict %{gcc_target_arch}-gcc
%endif
%if 0%{?gcc_libc_bootstrap:1}
# The -bootstrap packages file-conflict with the non-bootstrap variants. # The -bootstrap packages file-conflict with the non-bootstrap variants.
# Even if we don't actually (want to) distribute the bootstrap variants # Even if we don't actually (want to) distribute the bootstrap variants
# the following avoids repo-checker spamming us endlessly. # the following avoids repo-checker spamming us endlessly.
Provides: %{gcc_target_arch}-gcc
Conflicts: %{gcc_target_arch}-gcc Conflicts: %{gcc_target_arch}-gcc
Conflicts: %{pkgname}-bootstrap
%endif %endif
#!BuildIgnore: gcc-PIE #!BuildIgnore: gcc-PIE
%if 0%{build_cp:1} %if %{build_cp}
# The cross compiler only packages the arch specific c++ headers, so # The cross compiler only packages the arch specific c++ headers, so
# we need to depend on the host libstdc++ devel headers (we wouldn't need # we need to depend on the host libstdc++ devel headers (we wouldn't need
# the libs, though) # the libs, though)
Requires: libstdc++6-devel-gcc13 Requires: libstdc++6-devel-gcc13
%endif %endif
%if 0%{!?gcc_accel:1} %if 0%{!?gcc_accel:1} && %{suse_version} < 1600
BuildRequires: update-alternatives BuildRequires: update-alternatives
Requires(post): update-alternatives Requires(post): update-alternatives
Requires(preun): update-alternatives Requires(preun): update-alternatives
@@ -588,11 +586,11 @@ amdgcn-amdhsa,\
--enable-gnu-indirect-function \ --enable-gnu-indirect-function \
%endif %endif
%endif %endif
--program-suffix=%{binsuffix} \
%ifarch %{disable_multilib_arch} %ifarch %{disable_multilib_arch}
--disable-multilib \ --disable-multilib \
%endif %endif
%if 0%{!?gcc_target_arch:1} %if 0%{!?gcc_target_arch:1}
--program-suffix=%{binsuffix} \
%ifarch ia64 %ifarch ia64
--with-system-libunwind \ --with-system-libunwind \
%else %else
@@ -600,6 +598,9 @@ amdgcn-amdhsa,\
%endif %endif
%endif %endif
%if 0%{?gcc_target_arch:1} %if 0%{?gcc_target_arch:1}
%if 0%{?gcc_accel:1} || %{suse_version} < 1600
--program-suffix=%{binsuffix} \
%endif
--program-prefix=%{gcc_target_arch}- \ --program-prefix=%{gcc_target_arch}- \
--target=%{gcc_target_arch} \ --target=%{gcc_target_arch} \
--disable-nls \ --disable-nls \
@@ -687,7 +688,7 @@ amdgcn-amdhsa,\
%endif %endif
%if %{suse_version} >= 1600 && !0%{?is_opensuse} %if %{suse_version} >= 1600 && !0%{?is_opensuse}
--with-cpu=power9 \ --with-cpu=power9 \
--with-tune=power9 \ --with-tune=power10 \
%else %else
%if %{suse_version} >= 1350 %if %{suse_version} >= 1350
--with-cpu=power8 \ --with-cpu=power8 \
@@ -756,7 +757,7 @@ amdgcn-amdhsa,\
%endif %endif
%if "%{TARGET_ARCH}" == "s390" || "%{TARGET_ARCH}" == "s390x" %if "%{TARGET_ARCH}" == "s390" || "%{TARGET_ARCH}" == "s390x"
%if %{suse_version} >= 1600 && !0%{?is_opensuse} %if %{suse_version} >= 1600 && !0%{?is_opensuse}
--with-tune=z14 --with-arch=z14 \ --with-tune=z15 --with-arch=z14 \
%else %else
%if %{suse_version} >= 1310 %if %{suse_version} >= 1310
--with-tune=zEC12 --with-arch=z196 \ --with-tune=zEC12 --with-arch=z196 \
@@ -862,7 +863,7 @@ rm -f $RPM_BUILD_ROOT%{_libdir}/libiberty.a
mkdir -p $RPM_BUILD_ROOT/%{?sysroot:%sysroot} mkdir -p $RPM_BUILD_ROOT/%{?sysroot:%sysroot}
make DESTDIR=$RPM_BUILD_ROOT install-target make DESTDIR=$RPM_BUILD_ROOT install-target
%if %{build_cp} %if %{build_cp}
# So we installed libstdc++ headers into %prefix where they conflict # So we installed libstdc++ headers into %%prefix where they conflict
# with other host compilers. Rip out the non-target specific parts # with other host compilers. Rip out the non-target specific parts
# again. Note not all cross targets support libstdc++, so create the # again. Note not all cross targets support libstdc++, so create the
# directory to make things easier. # directory to make things easier.
@@ -887,6 +888,7 @@ rm -rf $RPM_BUILD_ROOT%{_infodir}
# for accelerators remove all frontends but lto1 and also install-tools # for accelerators remove all frontends but lto1 and also install-tools
%if 0%{?gcc_accel:1} %if 0%{?gcc_accel:1}
rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1 rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1
rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/f951
rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1plus rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1plus
rm -rf $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/install-tools rm -rf $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/install-tools
rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}/install-tools rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}/install-tools
@@ -894,6 +896,8 @@ rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}/install-tools
# that is the place where we later search for (only) # that is the place where we later search for (only)
( cd $RPM_BUILD_ROOT%{targetlibsubdir} && tar cf - . ) | ( cd $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch} && tar xf - ) ( cd $RPM_BUILD_ROOT%{targetlibsubdir} && tar cf - . ) | ( cd $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch} && tar xf - )
rm -rf $RPM_BUILD_ROOT%{targetlibsubdir} rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}
# also remove installed libstdc++ headers
rm -rf $RPM_BUILD_ROOT%{_prefix}/include/c++
%endif %endif
# for amdgcn install the symlinks to the llvm tools # for amdgcn install the symlinks to the llvm tools
# follow alternatives symlinks to the hardcoded version requirement # follow alternatives symlinks to the hardcoded version requirement
@@ -958,7 +962,7 @@ rm -r env
# we provide update-alternatives for selecting a compiler version for # we provide update-alternatives for selecting a compiler version for
# crosses # crosses
%if 0%{!?gcc_accel:1} %if 0%{!?gcc_accel:1} && %{suse_version} < 1600
mkdir -p %{buildroot}%{_sysconfdir}/alternatives mkdir -p %{buildroot}%{_sysconfdir}/alternatives
for ex in gcc cpp \ for ex in gcc cpp \
%if %{build_cp} %if %{build_cp}
@@ -1014,15 +1018,19 @@ fi
%endif %endif
%else %else
%{_prefix}/bin/%{gcc_target_arch}-gcc%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc%{binsuffix}
%if %{suse_version} < 1600
%{_prefix}/bin/%{gcc_target_arch}-cpp%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-cpp%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcc-ar%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc-ar%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcc-nm%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc-nm%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-lto-dump%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-lto-dump%{binsuffix}
%endif
%if 0%{!?gcc_libc_bootstrap:1} && "%{cross_arch}" != "bpf" %if 0%{!?gcc_libc_bootstrap:1} && "%{cross_arch}" != "bpf"
%if %{suse_version} < 1600
%{_prefix}/bin/%{gcc_target_arch}-gcov%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcov%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcov-dump%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcov-dump%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcov-tool%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcov-tool%{binsuffix}
%endif
%{_prefix}/bin/%{gcc_target_arch}-gcov %{_prefix}/bin/%{gcc_target_arch}-gcov
%{_prefix}/bin/%{gcc_target_arch}-gcov-dump %{_prefix}/bin/%{gcc_target_arch}-gcov-dump
%{_prefix}/bin/%{gcc_target_arch}-gcov-tool %{_prefix}/bin/%{gcc_target_arch}-gcov-tool
@@ -1033,6 +1041,7 @@ fi
%{_prefix}/bin/%{gcc_target_arch}-gcc-nm %{_prefix}/bin/%{gcc_target_arch}-gcc-nm
%{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib %{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib
%{_prefix}/bin/%{gcc_target_arch}-lto-dump %{_prefix}/bin/%{gcc_target_arch}-lto-dump
%if %{suse_version} < 1600
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-cpp %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-cpp
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc-ar %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc-ar
@@ -1044,13 +1053,16 @@ fi
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-dump %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-dump
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-tool %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-tool
%endif %endif
%endif
%if %{build_cp} %if %{build_cp}
%{_prefix}/bin/%{gcc_target_arch}-c++%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-g++%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-c++ %{_prefix}/bin/%{gcc_target_arch}-c++
%{_prefix}/bin/%{gcc_target_arch}-g++ %{_prefix}/bin/%{gcc_target_arch}-g++
%if %{suse_version} < 1600
%{_prefix}/bin/%{gcc_target_arch}-c++%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-g++%{binsuffix}
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-c++ %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-c++
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-g++ %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-g++
%endif
%if 0%{!?gcc_libc_bootstrap:1} %if 0%{!?gcc_libc_bootstrap:1}
%if "%{cross_arch}" == "avr" || 0%{?gcc_target_newlib:1} || 0%{?gcc_target_glibc:1} %if "%{cross_arch}" == "avr" || 0%{?gcc_target_newlib:1} || 0%{?gcc_target_glibc:1}
%{_prefix}/include/c++ %{_prefix}/include/c++

View File

@@ -292,26 +292,24 @@ ExclusiveArch: i586 ppc64le ppc64 x86_64 s390x aarch64 riscv64
%if "%pkgname" == "cross-ppc64-gcc49" %if "%pkgname" == "cross-ppc64-gcc49"
Obsoletes: cross-ppc-gcc49 <= 4.9.0+r209354 Obsoletes: cross-ppc-gcc49 <= 4.9.0+r209354
%endif %endif
%if 0%{?gcc_target_newlib:1}%{?gcc_target_glibc:1} || "%{cross_arch}" == "avr" %if 0%{!?gcc_accel:1}
# Generally only one cross for the same target triplet can be installed # Generally only one cross for the same target triplet can be installed
# at the same time as we are populating a non-version-specific sysroot # at the same time as we are populating a non-version-specific sysroot
Provides: %{gcc_target_arch}-gcc
Conflicts: %selfconflict %{gcc_target_arch}-gcc
%endif
%if 0%{?gcc_libc_bootstrap:1}
# The -bootstrap packages file-conflict with the non-bootstrap variants. # The -bootstrap packages file-conflict with the non-bootstrap variants.
# Even if we don't actually (want to) distribute the bootstrap variants # Even if we don't actually (want to) distribute the bootstrap variants
# the following avoids repo-checker spamming us endlessly. # the following avoids repo-checker spamming us endlessly.
Provides: %{gcc_target_arch}-gcc
Conflicts: %{gcc_target_arch}-gcc Conflicts: %{gcc_target_arch}-gcc
Conflicts: %{pkgname}-bootstrap
%endif %endif
#!BuildIgnore: gcc-PIE #!BuildIgnore: gcc-PIE
%if 0%{build_cp:1} %if %{build_cp}
# The cross compiler only packages the arch specific c++ headers, so # The cross compiler only packages the arch specific c++ headers, so
# we need to depend on the host libstdc++ devel headers (we wouldn't need # we need to depend on the host libstdc++ devel headers (we wouldn't need
# the libs, though) # the libs, though)
Requires: libstdc++6-devel-gcc13 Requires: libstdc++6-devel-gcc13
%endif %endif
%if 0%{!?gcc_accel:1} %if 0%{!?gcc_accel:1} && %{suse_version} < 1600
BuildRequires: update-alternatives BuildRequires: update-alternatives
Requires(post): update-alternatives Requires(post): update-alternatives
Requires(preun): update-alternatives Requires(preun): update-alternatives
@@ -587,11 +585,11 @@ amdgcn-amdhsa,\
--enable-gnu-indirect-function \ --enable-gnu-indirect-function \
%endif %endif
%endif %endif
--program-suffix=%{binsuffix} \
%ifarch %{disable_multilib_arch} %ifarch %{disable_multilib_arch}
--disable-multilib \ --disable-multilib \
%endif %endif
%if 0%{!?gcc_target_arch:1} %if 0%{!?gcc_target_arch:1}
--program-suffix=%{binsuffix} \
%ifarch ia64 %ifarch ia64
--with-system-libunwind \ --with-system-libunwind \
%else %else
@@ -599,6 +597,9 @@ amdgcn-amdhsa,\
%endif %endif
%endif %endif
%if 0%{?gcc_target_arch:1} %if 0%{?gcc_target_arch:1}
%if 0%{?gcc_accel:1} || %{suse_version} < 1600
--program-suffix=%{binsuffix} \
%endif
--program-prefix=%{gcc_target_arch}- \ --program-prefix=%{gcc_target_arch}- \
--target=%{gcc_target_arch} \ --target=%{gcc_target_arch} \
--disable-nls \ --disable-nls \
@@ -686,7 +687,7 @@ amdgcn-amdhsa,\
%endif %endif
%if %{suse_version} >= 1600 && !0%{?is_opensuse} %if %{suse_version} >= 1600 && !0%{?is_opensuse}
--with-cpu=power9 \ --with-cpu=power9 \
--with-tune=power9 \ --with-tune=power10 \
%else %else
%if %{suse_version} >= 1350 %if %{suse_version} >= 1350
--with-cpu=power8 \ --with-cpu=power8 \
@@ -755,7 +756,7 @@ amdgcn-amdhsa,\
%endif %endif
%if "%{TARGET_ARCH}" == "s390" || "%{TARGET_ARCH}" == "s390x" %if "%{TARGET_ARCH}" == "s390" || "%{TARGET_ARCH}" == "s390x"
%if %{suse_version} >= 1600 && !0%{?is_opensuse} %if %{suse_version} >= 1600 && !0%{?is_opensuse}
--with-tune=z14 --with-arch=z14 \ --with-tune=z15 --with-arch=z14 \
%else %else
%if %{suse_version} >= 1310 %if %{suse_version} >= 1310
--with-tune=zEC12 --with-arch=z196 \ --with-tune=zEC12 --with-arch=z196 \
@@ -861,7 +862,7 @@ rm -f $RPM_BUILD_ROOT%{_libdir}/libiberty.a
mkdir -p $RPM_BUILD_ROOT/%{?sysroot:%sysroot} mkdir -p $RPM_BUILD_ROOT/%{?sysroot:%sysroot}
make DESTDIR=$RPM_BUILD_ROOT install-target make DESTDIR=$RPM_BUILD_ROOT install-target
%if %{build_cp} %if %{build_cp}
# So we installed libstdc++ headers into %prefix where they conflict # So we installed libstdc++ headers into %%prefix where they conflict
# with other host compilers. Rip out the non-target specific parts # with other host compilers. Rip out the non-target specific parts
# again. Note not all cross targets support libstdc++, so create the # again. Note not all cross targets support libstdc++, so create the
# directory to make things easier. # directory to make things easier.
@@ -886,6 +887,7 @@ rm -rf $RPM_BUILD_ROOT%{_infodir}
# for accelerators remove all frontends but lto1 and also install-tools # for accelerators remove all frontends but lto1 and also install-tools
%if 0%{?gcc_accel:1} %if 0%{?gcc_accel:1}
rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1 rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1
rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/f951
rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1plus rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1plus
rm -rf $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/install-tools rm -rf $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/install-tools
rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}/install-tools rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}/install-tools
@@ -893,6 +895,8 @@ rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}/install-tools
# that is the place where we later search for (only) # that is the place where we later search for (only)
( cd $RPM_BUILD_ROOT%{targetlibsubdir} && tar cf - . ) | ( cd $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch} && tar xf - ) ( cd $RPM_BUILD_ROOT%{targetlibsubdir} && tar cf - . ) | ( cd $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch} && tar xf - )
rm -rf $RPM_BUILD_ROOT%{targetlibsubdir} rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}
# also remove installed libstdc++ headers
rm -rf $RPM_BUILD_ROOT%{_prefix}/include/c++
%endif %endif
# for amdgcn install the symlinks to the llvm tools # for amdgcn install the symlinks to the llvm tools
# follow alternatives symlinks to the hardcoded version requirement # follow alternatives symlinks to the hardcoded version requirement
@@ -957,7 +961,7 @@ rm -r env
# we provide update-alternatives for selecting a compiler version for # we provide update-alternatives for selecting a compiler version for
# crosses # crosses
%if 0%{!?gcc_accel:1} %if 0%{!?gcc_accel:1} && %{suse_version} < 1600
mkdir -p %{buildroot}%{_sysconfdir}/alternatives mkdir -p %{buildroot}%{_sysconfdir}/alternatives
for ex in gcc cpp \ for ex in gcc cpp \
%if %{build_cp} %if %{build_cp}
@@ -1013,15 +1017,19 @@ fi
%endif %endif
%else %else
%{_prefix}/bin/%{gcc_target_arch}-gcc%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc%{binsuffix}
%if %{suse_version} < 1600
%{_prefix}/bin/%{gcc_target_arch}-cpp%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-cpp%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcc-ar%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc-ar%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcc-nm%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc-nm%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-lto-dump%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-lto-dump%{binsuffix}
%endif
%if 0%{!?gcc_libc_bootstrap:1} && "%{cross_arch}" != "bpf" %if 0%{!?gcc_libc_bootstrap:1} && "%{cross_arch}" != "bpf"
%if %{suse_version} < 1600
%{_prefix}/bin/%{gcc_target_arch}-gcov%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcov%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcov-dump%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcov-dump%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcov-tool%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcov-tool%{binsuffix}
%endif
%{_prefix}/bin/%{gcc_target_arch}-gcov %{_prefix}/bin/%{gcc_target_arch}-gcov
%{_prefix}/bin/%{gcc_target_arch}-gcov-dump %{_prefix}/bin/%{gcc_target_arch}-gcov-dump
%{_prefix}/bin/%{gcc_target_arch}-gcov-tool %{_prefix}/bin/%{gcc_target_arch}-gcov-tool
@@ -1032,6 +1040,7 @@ fi
%{_prefix}/bin/%{gcc_target_arch}-gcc-nm %{_prefix}/bin/%{gcc_target_arch}-gcc-nm
%{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib %{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib
%{_prefix}/bin/%{gcc_target_arch}-lto-dump %{_prefix}/bin/%{gcc_target_arch}-lto-dump
%if %{suse_version} < 1600
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-cpp %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-cpp
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc-ar %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc-ar
@@ -1043,13 +1052,16 @@ fi
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-dump %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-dump
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-tool %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-tool
%endif %endif
%endif
%if %{build_cp} %if %{build_cp}
%{_prefix}/bin/%{gcc_target_arch}-c++%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-g++%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-c++ %{_prefix}/bin/%{gcc_target_arch}-c++
%{_prefix}/bin/%{gcc_target_arch}-g++ %{_prefix}/bin/%{gcc_target_arch}-g++
%if %{suse_version} < 1600
%{_prefix}/bin/%{gcc_target_arch}-c++%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-g++%{binsuffix}
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-c++ %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-c++
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-g++ %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-g++
%endif
%if 0%{!?gcc_libc_bootstrap:1} %if 0%{!?gcc_libc_bootstrap:1}
%if "%{cross_arch}" == "avr" || 0%{?gcc_target_newlib:1} || 0%{?gcc_target_glibc:1} %if "%{cross_arch}" == "avr" || 0%{?gcc_target_newlib:1} || 0%{?gcc_target_glibc:1}
%{_prefix}/include/c++ %{_prefix}/include/c++

View File

@@ -292,26 +292,24 @@ ExclusiveArch: i586 ppc64le ppc64 x86_64 s390x aarch64 riscv64
%if "%pkgname" == "cross-ppc64-gcc49" %if "%pkgname" == "cross-ppc64-gcc49"
Obsoletes: cross-ppc-gcc49 <= 4.9.0+r209354 Obsoletes: cross-ppc-gcc49 <= 4.9.0+r209354
%endif %endif
%if 0%{?gcc_target_newlib:1}%{?gcc_target_glibc:1} || "%{cross_arch}" == "avr" %if 0%{!?gcc_accel:1}
# Generally only one cross for the same target triplet can be installed # Generally only one cross for the same target triplet can be installed
# at the same time as we are populating a non-version-specific sysroot # at the same time as we are populating a non-version-specific sysroot
Provides: %{gcc_target_arch}-gcc
Conflicts: %selfconflict %{gcc_target_arch}-gcc
%endif
%if 0%{?gcc_libc_bootstrap:1}
# The -bootstrap packages file-conflict with the non-bootstrap variants. # The -bootstrap packages file-conflict with the non-bootstrap variants.
# Even if we don't actually (want to) distribute the bootstrap variants # Even if we don't actually (want to) distribute the bootstrap variants
# the following avoids repo-checker spamming us endlessly. # the following avoids repo-checker spamming us endlessly.
Provides: %{gcc_target_arch}-gcc
Conflicts: %{gcc_target_arch}-gcc Conflicts: %{gcc_target_arch}-gcc
Conflicts: %{pkgname}-bootstrap
%endif %endif
#!BuildIgnore: gcc-PIE #!BuildIgnore: gcc-PIE
%if 0%{build_cp:1} %if %{build_cp}
# The cross compiler only packages the arch specific c++ headers, so # The cross compiler only packages the arch specific c++ headers, so
# we need to depend on the host libstdc++ devel headers (we wouldn't need # we need to depend on the host libstdc++ devel headers (we wouldn't need
# the libs, though) # the libs, though)
Requires: libstdc++6-devel-gcc13 Requires: libstdc++6-devel-gcc13
%endif %endif
%if 0%{!?gcc_accel:1} %if 0%{!?gcc_accel:1} && %{suse_version} < 1600
BuildRequires: update-alternatives BuildRequires: update-alternatives
Requires(post): update-alternatives Requires(post): update-alternatives
Requires(preun): update-alternatives Requires(preun): update-alternatives
@@ -587,11 +585,11 @@ amdgcn-amdhsa,\
--enable-gnu-indirect-function \ --enable-gnu-indirect-function \
%endif %endif
%endif %endif
--program-suffix=%{binsuffix} \
%ifarch %{disable_multilib_arch} %ifarch %{disable_multilib_arch}
--disable-multilib \ --disable-multilib \
%endif %endif
%if 0%{!?gcc_target_arch:1} %if 0%{!?gcc_target_arch:1}
--program-suffix=%{binsuffix} \
%ifarch ia64 %ifarch ia64
--with-system-libunwind \ --with-system-libunwind \
%else %else
@@ -599,6 +597,9 @@ amdgcn-amdhsa,\
%endif %endif
%endif %endif
%if 0%{?gcc_target_arch:1} %if 0%{?gcc_target_arch:1}
%if 0%{?gcc_accel:1} || %{suse_version} < 1600
--program-suffix=%{binsuffix} \
%endif
--program-prefix=%{gcc_target_arch}- \ --program-prefix=%{gcc_target_arch}- \
--target=%{gcc_target_arch} \ --target=%{gcc_target_arch} \
--disable-nls \ --disable-nls \
@@ -686,7 +687,7 @@ amdgcn-amdhsa,\
%endif %endif
%if %{suse_version} >= 1600 && !0%{?is_opensuse} %if %{suse_version} >= 1600 && !0%{?is_opensuse}
--with-cpu=power9 \ --with-cpu=power9 \
--with-tune=power9 \ --with-tune=power10 \
%else %else
%if %{suse_version} >= 1350 %if %{suse_version} >= 1350
--with-cpu=power8 \ --with-cpu=power8 \
@@ -755,7 +756,7 @@ amdgcn-amdhsa,\
%endif %endif
%if "%{TARGET_ARCH}" == "s390" || "%{TARGET_ARCH}" == "s390x" %if "%{TARGET_ARCH}" == "s390" || "%{TARGET_ARCH}" == "s390x"
%if %{suse_version} >= 1600 && !0%{?is_opensuse} %if %{suse_version} >= 1600 && !0%{?is_opensuse}
--with-tune=z14 --with-arch=z14 \ --with-tune=z15 --with-arch=z14 \
%else %else
%if %{suse_version} >= 1310 %if %{suse_version} >= 1310
--with-tune=zEC12 --with-arch=z196 \ --with-tune=zEC12 --with-arch=z196 \
@@ -861,7 +862,7 @@ rm -f $RPM_BUILD_ROOT%{_libdir}/libiberty.a
mkdir -p $RPM_BUILD_ROOT/%{?sysroot:%sysroot} mkdir -p $RPM_BUILD_ROOT/%{?sysroot:%sysroot}
make DESTDIR=$RPM_BUILD_ROOT install-target make DESTDIR=$RPM_BUILD_ROOT install-target
%if %{build_cp} %if %{build_cp}
# So we installed libstdc++ headers into %prefix where they conflict # So we installed libstdc++ headers into %%prefix where they conflict
# with other host compilers. Rip out the non-target specific parts # with other host compilers. Rip out the non-target specific parts
# again. Note not all cross targets support libstdc++, so create the # again. Note not all cross targets support libstdc++, so create the
# directory to make things easier. # directory to make things easier.
@@ -886,6 +887,7 @@ rm -rf $RPM_BUILD_ROOT%{_infodir}
# for accelerators remove all frontends but lto1 and also install-tools # for accelerators remove all frontends but lto1 and also install-tools
%if 0%{?gcc_accel:1} %if 0%{?gcc_accel:1}
rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1 rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1
rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/f951
rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1plus rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1plus
rm -rf $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/install-tools rm -rf $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/install-tools
rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}/install-tools rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}/install-tools
@@ -893,6 +895,8 @@ rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}/install-tools
# that is the place where we later search for (only) # that is the place where we later search for (only)
( cd $RPM_BUILD_ROOT%{targetlibsubdir} && tar cf - . ) | ( cd $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch} && tar xf - ) ( cd $RPM_BUILD_ROOT%{targetlibsubdir} && tar cf - . ) | ( cd $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch} && tar xf - )
rm -rf $RPM_BUILD_ROOT%{targetlibsubdir} rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}
# also remove installed libstdc++ headers
rm -rf $RPM_BUILD_ROOT%{_prefix}/include/c++
%endif %endif
# for amdgcn install the symlinks to the llvm tools # for amdgcn install the symlinks to the llvm tools
# follow alternatives symlinks to the hardcoded version requirement # follow alternatives symlinks to the hardcoded version requirement
@@ -957,7 +961,7 @@ rm -r env
# we provide update-alternatives for selecting a compiler version for # we provide update-alternatives for selecting a compiler version for
# crosses # crosses
%if 0%{!?gcc_accel:1} %if 0%{!?gcc_accel:1} && %{suse_version} < 1600
mkdir -p %{buildroot}%{_sysconfdir}/alternatives mkdir -p %{buildroot}%{_sysconfdir}/alternatives
for ex in gcc cpp \ for ex in gcc cpp \
%if %{build_cp} %if %{build_cp}
@@ -1013,15 +1017,19 @@ fi
%endif %endif
%else %else
%{_prefix}/bin/%{gcc_target_arch}-gcc%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc%{binsuffix}
%if %{suse_version} < 1600
%{_prefix}/bin/%{gcc_target_arch}-cpp%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-cpp%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcc-ar%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc-ar%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcc-nm%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc-nm%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-lto-dump%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-lto-dump%{binsuffix}
%endif
%if 0%{!?gcc_libc_bootstrap:1} && "%{cross_arch}" != "bpf" %if 0%{!?gcc_libc_bootstrap:1} && "%{cross_arch}" != "bpf"
%if %{suse_version} < 1600
%{_prefix}/bin/%{gcc_target_arch}-gcov%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcov%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcov-dump%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcov-dump%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcov-tool%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcov-tool%{binsuffix}
%endif
%{_prefix}/bin/%{gcc_target_arch}-gcov %{_prefix}/bin/%{gcc_target_arch}-gcov
%{_prefix}/bin/%{gcc_target_arch}-gcov-dump %{_prefix}/bin/%{gcc_target_arch}-gcov-dump
%{_prefix}/bin/%{gcc_target_arch}-gcov-tool %{_prefix}/bin/%{gcc_target_arch}-gcov-tool
@@ -1032,6 +1040,7 @@ fi
%{_prefix}/bin/%{gcc_target_arch}-gcc-nm %{_prefix}/bin/%{gcc_target_arch}-gcc-nm
%{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib %{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib
%{_prefix}/bin/%{gcc_target_arch}-lto-dump %{_prefix}/bin/%{gcc_target_arch}-lto-dump
%if %{suse_version} < 1600
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-cpp %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-cpp
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc-ar %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc-ar
@@ -1043,13 +1052,16 @@ fi
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-dump %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-dump
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-tool %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-tool
%endif %endif
%endif
%if %{build_cp} %if %{build_cp}
%{_prefix}/bin/%{gcc_target_arch}-c++%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-g++%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-c++ %{_prefix}/bin/%{gcc_target_arch}-c++
%{_prefix}/bin/%{gcc_target_arch}-g++ %{_prefix}/bin/%{gcc_target_arch}-g++
%if %{suse_version} < 1600
%{_prefix}/bin/%{gcc_target_arch}-c++%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-g++%{binsuffix}
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-c++ %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-c++
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-g++ %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-g++
%endif
%if 0%{!?gcc_libc_bootstrap:1} %if 0%{!?gcc_libc_bootstrap:1}
%if "%{cross_arch}" == "avr" || 0%{?gcc_target_newlib:1} || 0%{?gcc_target_glibc:1} %if "%{cross_arch}" == "avr" || 0%{?gcc_target_newlib:1} || 0%{?gcc_target_glibc:1}
%{_prefix}/include/c++ %{_prefix}/include/c++

View File

@@ -292,26 +292,24 @@ ExclusiveArch: i586 ppc64le ppc64 x86_64 s390x aarch64 riscv64
%if "%pkgname" == "cross-ppc64-gcc49" %if "%pkgname" == "cross-ppc64-gcc49"
Obsoletes: cross-ppc-gcc49 <= 4.9.0+r209354 Obsoletes: cross-ppc-gcc49 <= 4.9.0+r209354
%endif %endif
%if 0%{?gcc_target_newlib:1}%{?gcc_target_glibc:1} || "%{cross_arch}" == "avr" %if 0%{!?gcc_accel:1}
# Generally only one cross for the same target triplet can be installed # Generally only one cross for the same target triplet can be installed
# at the same time as we are populating a non-version-specific sysroot # at the same time as we are populating a non-version-specific sysroot
Provides: %{gcc_target_arch}-gcc
Conflicts: %selfconflict %{gcc_target_arch}-gcc
%endif
%if 0%{?gcc_libc_bootstrap:1}
# The -bootstrap packages file-conflict with the non-bootstrap variants. # The -bootstrap packages file-conflict with the non-bootstrap variants.
# Even if we don't actually (want to) distribute the bootstrap variants # Even if we don't actually (want to) distribute the bootstrap variants
# the following avoids repo-checker spamming us endlessly. # the following avoids repo-checker spamming us endlessly.
Provides: %{gcc_target_arch}-gcc
Conflicts: %{gcc_target_arch}-gcc Conflicts: %{gcc_target_arch}-gcc
Conflicts: %{pkgname}-bootstrap
%endif %endif
#!BuildIgnore: gcc-PIE #!BuildIgnore: gcc-PIE
%if 0%{build_cp:1} %if %{build_cp}
# The cross compiler only packages the arch specific c++ headers, so # The cross compiler only packages the arch specific c++ headers, so
# we need to depend on the host libstdc++ devel headers (we wouldn't need # we need to depend on the host libstdc++ devel headers (we wouldn't need
# the libs, though) # the libs, though)
Requires: libstdc++6-devel-gcc13 Requires: libstdc++6-devel-gcc13
%endif %endif
%if 0%{!?gcc_accel:1} %if 0%{!?gcc_accel:1} && %{suse_version} < 1600
BuildRequires: update-alternatives BuildRequires: update-alternatives
Requires(post): update-alternatives Requires(post): update-alternatives
Requires(preun): update-alternatives Requires(preun): update-alternatives
@@ -587,11 +585,11 @@ amdgcn-amdhsa,\
--enable-gnu-indirect-function \ --enable-gnu-indirect-function \
%endif %endif
%endif %endif
--program-suffix=%{binsuffix} \
%ifarch %{disable_multilib_arch} %ifarch %{disable_multilib_arch}
--disable-multilib \ --disable-multilib \
%endif %endif
%if 0%{!?gcc_target_arch:1} %if 0%{!?gcc_target_arch:1}
--program-suffix=%{binsuffix} \
%ifarch ia64 %ifarch ia64
--with-system-libunwind \ --with-system-libunwind \
%else %else
@@ -599,6 +597,9 @@ amdgcn-amdhsa,\
%endif %endif
%endif %endif
%if 0%{?gcc_target_arch:1} %if 0%{?gcc_target_arch:1}
%if 0%{?gcc_accel:1} || %{suse_version} < 1600
--program-suffix=%{binsuffix} \
%endif
--program-prefix=%{gcc_target_arch}- \ --program-prefix=%{gcc_target_arch}- \
--target=%{gcc_target_arch} \ --target=%{gcc_target_arch} \
--disable-nls \ --disable-nls \
@@ -686,7 +687,7 @@ amdgcn-amdhsa,\
%endif %endif
%if %{suse_version} >= 1600 && !0%{?is_opensuse} %if %{suse_version} >= 1600 && !0%{?is_opensuse}
--with-cpu=power9 \ --with-cpu=power9 \
--with-tune=power9 \ --with-tune=power10 \
%else %else
%if %{suse_version} >= 1350 %if %{suse_version} >= 1350
--with-cpu=power8 \ --with-cpu=power8 \
@@ -755,7 +756,7 @@ amdgcn-amdhsa,\
%endif %endif
%if "%{TARGET_ARCH}" == "s390" || "%{TARGET_ARCH}" == "s390x" %if "%{TARGET_ARCH}" == "s390" || "%{TARGET_ARCH}" == "s390x"
%if %{suse_version} >= 1600 && !0%{?is_opensuse} %if %{suse_version} >= 1600 && !0%{?is_opensuse}
--with-tune=z14 --with-arch=z14 \ --with-tune=z15 --with-arch=z14 \
%else %else
%if %{suse_version} >= 1310 %if %{suse_version} >= 1310
--with-tune=zEC12 --with-arch=z196 \ --with-tune=zEC12 --with-arch=z196 \
@@ -861,7 +862,7 @@ rm -f $RPM_BUILD_ROOT%{_libdir}/libiberty.a
mkdir -p $RPM_BUILD_ROOT/%{?sysroot:%sysroot} mkdir -p $RPM_BUILD_ROOT/%{?sysroot:%sysroot}
make DESTDIR=$RPM_BUILD_ROOT install-target make DESTDIR=$RPM_BUILD_ROOT install-target
%if %{build_cp} %if %{build_cp}
# So we installed libstdc++ headers into %prefix where they conflict # So we installed libstdc++ headers into %%prefix where they conflict
# with other host compilers. Rip out the non-target specific parts # with other host compilers. Rip out the non-target specific parts
# again. Note not all cross targets support libstdc++, so create the # again. Note not all cross targets support libstdc++, so create the
# directory to make things easier. # directory to make things easier.
@@ -886,6 +887,7 @@ rm -rf $RPM_BUILD_ROOT%{_infodir}
# for accelerators remove all frontends but lto1 and also install-tools # for accelerators remove all frontends but lto1 and also install-tools
%if 0%{?gcc_accel:1} %if 0%{?gcc_accel:1}
rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1 rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1
rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/f951
rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1plus rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1plus
rm -rf $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/install-tools rm -rf $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/install-tools
rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}/install-tools rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}/install-tools
@@ -893,6 +895,8 @@ rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}/install-tools
# that is the place where we later search for (only) # that is the place where we later search for (only)
( cd $RPM_BUILD_ROOT%{targetlibsubdir} && tar cf - . ) | ( cd $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch} && tar xf - ) ( cd $RPM_BUILD_ROOT%{targetlibsubdir} && tar cf - . ) | ( cd $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch} && tar xf - )
rm -rf $RPM_BUILD_ROOT%{targetlibsubdir} rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}
# also remove installed libstdc++ headers
rm -rf $RPM_BUILD_ROOT%{_prefix}/include/c++
%endif %endif
# for amdgcn install the symlinks to the llvm tools # for amdgcn install the symlinks to the llvm tools
# follow alternatives symlinks to the hardcoded version requirement # follow alternatives symlinks to the hardcoded version requirement
@@ -957,7 +961,7 @@ rm -r env
# we provide update-alternatives for selecting a compiler version for # we provide update-alternatives for selecting a compiler version for
# crosses # crosses
%if 0%{!?gcc_accel:1} %if 0%{!?gcc_accel:1} && %{suse_version} < 1600
mkdir -p %{buildroot}%{_sysconfdir}/alternatives mkdir -p %{buildroot}%{_sysconfdir}/alternatives
for ex in gcc cpp \ for ex in gcc cpp \
%if %{build_cp} %if %{build_cp}
@@ -1013,15 +1017,19 @@ fi
%endif %endif
%else %else
%{_prefix}/bin/%{gcc_target_arch}-gcc%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc%{binsuffix}
%if %{suse_version} < 1600
%{_prefix}/bin/%{gcc_target_arch}-cpp%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-cpp%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcc-ar%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc-ar%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcc-nm%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc-nm%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-lto-dump%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-lto-dump%{binsuffix}
%endif
%if 0%{!?gcc_libc_bootstrap:1} && "%{cross_arch}" != "bpf" %if 0%{!?gcc_libc_bootstrap:1} && "%{cross_arch}" != "bpf"
%if %{suse_version} < 1600
%{_prefix}/bin/%{gcc_target_arch}-gcov%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcov%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcov-dump%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcov-dump%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcov-tool%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcov-tool%{binsuffix}
%endif
%{_prefix}/bin/%{gcc_target_arch}-gcov %{_prefix}/bin/%{gcc_target_arch}-gcov
%{_prefix}/bin/%{gcc_target_arch}-gcov-dump %{_prefix}/bin/%{gcc_target_arch}-gcov-dump
%{_prefix}/bin/%{gcc_target_arch}-gcov-tool %{_prefix}/bin/%{gcc_target_arch}-gcov-tool
@@ -1032,6 +1040,7 @@ fi
%{_prefix}/bin/%{gcc_target_arch}-gcc-nm %{_prefix}/bin/%{gcc_target_arch}-gcc-nm
%{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib %{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib
%{_prefix}/bin/%{gcc_target_arch}-lto-dump %{_prefix}/bin/%{gcc_target_arch}-lto-dump
%if %{suse_version} < 1600
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-cpp %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-cpp
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc-ar %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc-ar
@@ -1043,13 +1052,16 @@ fi
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-dump %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-dump
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-tool %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-tool
%endif %endif
%endif
%if %{build_cp} %if %{build_cp}
%{_prefix}/bin/%{gcc_target_arch}-c++%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-g++%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-c++ %{_prefix}/bin/%{gcc_target_arch}-c++
%{_prefix}/bin/%{gcc_target_arch}-g++ %{_prefix}/bin/%{gcc_target_arch}-g++
%if %{suse_version} < 1600
%{_prefix}/bin/%{gcc_target_arch}-c++%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-g++%{binsuffix}
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-c++ %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-c++
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-g++ %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-g++
%endif
%if 0%{!?gcc_libc_bootstrap:1} %if 0%{!?gcc_libc_bootstrap:1}
%if "%{cross_arch}" == "avr" || 0%{?gcc_target_newlib:1} || 0%{?gcc_target_glibc:1} %if "%{cross_arch}" == "avr" || 0%{?gcc_target_newlib:1} || 0%{?gcc_target_glibc:1}
%{_prefix}/include/c++ %{_prefix}/include/c++

View File

@@ -292,26 +292,24 @@ ExclusiveArch: i586 ppc64le ppc64 x86_64 s390x aarch64 riscv64
%if "%pkgname" == "cross-ppc64-gcc49" %if "%pkgname" == "cross-ppc64-gcc49"
Obsoletes: cross-ppc-gcc49 <= 4.9.0+r209354 Obsoletes: cross-ppc-gcc49 <= 4.9.0+r209354
%endif %endif
%if 0%{?gcc_target_newlib:1}%{?gcc_target_glibc:1} || "%{cross_arch}" == "avr" %if 0%{!?gcc_accel:1}
# Generally only one cross for the same target triplet can be installed # Generally only one cross for the same target triplet can be installed
# at the same time as we are populating a non-version-specific sysroot # at the same time as we are populating a non-version-specific sysroot
Provides: %{gcc_target_arch}-gcc
Conflicts: %selfconflict %{gcc_target_arch}-gcc
%endif
%if 0%{?gcc_libc_bootstrap:1}
# The -bootstrap packages file-conflict with the non-bootstrap variants. # The -bootstrap packages file-conflict with the non-bootstrap variants.
# Even if we don't actually (want to) distribute the bootstrap variants # Even if we don't actually (want to) distribute the bootstrap variants
# the following avoids repo-checker spamming us endlessly. # the following avoids repo-checker spamming us endlessly.
Provides: %{gcc_target_arch}-gcc
Conflicts: %{gcc_target_arch}-gcc Conflicts: %{gcc_target_arch}-gcc
Conflicts: %{pkgname}-bootstrap
%endif %endif
#!BuildIgnore: gcc-PIE #!BuildIgnore: gcc-PIE
%if 0%{build_cp:1} %if %{build_cp}
# The cross compiler only packages the arch specific c++ headers, so # The cross compiler only packages the arch specific c++ headers, so
# we need to depend on the host libstdc++ devel headers (we wouldn't need # we need to depend on the host libstdc++ devel headers (we wouldn't need
# the libs, though) # the libs, though)
Requires: libstdc++6-devel-gcc13 Requires: libstdc++6-devel-gcc13
%endif %endif
%if 0%{!?gcc_accel:1} %if 0%{!?gcc_accel:1} && %{suse_version} < 1600
BuildRequires: update-alternatives BuildRequires: update-alternatives
Requires(post): update-alternatives Requires(post): update-alternatives
Requires(preun): update-alternatives Requires(preun): update-alternatives
@@ -587,11 +585,11 @@ amdgcn-amdhsa,\
--enable-gnu-indirect-function \ --enable-gnu-indirect-function \
%endif %endif
%endif %endif
--program-suffix=%{binsuffix} \
%ifarch %{disable_multilib_arch} %ifarch %{disable_multilib_arch}
--disable-multilib \ --disable-multilib \
%endif %endif
%if 0%{!?gcc_target_arch:1} %if 0%{!?gcc_target_arch:1}
--program-suffix=%{binsuffix} \
%ifarch ia64 %ifarch ia64
--with-system-libunwind \ --with-system-libunwind \
%else %else
@@ -599,6 +597,9 @@ amdgcn-amdhsa,\
%endif %endif
%endif %endif
%if 0%{?gcc_target_arch:1} %if 0%{?gcc_target_arch:1}
%if 0%{?gcc_accel:1} || %{suse_version} < 1600
--program-suffix=%{binsuffix} \
%endif
--program-prefix=%{gcc_target_arch}- \ --program-prefix=%{gcc_target_arch}- \
--target=%{gcc_target_arch} \ --target=%{gcc_target_arch} \
--disable-nls \ --disable-nls \
@@ -686,7 +687,7 @@ amdgcn-amdhsa,\
%endif %endif
%if %{suse_version} >= 1600 && !0%{?is_opensuse} %if %{suse_version} >= 1600 && !0%{?is_opensuse}
--with-cpu=power9 \ --with-cpu=power9 \
--with-tune=power9 \ --with-tune=power10 \
%else %else
%if %{suse_version} >= 1350 %if %{suse_version} >= 1350
--with-cpu=power8 \ --with-cpu=power8 \
@@ -755,7 +756,7 @@ amdgcn-amdhsa,\
%endif %endif
%if "%{TARGET_ARCH}" == "s390" || "%{TARGET_ARCH}" == "s390x" %if "%{TARGET_ARCH}" == "s390" || "%{TARGET_ARCH}" == "s390x"
%if %{suse_version} >= 1600 && !0%{?is_opensuse} %if %{suse_version} >= 1600 && !0%{?is_opensuse}
--with-tune=z14 --with-arch=z14 \ --with-tune=z15 --with-arch=z14 \
%else %else
%if %{suse_version} >= 1310 %if %{suse_version} >= 1310
--with-tune=zEC12 --with-arch=z196 \ --with-tune=zEC12 --with-arch=z196 \
@@ -861,7 +862,7 @@ rm -f $RPM_BUILD_ROOT%{_libdir}/libiberty.a
mkdir -p $RPM_BUILD_ROOT/%{?sysroot:%sysroot} mkdir -p $RPM_BUILD_ROOT/%{?sysroot:%sysroot}
make DESTDIR=$RPM_BUILD_ROOT install-target make DESTDIR=$RPM_BUILD_ROOT install-target
%if %{build_cp} %if %{build_cp}
# So we installed libstdc++ headers into %prefix where they conflict # So we installed libstdc++ headers into %%prefix where they conflict
# with other host compilers. Rip out the non-target specific parts # with other host compilers. Rip out the non-target specific parts
# again. Note not all cross targets support libstdc++, so create the # again. Note not all cross targets support libstdc++, so create the
# directory to make things easier. # directory to make things easier.
@@ -886,6 +887,7 @@ rm -rf $RPM_BUILD_ROOT%{_infodir}
# for accelerators remove all frontends but lto1 and also install-tools # for accelerators remove all frontends but lto1 and also install-tools
%if 0%{?gcc_accel:1} %if 0%{?gcc_accel:1}
rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1 rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1
rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/f951
rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1plus rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1plus
rm -rf $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/install-tools rm -rf $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/install-tools
rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}/install-tools rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}/install-tools
@@ -893,6 +895,8 @@ rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}/install-tools
# that is the place where we later search for (only) # that is the place where we later search for (only)
( cd $RPM_BUILD_ROOT%{targetlibsubdir} && tar cf - . ) | ( cd $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch} && tar xf - ) ( cd $RPM_BUILD_ROOT%{targetlibsubdir} && tar cf - . ) | ( cd $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch} && tar xf - )
rm -rf $RPM_BUILD_ROOT%{targetlibsubdir} rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}
# also remove installed libstdc++ headers
rm -rf $RPM_BUILD_ROOT%{_prefix}/include/c++
%endif %endif
# for amdgcn install the symlinks to the llvm tools # for amdgcn install the symlinks to the llvm tools
# follow alternatives symlinks to the hardcoded version requirement # follow alternatives symlinks to the hardcoded version requirement
@@ -957,7 +961,7 @@ rm -r env
# we provide update-alternatives for selecting a compiler version for # we provide update-alternatives for selecting a compiler version for
# crosses # crosses
%if 0%{!?gcc_accel:1} %if 0%{!?gcc_accel:1} && %{suse_version} < 1600
mkdir -p %{buildroot}%{_sysconfdir}/alternatives mkdir -p %{buildroot}%{_sysconfdir}/alternatives
for ex in gcc cpp \ for ex in gcc cpp \
%if %{build_cp} %if %{build_cp}
@@ -1013,15 +1017,19 @@ fi
%endif %endif
%else %else
%{_prefix}/bin/%{gcc_target_arch}-gcc%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc%{binsuffix}
%if %{suse_version} < 1600
%{_prefix}/bin/%{gcc_target_arch}-cpp%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-cpp%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcc-ar%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc-ar%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcc-nm%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc-nm%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-lto-dump%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-lto-dump%{binsuffix}
%endif
%if 0%{!?gcc_libc_bootstrap:1} && "%{cross_arch}" != "bpf" %if 0%{!?gcc_libc_bootstrap:1} && "%{cross_arch}" != "bpf"
%if %{suse_version} < 1600
%{_prefix}/bin/%{gcc_target_arch}-gcov%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcov%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcov-dump%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcov-dump%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcov-tool%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcov-tool%{binsuffix}
%endif
%{_prefix}/bin/%{gcc_target_arch}-gcov %{_prefix}/bin/%{gcc_target_arch}-gcov
%{_prefix}/bin/%{gcc_target_arch}-gcov-dump %{_prefix}/bin/%{gcc_target_arch}-gcov-dump
%{_prefix}/bin/%{gcc_target_arch}-gcov-tool %{_prefix}/bin/%{gcc_target_arch}-gcov-tool
@@ -1032,6 +1040,7 @@ fi
%{_prefix}/bin/%{gcc_target_arch}-gcc-nm %{_prefix}/bin/%{gcc_target_arch}-gcc-nm
%{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib %{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib
%{_prefix}/bin/%{gcc_target_arch}-lto-dump %{_prefix}/bin/%{gcc_target_arch}-lto-dump
%if %{suse_version} < 1600
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-cpp %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-cpp
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc-ar %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc-ar
@@ -1043,13 +1052,16 @@ fi
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-dump %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-dump
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-tool %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-tool
%endif %endif
%endif
%if %{build_cp} %if %{build_cp}
%{_prefix}/bin/%{gcc_target_arch}-c++%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-g++%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-c++ %{_prefix}/bin/%{gcc_target_arch}-c++
%{_prefix}/bin/%{gcc_target_arch}-g++ %{_prefix}/bin/%{gcc_target_arch}-g++
%if %{suse_version} < 1600
%{_prefix}/bin/%{gcc_target_arch}-c++%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-g++%{binsuffix}
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-c++ %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-c++
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-g++ %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-g++
%endif
%if 0%{!?gcc_libc_bootstrap:1} %if 0%{!?gcc_libc_bootstrap:1}
%if "%{cross_arch}" == "avr" || 0%{?gcc_target_newlib:1} || 0%{?gcc_target_glibc:1} %if "%{cross_arch}" == "avr" || 0%{?gcc_target_newlib:1} || 0%{?gcc_target_glibc:1}
%{_prefix}/include/c++ %{_prefix}/include/c++

View File

@@ -292,26 +292,24 @@ ExclusiveArch: i586 ppc64le ppc64 x86_64 s390x aarch64 riscv64
%if "%pkgname" == "cross-ppc64-gcc49" %if "%pkgname" == "cross-ppc64-gcc49"
Obsoletes: cross-ppc-gcc49 <= 4.9.0+r209354 Obsoletes: cross-ppc-gcc49 <= 4.9.0+r209354
%endif %endif
%if 0%{?gcc_target_newlib:1}%{?gcc_target_glibc:1} || "%{cross_arch}" == "avr" %if 0%{!?gcc_accel:1}
# Generally only one cross for the same target triplet can be installed # Generally only one cross for the same target triplet can be installed
# at the same time as we are populating a non-version-specific sysroot # at the same time as we are populating a non-version-specific sysroot
Provides: %{gcc_target_arch}-gcc
Conflicts: %selfconflict %{gcc_target_arch}-gcc
%endif
%if 0%{?gcc_libc_bootstrap:1}
# The -bootstrap packages file-conflict with the non-bootstrap variants. # The -bootstrap packages file-conflict with the non-bootstrap variants.
# Even if we don't actually (want to) distribute the bootstrap variants # Even if we don't actually (want to) distribute the bootstrap variants
# the following avoids repo-checker spamming us endlessly. # the following avoids repo-checker spamming us endlessly.
Provides: %{gcc_target_arch}-gcc
Conflicts: %{gcc_target_arch}-gcc Conflicts: %{gcc_target_arch}-gcc
Conflicts: %{pkgname}-bootstrap
%endif %endif
#!BuildIgnore: gcc-PIE #!BuildIgnore: gcc-PIE
%if 0%{build_cp:1} %if %{build_cp}
# The cross compiler only packages the arch specific c++ headers, so # The cross compiler only packages the arch specific c++ headers, so
# we need to depend on the host libstdc++ devel headers (we wouldn't need # we need to depend on the host libstdc++ devel headers (we wouldn't need
# the libs, though) # the libs, though)
Requires: libstdc++6-devel-gcc13 Requires: libstdc++6-devel-gcc13
%endif %endif
%if 0%{!?gcc_accel:1} %if 0%{!?gcc_accel:1} && %{suse_version} < 1600
BuildRequires: update-alternatives BuildRequires: update-alternatives
Requires(post): update-alternatives Requires(post): update-alternatives
Requires(preun): update-alternatives Requires(preun): update-alternatives
@@ -587,11 +585,11 @@ amdgcn-amdhsa,\
--enable-gnu-indirect-function \ --enable-gnu-indirect-function \
%endif %endif
%endif %endif
--program-suffix=%{binsuffix} \
%ifarch %{disable_multilib_arch} %ifarch %{disable_multilib_arch}
--disable-multilib \ --disable-multilib \
%endif %endif
%if 0%{!?gcc_target_arch:1} %if 0%{!?gcc_target_arch:1}
--program-suffix=%{binsuffix} \
%ifarch ia64 %ifarch ia64
--with-system-libunwind \ --with-system-libunwind \
%else %else
@@ -599,6 +597,9 @@ amdgcn-amdhsa,\
%endif %endif
%endif %endif
%if 0%{?gcc_target_arch:1} %if 0%{?gcc_target_arch:1}
%if 0%{?gcc_accel:1} || %{suse_version} < 1600
--program-suffix=%{binsuffix} \
%endif
--program-prefix=%{gcc_target_arch}- \ --program-prefix=%{gcc_target_arch}- \
--target=%{gcc_target_arch} \ --target=%{gcc_target_arch} \
--disable-nls \ --disable-nls \
@@ -686,7 +687,7 @@ amdgcn-amdhsa,\
%endif %endif
%if %{suse_version} >= 1600 && !0%{?is_opensuse} %if %{suse_version} >= 1600 && !0%{?is_opensuse}
--with-cpu=power9 \ --with-cpu=power9 \
--with-tune=power9 \ --with-tune=power10 \
%else %else
%if %{suse_version} >= 1350 %if %{suse_version} >= 1350
--with-cpu=power8 \ --with-cpu=power8 \
@@ -755,7 +756,7 @@ amdgcn-amdhsa,\
%endif %endif
%if "%{TARGET_ARCH}" == "s390" || "%{TARGET_ARCH}" == "s390x" %if "%{TARGET_ARCH}" == "s390" || "%{TARGET_ARCH}" == "s390x"
%if %{suse_version} >= 1600 && !0%{?is_opensuse} %if %{suse_version} >= 1600 && !0%{?is_opensuse}
--with-tune=z14 --with-arch=z14 \ --with-tune=z15 --with-arch=z14 \
%else %else
%if %{suse_version} >= 1310 %if %{suse_version} >= 1310
--with-tune=zEC12 --with-arch=z196 \ --with-tune=zEC12 --with-arch=z196 \
@@ -861,7 +862,7 @@ rm -f $RPM_BUILD_ROOT%{_libdir}/libiberty.a
mkdir -p $RPM_BUILD_ROOT/%{?sysroot:%sysroot} mkdir -p $RPM_BUILD_ROOT/%{?sysroot:%sysroot}
make DESTDIR=$RPM_BUILD_ROOT install-target make DESTDIR=$RPM_BUILD_ROOT install-target
%if %{build_cp} %if %{build_cp}
# So we installed libstdc++ headers into %prefix where they conflict # So we installed libstdc++ headers into %%prefix where they conflict
# with other host compilers. Rip out the non-target specific parts # with other host compilers. Rip out the non-target specific parts
# again. Note not all cross targets support libstdc++, so create the # again. Note not all cross targets support libstdc++, so create the
# directory to make things easier. # directory to make things easier.
@@ -886,6 +887,7 @@ rm -rf $RPM_BUILD_ROOT%{_infodir}
# for accelerators remove all frontends but lto1 and also install-tools # for accelerators remove all frontends but lto1 and also install-tools
%if 0%{?gcc_accel:1} %if 0%{?gcc_accel:1}
rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1 rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1
rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/f951
rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1plus rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1plus
rm -rf $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/install-tools rm -rf $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/install-tools
rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}/install-tools rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}/install-tools
@@ -893,6 +895,8 @@ rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}/install-tools
# that is the place where we later search for (only) # that is the place where we later search for (only)
( cd $RPM_BUILD_ROOT%{targetlibsubdir} && tar cf - . ) | ( cd $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch} && tar xf - ) ( cd $RPM_BUILD_ROOT%{targetlibsubdir} && tar cf - . ) | ( cd $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch} && tar xf - )
rm -rf $RPM_BUILD_ROOT%{targetlibsubdir} rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}
# also remove installed libstdc++ headers
rm -rf $RPM_BUILD_ROOT%{_prefix}/include/c++
%endif %endif
# for amdgcn install the symlinks to the llvm tools # for amdgcn install the symlinks to the llvm tools
# follow alternatives symlinks to the hardcoded version requirement # follow alternatives symlinks to the hardcoded version requirement
@@ -957,7 +961,7 @@ rm -r env
# we provide update-alternatives for selecting a compiler version for # we provide update-alternatives for selecting a compiler version for
# crosses # crosses
%if 0%{!?gcc_accel:1} %if 0%{!?gcc_accel:1} && %{suse_version} < 1600
mkdir -p %{buildroot}%{_sysconfdir}/alternatives mkdir -p %{buildroot}%{_sysconfdir}/alternatives
for ex in gcc cpp \ for ex in gcc cpp \
%if %{build_cp} %if %{build_cp}
@@ -1013,15 +1017,19 @@ fi
%endif %endif
%else %else
%{_prefix}/bin/%{gcc_target_arch}-gcc%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc%{binsuffix}
%if %{suse_version} < 1600
%{_prefix}/bin/%{gcc_target_arch}-cpp%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-cpp%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcc-ar%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc-ar%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcc-nm%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc-nm%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-lto-dump%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-lto-dump%{binsuffix}
%endif
%if 0%{!?gcc_libc_bootstrap:1} && "%{cross_arch}" != "bpf" %if 0%{!?gcc_libc_bootstrap:1} && "%{cross_arch}" != "bpf"
%if %{suse_version} < 1600
%{_prefix}/bin/%{gcc_target_arch}-gcov%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcov%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcov-dump%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcov-dump%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcov-tool%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcov-tool%{binsuffix}
%endif
%{_prefix}/bin/%{gcc_target_arch}-gcov %{_prefix}/bin/%{gcc_target_arch}-gcov
%{_prefix}/bin/%{gcc_target_arch}-gcov-dump %{_prefix}/bin/%{gcc_target_arch}-gcov-dump
%{_prefix}/bin/%{gcc_target_arch}-gcov-tool %{_prefix}/bin/%{gcc_target_arch}-gcov-tool
@@ -1032,6 +1040,7 @@ fi
%{_prefix}/bin/%{gcc_target_arch}-gcc-nm %{_prefix}/bin/%{gcc_target_arch}-gcc-nm
%{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib %{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib
%{_prefix}/bin/%{gcc_target_arch}-lto-dump %{_prefix}/bin/%{gcc_target_arch}-lto-dump
%if %{suse_version} < 1600
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-cpp %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-cpp
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc-ar %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc-ar
@@ -1043,13 +1052,16 @@ fi
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-dump %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-dump
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-tool %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-tool
%endif %endif
%endif
%if %{build_cp} %if %{build_cp}
%{_prefix}/bin/%{gcc_target_arch}-c++%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-g++%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-c++ %{_prefix}/bin/%{gcc_target_arch}-c++
%{_prefix}/bin/%{gcc_target_arch}-g++ %{_prefix}/bin/%{gcc_target_arch}-g++
%if %{suse_version} < 1600
%{_prefix}/bin/%{gcc_target_arch}-c++%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-g++%{binsuffix}
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-c++ %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-c++
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-g++ %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-g++
%endif
%if 0%{!?gcc_libc_bootstrap:1} %if 0%{!?gcc_libc_bootstrap:1}
%if "%{cross_arch}" == "avr" || 0%{?gcc_target_newlib:1} || 0%{?gcc_target_glibc:1} %if "%{cross_arch}" == "avr" || 0%{?gcc_target_newlib:1} || 0%{?gcc_target_glibc:1}
%{_prefix}/include/c++ %{_prefix}/include/c++

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@@ -292,26 +292,24 @@ ExclusiveArch: i586 ppc64le ppc64 x86_64 s390x aarch64 riscv64
%if "%pkgname" == "cross-ppc64-gcc49" %if "%pkgname" == "cross-ppc64-gcc49"
Obsoletes: cross-ppc-gcc49 <= 4.9.0+r209354 Obsoletes: cross-ppc-gcc49 <= 4.9.0+r209354
%endif %endif
%if 0%{?gcc_target_newlib:1}%{?gcc_target_glibc:1} || "%{cross_arch}" == "avr" %if 0%{!?gcc_accel:1}
# Generally only one cross for the same target triplet can be installed # Generally only one cross for the same target triplet can be installed
# at the same time as we are populating a non-version-specific sysroot # at the same time as we are populating a non-version-specific sysroot
Provides: %{gcc_target_arch}-gcc
Conflicts: %selfconflict %{gcc_target_arch}-gcc
%endif
%if 0%{?gcc_libc_bootstrap:1}
# The -bootstrap packages file-conflict with the non-bootstrap variants. # The -bootstrap packages file-conflict with the non-bootstrap variants.
# Even if we don't actually (want to) distribute the bootstrap variants # Even if we don't actually (want to) distribute the bootstrap variants
# the following avoids repo-checker spamming us endlessly. # the following avoids repo-checker spamming us endlessly.
Provides: %{gcc_target_arch}-gcc
Conflicts: %{gcc_target_arch}-gcc Conflicts: %{gcc_target_arch}-gcc
Conflicts: %{pkgname}-bootstrap
%endif %endif
#!BuildIgnore: gcc-PIE #!BuildIgnore: gcc-PIE
%if 0%{build_cp:1} %if %{build_cp}
# The cross compiler only packages the arch specific c++ headers, so # The cross compiler only packages the arch specific c++ headers, so
# we need to depend on the host libstdc++ devel headers (we wouldn't need # we need to depend on the host libstdc++ devel headers (we wouldn't need
# the libs, though) # the libs, though)
Requires: libstdc++6-devel-gcc13 Requires: libstdc++6-devel-gcc13
%endif %endif
%if 0%{!?gcc_accel:1} %if 0%{!?gcc_accel:1} && %{suse_version} < 1600
BuildRequires: update-alternatives BuildRequires: update-alternatives
Requires(post): update-alternatives Requires(post): update-alternatives
Requires(preun): update-alternatives Requires(preun): update-alternatives
@@ -587,11 +585,11 @@ amdgcn-amdhsa,\
--enable-gnu-indirect-function \ --enable-gnu-indirect-function \
%endif %endif
%endif %endif
--program-suffix=%{binsuffix} \
%ifarch %{disable_multilib_arch} %ifarch %{disable_multilib_arch}
--disable-multilib \ --disable-multilib \
%endif %endif
%if 0%{!?gcc_target_arch:1} %if 0%{!?gcc_target_arch:1}
--program-suffix=%{binsuffix} \
%ifarch ia64 %ifarch ia64
--with-system-libunwind \ --with-system-libunwind \
%else %else
@@ -599,6 +597,9 @@ amdgcn-amdhsa,\
%endif %endif
%endif %endif
%if 0%{?gcc_target_arch:1} %if 0%{?gcc_target_arch:1}
%if 0%{?gcc_accel:1} || %{suse_version} < 1600
--program-suffix=%{binsuffix} \
%endif
--program-prefix=%{gcc_target_arch}- \ --program-prefix=%{gcc_target_arch}- \
--target=%{gcc_target_arch} \ --target=%{gcc_target_arch} \
--disable-nls \ --disable-nls \
@@ -686,7 +687,7 @@ amdgcn-amdhsa,\
%endif %endif
%if %{suse_version} >= 1600 && !0%{?is_opensuse} %if %{suse_version} >= 1600 && !0%{?is_opensuse}
--with-cpu=power9 \ --with-cpu=power9 \
--with-tune=power9 \ --with-tune=power10 \
%else %else
%if %{suse_version} >= 1350 %if %{suse_version} >= 1350
--with-cpu=power8 \ --with-cpu=power8 \
@@ -755,7 +756,7 @@ amdgcn-amdhsa,\
%endif %endif
%if "%{TARGET_ARCH}" == "s390" || "%{TARGET_ARCH}" == "s390x" %if "%{TARGET_ARCH}" == "s390" || "%{TARGET_ARCH}" == "s390x"
%if %{suse_version} >= 1600 && !0%{?is_opensuse} %if %{suse_version} >= 1600 && !0%{?is_opensuse}
--with-tune=z14 --with-arch=z14 \ --with-tune=z15 --with-arch=z14 \
%else %else
%if %{suse_version} >= 1310 %if %{suse_version} >= 1310
--with-tune=zEC12 --with-arch=z196 \ --with-tune=zEC12 --with-arch=z196 \
@@ -861,7 +862,7 @@ rm -f $RPM_BUILD_ROOT%{_libdir}/libiberty.a
mkdir -p $RPM_BUILD_ROOT/%{?sysroot:%sysroot} mkdir -p $RPM_BUILD_ROOT/%{?sysroot:%sysroot}
make DESTDIR=$RPM_BUILD_ROOT install-target make DESTDIR=$RPM_BUILD_ROOT install-target
%if %{build_cp} %if %{build_cp}
# So we installed libstdc++ headers into %prefix where they conflict # So we installed libstdc++ headers into %%prefix where they conflict
# with other host compilers. Rip out the non-target specific parts # with other host compilers. Rip out the non-target specific parts
# again. Note not all cross targets support libstdc++, so create the # again. Note not all cross targets support libstdc++, so create the
# directory to make things easier. # directory to make things easier.
@@ -886,6 +887,7 @@ rm -rf $RPM_BUILD_ROOT%{_infodir}
# for accelerators remove all frontends but lto1 and also install-tools # for accelerators remove all frontends but lto1 and also install-tools
%if 0%{?gcc_accel:1} %if 0%{?gcc_accel:1}
rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1 rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1
rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/f951
rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1plus rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1plus
rm -rf $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/install-tools rm -rf $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/install-tools
rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}/install-tools rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}/install-tools
@@ -893,6 +895,8 @@ rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}/install-tools
# that is the place where we later search for (only) # that is the place where we later search for (only)
( cd $RPM_BUILD_ROOT%{targetlibsubdir} && tar cf - . ) | ( cd $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch} && tar xf - ) ( cd $RPM_BUILD_ROOT%{targetlibsubdir} && tar cf - . ) | ( cd $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch} && tar xf - )
rm -rf $RPM_BUILD_ROOT%{targetlibsubdir} rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}
# also remove installed libstdc++ headers
rm -rf $RPM_BUILD_ROOT%{_prefix}/include/c++
%endif %endif
# for amdgcn install the symlinks to the llvm tools # for amdgcn install the symlinks to the llvm tools
# follow alternatives symlinks to the hardcoded version requirement # follow alternatives symlinks to the hardcoded version requirement
@@ -957,7 +961,7 @@ rm -r env
# we provide update-alternatives for selecting a compiler version for # we provide update-alternatives for selecting a compiler version for
# crosses # crosses
%if 0%{!?gcc_accel:1} %if 0%{!?gcc_accel:1} && %{suse_version} < 1600
mkdir -p %{buildroot}%{_sysconfdir}/alternatives mkdir -p %{buildroot}%{_sysconfdir}/alternatives
for ex in gcc cpp \ for ex in gcc cpp \
%if %{build_cp} %if %{build_cp}
@@ -1013,15 +1017,19 @@ fi
%endif %endif
%else %else
%{_prefix}/bin/%{gcc_target_arch}-gcc%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc%{binsuffix}
%if %{suse_version} < 1600
%{_prefix}/bin/%{gcc_target_arch}-cpp%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-cpp%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcc-ar%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc-ar%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcc-nm%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc-nm%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-lto-dump%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-lto-dump%{binsuffix}
%endif
%if 0%{!?gcc_libc_bootstrap:1} && "%{cross_arch}" != "bpf" %if 0%{!?gcc_libc_bootstrap:1} && "%{cross_arch}" != "bpf"
%if %{suse_version} < 1600
%{_prefix}/bin/%{gcc_target_arch}-gcov%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcov%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcov-dump%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcov-dump%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcov-tool%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcov-tool%{binsuffix}
%endif
%{_prefix}/bin/%{gcc_target_arch}-gcov %{_prefix}/bin/%{gcc_target_arch}-gcov
%{_prefix}/bin/%{gcc_target_arch}-gcov-dump %{_prefix}/bin/%{gcc_target_arch}-gcov-dump
%{_prefix}/bin/%{gcc_target_arch}-gcov-tool %{_prefix}/bin/%{gcc_target_arch}-gcov-tool
@@ -1032,6 +1040,7 @@ fi
%{_prefix}/bin/%{gcc_target_arch}-gcc-nm %{_prefix}/bin/%{gcc_target_arch}-gcc-nm
%{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib %{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib
%{_prefix}/bin/%{gcc_target_arch}-lto-dump %{_prefix}/bin/%{gcc_target_arch}-lto-dump
%if %{suse_version} < 1600
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-cpp %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-cpp
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc-ar %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc-ar
@@ -1043,13 +1052,16 @@ fi
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-dump %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-dump
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-tool %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-tool
%endif %endif
%endif
%if %{build_cp} %if %{build_cp}
%{_prefix}/bin/%{gcc_target_arch}-c++%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-g++%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-c++ %{_prefix}/bin/%{gcc_target_arch}-c++
%{_prefix}/bin/%{gcc_target_arch}-g++ %{_prefix}/bin/%{gcc_target_arch}-g++
%if %{suse_version} < 1600
%{_prefix}/bin/%{gcc_target_arch}-c++%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-g++%{binsuffix}
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-c++ %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-c++
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-g++ %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-g++
%endif
%if 0%{!?gcc_libc_bootstrap:1} %if 0%{!?gcc_libc_bootstrap:1}
%if "%{cross_arch}" == "avr" || 0%{?gcc_target_newlib:1} || 0%{?gcc_target_glibc:1} %if "%{cross_arch}" == "avr" || 0%{?gcc_target_newlib:1} || 0%{?gcc_target_glibc:1}
%{_prefix}/include/c++ %{_prefix}/include/c++

View File

@@ -19,7 +19,8 @@
%define pkgname cross-ppc64-gcc13 %define pkgname cross-ppc64-gcc13
%define cross_arch ppc64 %define cross_arch ppc64
%define gcc_target_arch powerpc64-suse-linux %define gcc_target_arch powerpc64-suse-linux
%define gcc_icecream 1 %define gcc_target_glibc 1
%define gcc_libc_bootstrap 1
# nospeccleaner # nospeccleaner
%define build_cp 0%{!?gcc_accel:1} %define build_cp 0%{!?gcc_accel:1}
@@ -292,26 +293,24 @@ ExclusiveArch: i586 ppc64le x86_64 s390x aarch64 riscv64
%if "%pkgname" == "cross-ppc64-gcc49" %if "%pkgname" == "cross-ppc64-gcc49"
Obsoletes: cross-ppc-gcc49 <= 4.9.0+r209354 Obsoletes: cross-ppc-gcc49 <= 4.9.0+r209354
%endif %endif
%if 0%{?gcc_target_newlib:1}%{?gcc_target_glibc:1} || "%{cross_arch}" == "avr" %if 0%{!?gcc_accel:1}
# Generally only one cross for the same target triplet can be installed # Generally only one cross for the same target triplet can be installed
# at the same time as we are populating a non-version-specific sysroot # at the same time as we are populating a non-version-specific sysroot
Provides: %{gcc_target_arch}-gcc
Conflicts: %selfconflict %{gcc_target_arch}-gcc
%endif
%if 0%{?gcc_libc_bootstrap:1}
# The -bootstrap packages file-conflict with the non-bootstrap variants. # The -bootstrap packages file-conflict with the non-bootstrap variants.
# Even if we don't actually (want to) distribute the bootstrap variants # Even if we don't actually (want to) distribute the bootstrap variants
# the following avoids repo-checker spamming us endlessly. # the following avoids repo-checker spamming us endlessly.
Provides: %{gcc_target_arch}-gcc
Conflicts: %{gcc_target_arch}-gcc Conflicts: %{gcc_target_arch}-gcc
Conflicts: %{pkgname}-bootstrap
%endif %endif
#!BuildIgnore: gcc-PIE #!BuildIgnore: gcc-PIE
%if 0%{build_cp:1} %if %{build_cp}
# The cross compiler only packages the arch specific c++ headers, so # The cross compiler only packages the arch specific c++ headers, so
# we need to depend on the host libstdc++ devel headers (we wouldn't need # we need to depend on the host libstdc++ devel headers (we wouldn't need
# the libs, though) # the libs, though)
Requires: libstdc++6-devel-gcc13 Requires: libstdc++6-devel-gcc13
%endif %endif
%if 0%{!?gcc_accel:1} %if 0%{!?gcc_accel:1} && %{suse_version} < 1600
BuildRequires: update-alternatives BuildRequires: update-alternatives
Requires(post): update-alternatives Requires(post): update-alternatives
Requires(preun): update-alternatives Requires(preun): update-alternatives
@@ -587,11 +586,11 @@ amdgcn-amdhsa,\
--enable-gnu-indirect-function \ --enable-gnu-indirect-function \
%endif %endif
%endif %endif
--program-suffix=%{binsuffix} \
%ifarch %{disable_multilib_arch} %ifarch %{disable_multilib_arch}
--disable-multilib \ --disable-multilib \
%endif %endif
%if 0%{!?gcc_target_arch:1} %if 0%{!?gcc_target_arch:1}
--program-suffix=%{binsuffix} \
%ifarch ia64 %ifarch ia64
--with-system-libunwind \ --with-system-libunwind \
%else %else
@@ -599,6 +598,9 @@ amdgcn-amdhsa,\
%endif %endif
%endif %endif
%if 0%{?gcc_target_arch:1} %if 0%{?gcc_target_arch:1}
%if 0%{?gcc_accel:1} || %{suse_version} < 1600
--program-suffix=%{binsuffix} \
%endif
--program-prefix=%{gcc_target_arch}- \ --program-prefix=%{gcc_target_arch}- \
--target=%{gcc_target_arch} \ --target=%{gcc_target_arch} \
--disable-nls \ --disable-nls \
@@ -686,7 +688,7 @@ amdgcn-amdhsa,\
%endif %endif
%if %{suse_version} >= 1600 && !0%{?is_opensuse} %if %{suse_version} >= 1600 && !0%{?is_opensuse}
--with-cpu=power9 \ --with-cpu=power9 \
--with-tune=power9 \ --with-tune=power10 \
%else %else
%if %{suse_version} >= 1350 %if %{suse_version} >= 1350
--with-cpu=power8 \ --with-cpu=power8 \
@@ -755,7 +757,7 @@ amdgcn-amdhsa,\
%endif %endif
%if "%{TARGET_ARCH}" == "s390" || "%{TARGET_ARCH}" == "s390x" %if "%{TARGET_ARCH}" == "s390" || "%{TARGET_ARCH}" == "s390x"
%if %{suse_version} >= 1600 && !0%{?is_opensuse} %if %{suse_version} >= 1600 && !0%{?is_opensuse}
--with-tune=z14 --with-arch=z14 \ --with-tune=z15 --with-arch=z14 \
%else %else
%if %{suse_version} >= 1310 %if %{suse_version} >= 1310
--with-tune=zEC12 --with-arch=z196 \ --with-tune=zEC12 --with-arch=z196 \
@@ -861,7 +863,7 @@ rm -f $RPM_BUILD_ROOT%{_libdir}/libiberty.a
mkdir -p $RPM_BUILD_ROOT/%{?sysroot:%sysroot} mkdir -p $RPM_BUILD_ROOT/%{?sysroot:%sysroot}
make DESTDIR=$RPM_BUILD_ROOT install-target make DESTDIR=$RPM_BUILD_ROOT install-target
%if %{build_cp} %if %{build_cp}
# So we installed libstdc++ headers into %prefix where they conflict # So we installed libstdc++ headers into %%prefix where they conflict
# with other host compilers. Rip out the non-target specific parts # with other host compilers. Rip out the non-target specific parts
# again. Note not all cross targets support libstdc++, so create the # again. Note not all cross targets support libstdc++, so create the
# directory to make things easier. # directory to make things easier.
@@ -886,6 +888,7 @@ rm -rf $RPM_BUILD_ROOT%{_infodir}
# for accelerators remove all frontends but lto1 and also install-tools # for accelerators remove all frontends but lto1 and also install-tools
%if 0%{?gcc_accel:1} %if 0%{?gcc_accel:1}
rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1 rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1
rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/f951
rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1plus rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1plus
rm -rf $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/install-tools rm -rf $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/install-tools
rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}/install-tools rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}/install-tools
@@ -893,6 +896,8 @@ rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}/install-tools
# that is the place where we later search for (only) # that is the place where we later search for (only)
( cd $RPM_BUILD_ROOT%{targetlibsubdir} && tar cf - . ) | ( cd $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch} && tar xf - ) ( cd $RPM_BUILD_ROOT%{targetlibsubdir} && tar cf - . ) | ( cd $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch} && tar xf - )
rm -rf $RPM_BUILD_ROOT%{targetlibsubdir} rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}
# also remove installed libstdc++ headers
rm -rf $RPM_BUILD_ROOT%{_prefix}/include/c++
%endif %endif
# for amdgcn install the symlinks to the llvm tools # for amdgcn install the symlinks to the llvm tools
# follow alternatives symlinks to the hardcoded version requirement # follow alternatives symlinks to the hardcoded version requirement
@@ -957,7 +962,7 @@ rm -r env
# we provide update-alternatives for selecting a compiler version for # we provide update-alternatives for selecting a compiler version for
# crosses # crosses
%if 0%{!?gcc_accel:1} %if 0%{!?gcc_accel:1} && %{suse_version} < 1600
mkdir -p %{buildroot}%{_sysconfdir}/alternatives mkdir -p %{buildroot}%{_sysconfdir}/alternatives
for ex in gcc cpp \ for ex in gcc cpp \
%if %{build_cp} %if %{build_cp}
@@ -1013,15 +1018,19 @@ fi
%endif %endif
%else %else
%{_prefix}/bin/%{gcc_target_arch}-gcc%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc%{binsuffix}
%if %{suse_version} < 1600
%{_prefix}/bin/%{gcc_target_arch}-cpp%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-cpp%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcc-ar%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc-ar%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcc-nm%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc-nm%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-lto-dump%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-lto-dump%{binsuffix}
%endif
%if 0%{!?gcc_libc_bootstrap:1} && "%{cross_arch}" != "bpf" %if 0%{!?gcc_libc_bootstrap:1} && "%{cross_arch}" != "bpf"
%if %{suse_version} < 1600
%{_prefix}/bin/%{gcc_target_arch}-gcov%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcov%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcov-dump%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcov-dump%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcov-tool%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcov-tool%{binsuffix}
%endif
%{_prefix}/bin/%{gcc_target_arch}-gcov %{_prefix}/bin/%{gcc_target_arch}-gcov
%{_prefix}/bin/%{gcc_target_arch}-gcov-dump %{_prefix}/bin/%{gcc_target_arch}-gcov-dump
%{_prefix}/bin/%{gcc_target_arch}-gcov-tool %{_prefix}/bin/%{gcc_target_arch}-gcov-tool
@@ -1032,6 +1041,7 @@ fi
%{_prefix}/bin/%{gcc_target_arch}-gcc-nm %{_prefix}/bin/%{gcc_target_arch}-gcc-nm
%{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib %{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib
%{_prefix}/bin/%{gcc_target_arch}-lto-dump %{_prefix}/bin/%{gcc_target_arch}-lto-dump
%if %{suse_version} < 1600
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-cpp %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-cpp
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc-ar %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc-ar
@@ -1043,13 +1053,16 @@ fi
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-dump %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-dump
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-tool %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-tool
%endif %endif
%endif
%if %{build_cp} %if %{build_cp}
%{_prefix}/bin/%{gcc_target_arch}-c++%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-g++%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-c++ %{_prefix}/bin/%{gcc_target_arch}-c++
%{_prefix}/bin/%{gcc_target_arch}-g++ %{_prefix}/bin/%{gcc_target_arch}-g++
%if %{suse_version} < 1600
%{_prefix}/bin/%{gcc_target_arch}-c++%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-g++%{binsuffix}
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-c++ %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-c++
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-g++ %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-g++
%endif
%if 0%{!?gcc_libc_bootstrap:1} %if 0%{!?gcc_libc_bootstrap:1}
%if "%{cross_arch}" == "avr" || 0%{?gcc_target_newlib:1} || 0%{?gcc_target_glibc:1} %if "%{cross_arch}" == "avr" || 0%{?gcc_target_newlib:1} || 0%{?gcc_target_glibc:1}
%{_prefix}/include/c++ %{_prefix}/include/c++

View File

@@ -19,6 +19,7 @@
%define pkgname cross-ppc64le-gcc13-bootstrap %define pkgname cross-ppc64le-gcc13-bootstrap
%define cross_arch ppc64le %define cross_arch ppc64le
%define gcc_target_arch powerpc64le-suse-linux %define gcc_target_arch powerpc64le-suse-linux
%define gcc_target_glibc 1
%define gcc_libc_bootstrap 1 %define gcc_libc_bootstrap 1
# nospeccleaner # nospeccleaner
@@ -292,26 +293,24 @@ ExclusiveArch: i586 ppc64 x86_64 s390x aarch64 riscv64
%if "%pkgname" == "cross-ppc64-gcc49" %if "%pkgname" == "cross-ppc64-gcc49"
Obsoletes: cross-ppc-gcc49 <= 4.9.0+r209354 Obsoletes: cross-ppc-gcc49 <= 4.9.0+r209354
%endif %endif
%if 0%{?gcc_target_newlib:1}%{?gcc_target_glibc:1} || "%{cross_arch}" == "avr" %if 0%{!?gcc_accel:1}
# Generally only one cross for the same target triplet can be installed # Generally only one cross for the same target triplet can be installed
# at the same time as we are populating a non-version-specific sysroot # at the same time as we are populating a non-version-specific sysroot
Provides: %{gcc_target_arch}-gcc
Conflicts: %selfconflict %{gcc_target_arch}-gcc
%endif
%if 0%{?gcc_libc_bootstrap:1}
# The -bootstrap packages file-conflict with the non-bootstrap variants. # The -bootstrap packages file-conflict with the non-bootstrap variants.
# Even if we don't actually (want to) distribute the bootstrap variants # Even if we don't actually (want to) distribute the bootstrap variants
# the following avoids repo-checker spamming us endlessly. # the following avoids repo-checker spamming us endlessly.
Provides: %{gcc_target_arch}-gcc
Conflicts: %{gcc_target_arch}-gcc Conflicts: %{gcc_target_arch}-gcc
Conflicts: %{pkgname}-bootstrap
%endif %endif
#!BuildIgnore: gcc-PIE #!BuildIgnore: gcc-PIE
%if 0%{build_cp:1} %if %{build_cp}
# The cross compiler only packages the arch specific c++ headers, so # The cross compiler only packages the arch specific c++ headers, so
# we need to depend on the host libstdc++ devel headers (we wouldn't need # we need to depend on the host libstdc++ devel headers (we wouldn't need
# the libs, though) # the libs, though)
Requires: libstdc++6-devel-gcc13 Requires: libstdc++6-devel-gcc13
%endif %endif
%if 0%{!?gcc_accel:1} %if 0%{!?gcc_accel:1} && %{suse_version} < 1600
BuildRequires: update-alternatives BuildRequires: update-alternatives
Requires(post): update-alternatives Requires(post): update-alternatives
Requires(preun): update-alternatives Requires(preun): update-alternatives
@@ -587,11 +586,11 @@ amdgcn-amdhsa,\
--enable-gnu-indirect-function \ --enable-gnu-indirect-function \
%endif %endif
%endif %endif
--program-suffix=%{binsuffix} \
%ifarch %{disable_multilib_arch} %ifarch %{disable_multilib_arch}
--disable-multilib \ --disable-multilib \
%endif %endif
%if 0%{!?gcc_target_arch:1} %if 0%{!?gcc_target_arch:1}
--program-suffix=%{binsuffix} \
%ifarch ia64 %ifarch ia64
--with-system-libunwind \ --with-system-libunwind \
%else %else
@@ -599,6 +598,9 @@ amdgcn-amdhsa,\
%endif %endif
%endif %endif
%if 0%{?gcc_target_arch:1} %if 0%{?gcc_target_arch:1}
%if 0%{?gcc_accel:1} || %{suse_version} < 1600
--program-suffix=%{binsuffix} \
%endif
--program-prefix=%{gcc_target_arch}- \ --program-prefix=%{gcc_target_arch}- \
--target=%{gcc_target_arch} \ --target=%{gcc_target_arch} \
--disable-nls \ --disable-nls \
@@ -686,7 +688,7 @@ amdgcn-amdhsa,\
%endif %endif
%if %{suse_version} >= 1600 && !0%{?is_opensuse} %if %{suse_version} >= 1600 && !0%{?is_opensuse}
--with-cpu=power9 \ --with-cpu=power9 \
--with-tune=power9 \ --with-tune=power10 \
%else %else
%if %{suse_version} >= 1350 %if %{suse_version} >= 1350
--with-cpu=power8 \ --with-cpu=power8 \
@@ -755,7 +757,7 @@ amdgcn-amdhsa,\
%endif %endif
%if "%{TARGET_ARCH}" == "s390" || "%{TARGET_ARCH}" == "s390x" %if "%{TARGET_ARCH}" == "s390" || "%{TARGET_ARCH}" == "s390x"
%if %{suse_version} >= 1600 && !0%{?is_opensuse} %if %{suse_version} >= 1600 && !0%{?is_opensuse}
--with-tune=z14 --with-arch=z14 \ --with-tune=z15 --with-arch=z14 \
%else %else
%if %{suse_version} >= 1310 %if %{suse_version} >= 1310
--with-tune=zEC12 --with-arch=z196 \ --with-tune=zEC12 --with-arch=z196 \
@@ -861,7 +863,7 @@ rm -f $RPM_BUILD_ROOT%{_libdir}/libiberty.a
mkdir -p $RPM_BUILD_ROOT/%{?sysroot:%sysroot} mkdir -p $RPM_BUILD_ROOT/%{?sysroot:%sysroot}
make DESTDIR=$RPM_BUILD_ROOT install-target make DESTDIR=$RPM_BUILD_ROOT install-target
%if %{build_cp} %if %{build_cp}
# So we installed libstdc++ headers into %prefix where they conflict # So we installed libstdc++ headers into %%prefix where they conflict
# with other host compilers. Rip out the non-target specific parts # with other host compilers. Rip out the non-target specific parts
# again. Note not all cross targets support libstdc++, so create the # again. Note not all cross targets support libstdc++, so create the
# directory to make things easier. # directory to make things easier.
@@ -886,6 +888,7 @@ rm -rf $RPM_BUILD_ROOT%{_infodir}
# for accelerators remove all frontends but lto1 and also install-tools # for accelerators remove all frontends but lto1 and also install-tools
%if 0%{?gcc_accel:1} %if 0%{?gcc_accel:1}
rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1 rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1
rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/f951
rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1plus rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1plus
rm -rf $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/install-tools rm -rf $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/install-tools
rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}/install-tools rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}/install-tools
@@ -893,6 +896,8 @@ rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}/install-tools
# that is the place where we later search for (only) # that is the place where we later search for (only)
( cd $RPM_BUILD_ROOT%{targetlibsubdir} && tar cf - . ) | ( cd $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch} && tar xf - ) ( cd $RPM_BUILD_ROOT%{targetlibsubdir} && tar cf - . ) | ( cd $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch} && tar xf - )
rm -rf $RPM_BUILD_ROOT%{targetlibsubdir} rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}
# also remove installed libstdc++ headers
rm -rf $RPM_BUILD_ROOT%{_prefix}/include/c++
%endif %endif
# for amdgcn install the symlinks to the llvm tools # for amdgcn install the symlinks to the llvm tools
# follow alternatives symlinks to the hardcoded version requirement # follow alternatives symlinks to the hardcoded version requirement
@@ -957,7 +962,7 @@ rm -r env
# we provide update-alternatives for selecting a compiler version for # we provide update-alternatives for selecting a compiler version for
# crosses # crosses
%if 0%{!?gcc_accel:1} %if 0%{!?gcc_accel:1} && %{suse_version} < 1600
mkdir -p %{buildroot}%{_sysconfdir}/alternatives mkdir -p %{buildroot}%{_sysconfdir}/alternatives
for ex in gcc cpp \ for ex in gcc cpp \
%if %{build_cp} %if %{build_cp}
@@ -1013,15 +1018,19 @@ fi
%endif %endif
%else %else
%{_prefix}/bin/%{gcc_target_arch}-gcc%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc%{binsuffix}
%if %{suse_version} < 1600
%{_prefix}/bin/%{gcc_target_arch}-cpp%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-cpp%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcc-ar%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc-ar%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcc-nm%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc-nm%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-lto-dump%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-lto-dump%{binsuffix}
%endif
%if 0%{!?gcc_libc_bootstrap:1} && "%{cross_arch}" != "bpf" %if 0%{!?gcc_libc_bootstrap:1} && "%{cross_arch}" != "bpf"
%if %{suse_version} < 1600
%{_prefix}/bin/%{gcc_target_arch}-gcov%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcov%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcov-dump%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcov-dump%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcov-tool%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcov-tool%{binsuffix}
%endif
%{_prefix}/bin/%{gcc_target_arch}-gcov %{_prefix}/bin/%{gcc_target_arch}-gcov
%{_prefix}/bin/%{gcc_target_arch}-gcov-dump %{_prefix}/bin/%{gcc_target_arch}-gcov-dump
%{_prefix}/bin/%{gcc_target_arch}-gcov-tool %{_prefix}/bin/%{gcc_target_arch}-gcov-tool
@@ -1032,6 +1041,7 @@ fi
%{_prefix}/bin/%{gcc_target_arch}-gcc-nm %{_prefix}/bin/%{gcc_target_arch}-gcc-nm
%{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib %{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib
%{_prefix}/bin/%{gcc_target_arch}-lto-dump %{_prefix}/bin/%{gcc_target_arch}-lto-dump
%if %{suse_version} < 1600
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-cpp %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-cpp
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc-ar %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc-ar
@@ -1043,13 +1053,16 @@ fi
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-dump %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-dump
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-tool %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-tool
%endif %endif
%endif
%if %{build_cp} %if %{build_cp}
%{_prefix}/bin/%{gcc_target_arch}-c++%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-g++%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-c++ %{_prefix}/bin/%{gcc_target_arch}-c++
%{_prefix}/bin/%{gcc_target_arch}-g++ %{_prefix}/bin/%{gcc_target_arch}-g++
%if %{suse_version} < 1600
%{_prefix}/bin/%{gcc_target_arch}-c++%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-g++%{binsuffix}
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-c++ %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-c++
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-g++ %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-g++
%endif
%if 0%{!?gcc_libc_bootstrap:1} %if 0%{!?gcc_libc_bootstrap:1}
%if "%{cross_arch}" == "avr" || 0%{?gcc_target_newlib:1} || 0%{?gcc_target_glibc:1} %if "%{cross_arch}" == "avr" || 0%{?gcc_target_newlib:1} || 0%{?gcc_target_glibc:1}
%{_prefix}/include/c++ %{_prefix}/include/c++

View File

@@ -292,26 +292,24 @@ ExclusiveArch: i586 ppc64 x86_64 s390x aarch64 riscv64
%if "%pkgname" == "cross-ppc64-gcc49" %if "%pkgname" == "cross-ppc64-gcc49"
Obsoletes: cross-ppc-gcc49 <= 4.9.0+r209354 Obsoletes: cross-ppc-gcc49 <= 4.9.0+r209354
%endif %endif
%if 0%{?gcc_target_newlib:1}%{?gcc_target_glibc:1} || "%{cross_arch}" == "avr" %if 0%{!?gcc_accel:1}
# Generally only one cross for the same target triplet can be installed # Generally only one cross for the same target triplet can be installed
# at the same time as we are populating a non-version-specific sysroot # at the same time as we are populating a non-version-specific sysroot
Provides: %{gcc_target_arch}-gcc
Conflicts: %selfconflict %{gcc_target_arch}-gcc
%endif
%if 0%{?gcc_libc_bootstrap:1}
# The -bootstrap packages file-conflict with the non-bootstrap variants. # The -bootstrap packages file-conflict with the non-bootstrap variants.
# Even if we don't actually (want to) distribute the bootstrap variants # Even if we don't actually (want to) distribute the bootstrap variants
# the following avoids repo-checker spamming us endlessly. # the following avoids repo-checker spamming us endlessly.
Provides: %{gcc_target_arch}-gcc
Conflicts: %{gcc_target_arch}-gcc Conflicts: %{gcc_target_arch}-gcc
Conflicts: %{pkgname}-bootstrap
%endif %endif
#!BuildIgnore: gcc-PIE #!BuildIgnore: gcc-PIE
%if 0%{build_cp:1} %if %{build_cp}
# The cross compiler only packages the arch specific c++ headers, so # The cross compiler only packages the arch specific c++ headers, so
# we need to depend on the host libstdc++ devel headers (we wouldn't need # we need to depend on the host libstdc++ devel headers (we wouldn't need
# the libs, though) # the libs, though)
Requires: libstdc++6-devel-gcc13 Requires: libstdc++6-devel-gcc13
%endif %endif
%if 0%{!?gcc_accel:1} %if 0%{!?gcc_accel:1} && %{suse_version} < 1600
BuildRequires: update-alternatives BuildRequires: update-alternatives
Requires(post): update-alternatives Requires(post): update-alternatives
Requires(preun): update-alternatives Requires(preun): update-alternatives
@@ -587,11 +585,11 @@ amdgcn-amdhsa,\
--enable-gnu-indirect-function \ --enable-gnu-indirect-function \
%endif %endif
%endif %endif
--program-suffix=%{binsuffix} \
%ifarch %{disable_multilib_arch} %ifarch %{disable_multilib_arch}
--disable-multilib \ --disable-multilib \
%endif %endif
%if 0%{!?gcc_target_arch:1} %if 0%{!?gcc_target_arch:1}
--program-suffix=%{binsuffix} \
%ifarch ia64 %ifarch ia64
--with-system-libunwind \ --with-system-libunwind \
%else %else
@@ -599,6 +597,9 @@ amdgcn-amdhsa,\
%endif %endif
%endif %endif
%if 0%{?gcc_target_arch:1} %if 0%{?gcc_target_arch:1}
%if 0%{?gcc_accel:1} || %{suse_version} < 1600
--program-suffix=%{binsuffix} \
%endif
--program-prefix=%{gcc_target_arch}- \ --program-prefix=%{gcc_target_arch}- \
--target=%{gcc_target_arch} \ --target=%{gcc_target_arch} \
--disable-nls \ --disable-nls \
@@ -686,7 +687,7 @@ amdgcn-amdhsa,\
%endif %endif
%if %{suse_version} >= 1600 && !0%{?is_opensuse} %if %{suse_version} >= 1600 && !0%{?is_opensuse}
--with-cpu=power9 \ --with-cpu=power9 \
--with-tune=power9 \ --with-tune=power10 \
%else %else
%if %{suse_version} >= 1350 %if %{suse_version} >= 1350
--with-cpu=power8 \ --with-cpu=power8 \
@@ -755,7 +756,7 @@ amdgcn-amdhsa,\
%endif %endif
%if "%{TARGET_ARCH}" == "s390" || "%{TARGET_ARCH}" == "s390x" %if "%{TARGET_ARCH}" == "s390" || "%{TARGET_ARCH}" == "s390x"
%if %{suse_version} >= 1600 && !0%{?is_opensuse} %if %{suse_version} >= 1600 && !0%{?is_opensuse}
--with-tune=z14 --with-arch=z14 \ --with-tune=z15 --with-arch=z14 \
%else %else
%if %{suse_version} >= 1310 %if %{suse_version} >= 1310
--with-tune=zEC12 --with-arch=z196 \ --with-tune=zEC12 --with-arch=z196 \
@@ -861,7 +862,7 @@ rm -f $RPM_BUILD_ROOT%{_libdir}/libiberty.a
mkdir -p $RPM_BUILD_ROOT/%{?sysroot:%sysroot} mkdir -p $RPM_BUILD_ROOT/%{?sysroot:%sysroot}
make DESTDIR=$RPM_BUILD_ROOT install-target make DESTDIR=$RPM_BUILD_ROOT install-target
%if %{build_cp} %if %{build_cp}
# So we installed libstdc++ headers into %prefix where they conflict # So we installed libstdc++ headers into %%prefix where they conflict
# with other host compilers. Rip out the non-target specific parts # with other host compilers. Rip out the non-target specific parts
# again. Note not all cross targets support libstdc++, so create the # again. Note not all cross targets support libstdc++, so create the
# directory to make things easier. # directory to make things easier.
@@ -886,6 +887,7 @@ rm -rf $RPM_BUILD_ROOT%{_infodir}
# for accelerators remove all frontends but lto1 and also install-tools # for accelerators remove all frontends but lto1 and also install-tools
%if 0%{?gcc_accel:1} %if 0%{?gcc_accel:1}
rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1 rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1
rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/f951
rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1plus rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1plus
rm -rf $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/install-tools rm -rf $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/install-tools
rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}/install-tools rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}/install-tools
@@ -893,6 +895,8 @@ rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}/install-tools
# that is the place where we later search for (only) # that is the place where we later search for (only)
( cd $RPM_BUILD_ROOT%{targetlibsubdir} && tar cf - . ) | ( cd $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch} && tar xf - ) ( cd $RPM_BUILD_ROOT%{targetlibsubdir} && tar cf - . ) | ( cd $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch} && tar xf - )
rm -rf $RPM_BUILD_ROOT%{targetlibsubdir} rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}
# also remove installed libstdc++ headers
rm -rf $RPM_BUILD_ROOT%{_prefix}/include/c++
%endif %endif
# for amdgcn install the symlinks to the llvm tools # for amdgcn install the symlinks to the llvm tools
# follow alternatives symlinks to the hardcoded version requirement # follow alternatives symlinks to the hardcoded version requirement
@@ -957,7 +961,7 @@ rm -r env
# we provide update-alternatives for selecting a compiler version for # we provide update-alternatives for selecting a compiler version for
# crosses # crosses
%if 0%{!?gcc_accel:1} %if 0%{!?gcc_accel:1} && %{suse_version} < 1600
mkdir -p %{buildroot}%{_sysconfdir}/alternatives mkdir -p %{buildroot}%{_sysconfdir}/alternatives
for ex in gcc cpp \ for ex in gcc cpp \
%if %{build_cp} %if %{build_cp}
@@ -1013,15 +1017,19 @@ fi
%endif %endif
%else %else
%{_prefix}/bin/%{gcc_target_arch}-gcc%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc%{binsuffix}
%if %{suse_version} < 1600
%{_prefix}/bin/%{gcc_target_arch}-cpp%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-cpp%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcc-ar%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc-ar%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcc-nm%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc-nm%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-lto-dump%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-lto-dump%{binsuffix}
%endif
%if 0%{!?gcc_libc_bootstrap:1} && "%{cross_arch}" != "bpf" %if 0%{!?gcc_libc_bootstrap:1} && "%{cross_arch}" != "bpf"
%if %{suse_version} < 1600
%{_prefix}/bin/%{gcc_target_arch}-gcov%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcov%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcov-dump%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcov-dump%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcov-tool%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcov-tool%{binsuffix}
%endif
%{_prefix}/bin/%{gcc_target_arch}-gcov %{_prefix}/bin/%{gcc_target_arch}-gcov
%{_prefix}/bin/%{gcc_target_arch}-gcov-dump %{_prefix}/bin/%{gcc_target_arch}-gcov-dump
%{_prefix}/bin/%{gcc_target_arch}-gcov-tool %{_prefix}/bin/%{gcc_target_arch}-gcov-tool
@@ -1032,6 +1040,7 @@ fi
%{_prefix}/bin/%{gcc_target_arch}-gcc-nm %{_prefix}/bin/%{gcc_target_arch}-gcc-nm
%{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib %{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib
%{_prefix}/bin/%{gcc_target_arch}-lto-dump %{_prefix}/bin/%{gcc_target_arch}-lto-dump
%if %{suse_version} < 1600
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-cpp %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-cpp
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc-ar %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc-ar
@@ -1043,13 +1052,16 @@ fi
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-dump %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-dump
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-tool %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-tool
%endif %endif
%endif
%if %{build_cp} %if %{build_cp}
%{_prefix}/bin/%{gcc_target_arch}-c++%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-g++%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-c++ %{_prefix}/bin/%{gcc_target_arch}-c++
%{_prefix}/bin/%{gcc_target_arch}-g++ %{_prefix}/bin/%{gcc_target_arch}-g++
%if %{suse_version} < 1600
%{_prefix}/bin/%{gcc_target_arch}-c++%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-g++%{binsuffix}
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-c++ %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-c++
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-g++ %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-g++
%endif
%if 0%{!?gcc_libc_bootstrap:1} %if 0%{!?gcc_libc_bootstrap:1}
%if "%{cross_arch}" == "avr" || 0%{?gcc_target_newlib:1} || 0%{?gcc_target_glibc:1} %if "%{cross_arch}" == "avr" || 0%{?gcc_target_newlib:1} || 0%{?gcc_target_glibc:1}
%{_prefix}/include/c++ %{_prefix}/include/c++

View File

@@ -293,26 +293,24 @@ ExclusiveArch: i586 ppc64le ppc64 x86_64 s390x aarch64 riscv64
%if "%pkgname" == "cross-ppc64-gcc49" %if "%pkgname" == "cross-ppc64-gcc49"
Obsoletes: cross-ppc-gcc49 <= 4.9.0+r209354 Obsoletes: cross-ppc-gcc49 <= 4.9.0+r209354
%endif %endif
%if 0%{?gcc_target_newlib:1}%{?gcc_target_glibc:1} || "%{cross_arch}" == "avr" %if 0%{!?gcc_accel:1}
# Generally only one cross for the same target triplet can be installed # Generally only one cross for the same target triplet can be installed
# at the same time as we are populating a non-version-specific sysroot # at the same time as we are populating a non-version-specific sysroot
Provides: %{gcc_target_arch}-gcc
Conflicts: %selfconflict %{gcc_target_arch}-gcc
%endif
%if 0%{?gcc_libc_bootstrap:1}
# The -bootstrap packages file-conflict with the non-bootstrap variants. # The -bootstrap packages file-conflict with the non-bootstrap variants.
# Even if we don't actually (want to) distribute the bootstrap variants # Even if we don't actually (want to) distribute the bootstrap variants
# the following avoids repo-checker spamming us endlessly. # the following avoids repo-checker spamming us endlessly.
Provides: %{gcc_target_arch}-gcc
Conflicts: %{gcc_target_arch}-gcc Conflicts: %{gcc_target_arch}-gcc
Conflicts: %{pkgname}-bootstrap
%endif %endif
#!BuildIgnore: gcc-PIE #!BuildIgnore: gcc-PIE
%if 0%{build_cp:1} %if %{build_cp}
# The cross compiler only packages the arch specific c++ headers, so # The cross compiler only packages the arch specific c++ headers, so
# we need to depend on the host libstdc++ devel headers (we wouldn't need # we need to depend on the host libstdc++ devel headers (we wouldn't need
# the libs, though) # the libs, though)
Requires: libstdc++6-devel-gcc13 Requires: libstdc++6-devel-gcc13
%endif %endif
%if 0%{!?gcc_accel:1} %if 0%{!?gcc_accel:1} && %{suse_version} < 1600
BuildRequires: update-alternatives BuildRequires: update-alternatives
Requires(post): update-alternatives Requires(post): update-alternatives
Requires(preun): update-alternatives Requires(preun): update-alternatives
@@ -588,11 +586,11 @@ amdgcn-amdhsa,\
--enable-gnu-indirect-function \ --enable-gnu-indirect-function \
%endif %endif
%endif %endif
--program-suffix=%{binsuffix} \
%ifarch %{disable_multilib_arch} %ifarch %{disable_multilib_arch}
--disable-multilib \ --disable-multilib \
%endif %endif
%if 0%{!?gcc_target_arch:1} %if 0%{!?gcc_target_arch:1}
--program-suffix=%{binsuffix} \
%ifarch ia64 %ifarch ia64
--with-system-libunwind \ --with-system-libunwind \
%else %else
@@ -600,6 +598,9 @@ amdgcn-amdhsa,\
%endif %endif
%endif %endif
%if 0%{?gcc_target_arch:1} %if 0%{?gcc_target_arch:1}
%if 0%{?gcc_accel:1} || %{suse_version} < 1600
--program-suffix=%{binsuffix} \
%endif
--program-prefix=%{gcc_target_arch}- \ --program-prefix=%{gcc_target_arch}- \
--target=%{gcc_target_arch} \ --target=%{gcc_target_arch} \
--disable-nls \ --disable-nls \
@@ -687,7 +688,7 @@ amdgcn-amdhsa,\
%endif %endif
%if %{suse_version} >= 1600 && !0%{?is_opensuse} %if %{suse_version} >= 1600 && !0%{?is_opensuse}
--with-cpu=power9 \ --with-cpu=power9 \
--with-tune=power9 \ --with-tune=power10 \
%else %else
%if %{suse_version} >= 1350 %if %{suse_version} >= 1350
--with-cpu=power8 \ --with-cpu=power8 \
@@ -756,7 +757,7 @@ amdgcn-amdhsa,\
%endif %endif
%if "%{TARGET_ARCH}" == "s390" || "%{TARGET_ARCH}" == "s390x" %if "%{TARGET_ARCH}" == "s390" || "%{TARGET_ARCH}" == "s390x"
%if %{suse_version} >= 1600 && !0%{?is_opensuse} %if %{suse_version} >= 1600 && !0%{?is_opensuse}
--with-tune=z14 --with-arch=z14 \ --with-tune=z15 --with-arch=z14 \
%else %else
%if %{suse_version} >= 1310 %if %{suse_version} >= 1310
--with-tune=zEC12 --with-arch=z196 \ --with-tune=zEC12 --with-arch=z196 \
@@ -862,7 +863,7 @@ rm -f $RPM_BUILD_ROOT%{_libdir}/libiberty.a
mkdir -p $RPM_BUILD_ROOT/%{?sysroot:%sysroot} mkdir -p $RPM_BUILD_ROOT/%{?sysroot:%sysroot}
make DESTDIR=$RPM_BUILD_ROOT install-target make DESTDIR=$RPM_BUILD_ROOT install-target
%if %{build_cp} %if %{build_cp}
# So we installed libstdc++ headers into %prefix where they conflict # So we installed libstdc++ headers into %%prefix where they conflict
# with other host compilers. Rip out the non-target specific parts # with other host compilers. Rip out the non-target specific parts
# again. Note not all cross targets support libstdc++, so create the # again. Note not all cross targets support libstdc++, so create the
# directory to make things easier. # directory to make things easier.
@@ -887,6 +888,7 @@ rm -rf $RPM_BUILD_ROOT%{_infodir}
# for accelerators remove all frontends but lto1 and also install-tools # for accelerators remove all frontends but lto1 and also install-tools
%if 0%{?gcc_accel:1} %if 0%{?gcc_accel:1}
rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1 rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1
rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/f951
rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1plus rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1plus
rm -rf $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/install-tools rm -rf $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/install-tools
rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}/install-tools rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}/install-tools
@@ -894,6 +896,8 @@ rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}/install-tools
# that is the place where we later search for (only) # that is the place where we later search for (only)
( cd $RPM_BUILD_ROOT%{targetlibsubdir} && tar cf - . ) | ( cd $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch} && tar xf - ) ( cd $RPM_BUILD_ROOT%{targetlibsubdir} && tar cf - . ) | ( cd $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch} && tar xf - )
rm -rf $RPM_BUILD_ROOT%{targetlibsubdir} rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}
# also remove installed libstdc++ headers
rm -rf $RPM_BUILD_ROOT%{_prefix}/include/c++
%endif %endif
# for amdgcn install the symlinks to the llvm tools # for amdgcn install the symlinks to the llvm tools
# follow alternatives symlinks to the hardcoded version requirement # follow alternatives symlinks to the hardcoded version requirement
@@ -958,7 +962,7 @@ rm -r env
# we provide update-alternatives for selecting a compiler version for # we provide update-alternatives for selecting a compiler version for
# crosses # crosses
%if 0%{!?gcc_accel:1} %if 0%{!?gcc_accel:1} && %{suse_version} < 1600
mkdir -p %{buildroot}%{_sysconfdir}/alternatives mkdir -p %{buildroot}%{_sysconfdir}/alternatives
for ex in gcc cpp \ for ex in gcc cpp \
%if %{build_cp} %if %{build_cp}
@@ -1014,15 +1018,19 @@ fi
%endif %endif
%else %else
%{_prefix}/bin/%{gcc_target_arch}-gcc%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc%{binsuffix}
%if %{suse_version} < 1600
%{_prefix}/bin/%{gcc_target_arch}-cpp%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-cpp%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcc-ar%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc-ar%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcc-nm%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc-nm%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-lto-dump%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-lto-dump%{binsuffix}
%endif
%if 0%{!?gcc_libc_bootstrap:1} && "%{cross_arch}" != "bpf" %if 0%{!?gcc_libc_bootstrap:1} && "%{cross_arch}" != "bpf"
%if %{suse_version} < 1600
%{_prefix}/bin/%{gcc_target_arch}-gcov%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcov%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcov-dump%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcov-dump%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcov-tool%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcov-tool%{binsuffix}
%endif
%{_prefix}/bin/%{gcc_target_arch}-gcov %{_prefix}/bin/%{gcc_target_arch}-gcov
%{_prefix}/bin/%{gcc_target_arch}-gcov-dump %{_prefix}/bin/%{gcc_target_arch}-gcov-dump
%{_prefix}/bin/%{gcc_target_arch}-gcov-tool %{_prefix}/bin/%{gcc_target_arch}-gcov-tool
@@ -1033,6 +1041,7 @@ fi
%{_prefix}/bin/%{gcc_target_arch}-gcc-nm %{_prefix}/bin/%{gcc_target_arch}-gcc-nm
%{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib %{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib
%{_prefix}/bin/%{gcc_target_arch}-lto-dump %{_prefix}/bin/%{gcc_target_arch}-lto-dump
%if %{suse_version} < 1600
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-cpp %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-cpp
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc-ar %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc-ar
@@ -1044,13 +1053,16 @@ fi
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-dump %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-dump
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-tool %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-tool
%endif %endif
%endif
%if %{build_cp} %if %{build_cp}
%{_prefix}/bin/%{gcc_target_arch}-c++%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-g++%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-c++ %{_prefix}/bin/%{gcc_target_arch}-c++
%{_prefix}/bin/%{gcc_target_arch}-g++ %{_prefix}/bin/%{gcc_target_arch}-g++
%if %{suse_version} < 1600
%{_prefix}/bin/%{gcc_target_arch}-c++%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-g++%{binsuffix}
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-c++ %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-c++
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-g++ %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-g++
%endif
%if 0%{!?gcc_libc_bootstrap:1} %if 0%{!?gcc_libc_bootstrap:1}
%if "%{cross_arch}" == "avr" || 0%{?gcc_target_newlib:1} || 0%{?gcc_target_glibc:1} %if "%{cross_arch}" == "avr" || 0%{?gcc_target_newlib:1} || 0%{?gcc_target_glibc:1}
%{_prefix}/include/c++ %{_prefix}/include/c++

View File

@@ -292,26 +292,24 @@ ExclusiveArch: i586 ppc64le ppc64 x86_64 s390x aarch64 riscv64
%if "%pkgname" == "cross-ppc64-gcc49" %if "%pkgname" == "cross-ppc64-gcc49"
Obsoletes: cross-ppc-gcc49 <= 4.9.0+r209354 Obsoletes: cross-ppc-gcc49 <= 4.9.0+r209354
%endif %endif
%if 0%{?gcc_target_newlib:1}%{?gcc_target_glibc:1} || "%{cross_arch}" == "avr" %if 0%{!?gcc_accel:1}
# Generally only one cross for the same target triplet can be installed # Generally only one cross for the same target triplet can be installed
# at the same time as we are populating a non-version-specific sysroot # at the same time as we are populating a non-version-specific sysroot
Provides: %{gcc_target_arch}-gcc
Conflicts: %selfconflict %{gcc_target_arch}-gcc
%endif
%if 0%{?gcc_libc_bootstrap:1}
# The -bootstrap packages file-conflict with the non-bootstrap variants. # The -bootstrap packages file-conflict with the non-bootstrap variants.
# Even if we don't actually (want to) distribute the bootstrap variants # Even if we don't actually (want to) distribute the bootstrap variants
# the following avoids repo-checker spamming us endlessly. # the following avoids repo-checker spamming us endlessly.
Provides: %{gcc_target_arch}-gcc
Conflicts: %{gcc_target_arch}-gcc Conflicts: %{gcc_target_arch}-gcc
Conflicts: %{pkgname}-bootstrap
%endif %endif
#!BuildIgnore: gcc-PIE #!BuildIgnore: gcc-PIE
%if 0%{build_cp:1} %if %{build_cp}
# The cross compiler only packages the arch specific c++ headers, so # The cross compiler only packages the arch specific c++ headers, so
# we need to depend on the host libstdc++ devel headers (we wouldn't need # we need to depend on the host libstdc++ devel headers (we wouldn't need
# the libs, though) # the libs, though)
Requires: libstdc++6-devel-gcc13 Requires: libstdc++6-devel-gcc13
%endif %endif
%if 0%{!?gcc_accel:1} %if 0%{!?gcc_accel:1} && %{suse_version} < 1600
BuildRequires: update-alternatives BuildRequires: update-alternatives
Requires(post): update-alternatives Requires(post): update-alternatives
Requires(preun): update-alternatives Requires(preun): update-alternatives
@@ -587,11 +585,11 @@ amdgcn-amdhsa,\
--enable-gnu-indirect-function \ --enable-gnu-indirect-function \
%endif %endif
%endif %endif
--program-suffix=%{binsuffix} \
%ifarch %{disable_multilib_arch} %ifarch %{disable_multilib_arch}
--disable-multilib \ --disable-multilib \
%endif %endif
%if 0%{!?gcc_target_arch:1} %if 0%{!?gcc_target_arch:1}
--program-suffix=%{binsuffix} \
%ifarch ia64 %ifarch ia64
--with-system-libunwind \ --with-system-libunwind \
%else %else
@@ -599,6 +597,9 @@ amdgcn-amdhsa,\
%endif %endif
%endif %endif
%if 0%{?gcc_target_arch:1} %if 0%{?gcc_target_arch:1}
%if 0%{?gcc_accel:1} || %{suse_version} < 1600
--program-suffix=%{binsuffix} \
%endif
--program-prefix=%{gcc_target_arch}- \ --program-prefix=%{gcc_target_arch}- \
--target=%{gcc_target_arch} \ --target=%{gcc_target_arch} \
--disable-nls \ --disable-nls \
@@ -686,7 +687,7 @@ amdgcn-amdhsa,\
%endif %endif
%if %{suse_version} >= 1600 && !0%{?is_opensuse} %if %{suse_version} >= 1600 && !0%{?is_opensuse}
--with-cpu=power9 \ --with-cpu=power9 \
--with-tune=power9 \ --with-tune=power10 \
%else %else
%if %{suse_version} >= 1350 %if %{suse_version} >= 1350
--with-cpu=power8 \ --with-cpu=power8 \
@@ -755,7 +756,7 @@ amdgcn-amdhsa,\
%endif %endif
%if "%{TARGET_ARCH}" == "s390" || "%{TARGET_ARCH}" == "s390x" %if "%{TARGET_ARCH}" == "s390" || "%{TARGET_ARCH}" == "s390x"
%if %{suse_version} >= 1600 && !0%{?is_opensuse} %if %{suse_version} >= 1600 && !0%{?is_opensuse}
--with-tune=z14 --with-arch=z14 \ --with-tune=z15 --with-arch=z14 \
%else %else
%if %{suse_version} >= 1310 %if %{suse_version} >= 1310
--with-tune=zEC12 --with-arch=z196 \ --with-tune=zEC12 --with-arch=z196 \
@@ -861,7 +862,7 @@ rm -f $RPM_BUILD_ROOT%{_libdir}/libiberty.a
mkdir -p $RPM_BUILD_ROOT/%{?sysroot:%sysroot} mkdir -p $RPM_BUILD_ROOT/%{?sysroot:%sysroot}
make DESTDIR=$RPM_BUILD_ROOT install-target make DESTDIR=$RPM_BUILD_ROOT install-target
%if %{build_cp} %if %{build_cp}
# So we installed libstdc++ headers into %prefix where they conflict # So we installed libstdc++ headers into %%prefix where they conflict
# with other host compilers. Rip out the non-target specific parts # with other host compilers. Rip out the non-target specific parts
# again. Note not all cross targets support libstdc++, so create the # again. Note not all cross targets support libstdc++, so create the
# directory to make things easier. # directory to make things easier.
@@ -886,6 +887,7 @@ rm -rf $RPM_BUILD_ROOT%{_infodir}
# for accelerators remove all frontends but lto1 and also install-tools # for accelerators remove all frontends but lto1 and also install-tools
%if 0%{?gcc_accel:1} %if 0%{?gcc_accel:1}
rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1 rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1
rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/f951
rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1plus rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1plus
rm -rf $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/install-tools rm -rf $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/install-tools
rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}/install-tools rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}/install-tools
@@ -893,6 +895,8 @@ rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}/install-tools
# that is the place where we later search for (only) # that is the place where we later search for (only)
( cd $RPM_BUILD_ROOT%{targetlibsubdir} && tar cf - . ) | ( cd $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch} && tar xf - ) ( cd $RPM_BUILD_ROOT%{targetlibsubdir} && tar cf - . ) | ( cd $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch} && tar xf - )
rm -rf $RPM_BUILD_ROOT%{targetlibsubdir} rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}
# also remove installed libstdc++ headers
rm -rf $RPM_BUILD_ROOT%{_prefix}/include/c++
%endif %endif
# for amdgcn install the symlinks to the llvm tools # for amdgcn install the symlinks to the llvm tools
# follow alternatives symlinks to the hardcoded version requirement # follow alternatives symlinks to the hardcoded version requirement
@@ -957,7 +961,7 @@ rm -r env
# we provide update-alternatives for selecting a compiler version for # we provide update-alternatives for selecting a compiler version for
# crosses # crosses
%if 0%{!?gcc_accel:1} %if 0%{!?gcc_accel:1} && %{suse_version} < 1600
mkdir -p %{buildroot}%{_sysconfdir}/alternatives mkdir -p %{buildroot}%{_sysconfdir}/alternatives
for ex in gcc cpp \ for ex in gcc cpp \
%if %{build_cp} %if %{build_cp}
@@ -1013,15 +1017,19 @@ fi
%endif %endif
%else %else
%{_prefix}/bin/%{gcc_target_arch}-gcc%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc%{binsuffix}
%if %{suse_version} < 1600
%{_prefix}/bin/%{gcc_target_arch}-cpp%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-cpp%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcc-ar%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc-ar%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcc-nm%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc-nm%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-lto-dump%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-lto-dump%{binsuffix}
%endif
%if 0%{!?gcc_libc_bootstrap:1} && "%{cross_arch}" != "bpf" %if 0%{!?gcc_libc_bootstrap:1} && "%{cross_arch}" != "bpf"
%if %{suse_version} < 1600
%{_prefix}/bin/%{gcc_target_arch}-gcov%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcov%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcov-dump%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcov-dump%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcov-tool%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcov-tool%{binsuffix}
%endif
%{_prefix}/bin/%{gcc_target_arch}-gcov %{_prefix}/bin/%{gcc_target_arch}-gcov
%{_prefix}/bin/%{gcc_target_arch}-gcov-dump %{_prefix}/bin/%{gcc_target_arch}-gcov-dump
%{_prefix}/bin/%{gcc_target_arch}-gcov-tool %{_prefix}/bin/%{gcc_target_arch}-gcov-tool
@@ -1032,6 +1040,7 @@ fi
%{_prefix}/bin/%{gcc_target_arch}-gcc-nm %{_prefix}/bin/%{gcc_target_arch}-gcc-nm
%{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib %{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib
%{_prefix}/bin/%{gcc_target_arch}-lto-dump %{_prefix}/bin/%{gcc_target_arch}-lto-dump
%if %{suse_version} < 1600
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-cpp %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-cpp
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc-ar %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc-ar
@@ -1043,13 +1052,16 @@ fi
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-dump %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-dump
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-tool %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-tool
%endif %endif
%endif
%if %{build_cp} %if %{build_cp}
%{_prefix}/bin/%{gcc_target_arch}-c++%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-g++%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-c++ %{_prefix}/bin/%{gcc_target_arch}-c++
%{_prefix}/bin/%{gcc_target_arch}-g++ %{_prefix}/bin/%{gcc_target_arch}-g++
%if %{suse_version} < 1600
%{_prefix}/bin/%{gcc_target_arch}-c++%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-g++%{binsuffix}
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-c++ %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-c++
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-g++ %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-g++
%endif
%if 0%{!?gcc_libc_bootstrap:1} %if 0%{!?gcc_libc_bootstrap:1}
%if "%{cross_arch}" == "avr" || 0%{?gcc_target_newlib:1} || 0%{?gcc_target_glibc:1} %if "%{cross_arch}" == "avr" || 0%{?gcc_target_newlib:1} || 0%{?gcc_target_glibc:1}
%{_prefix}/include/c++ %{_prefix}/include/c++

View File

@@ -293,26 +293,24 @@ ExclusiveArch: i586 ppc64le ppc64 x86_64 s390x aarch64
%if "%pkgname" == "cross-ppc64-gcc49" %if "%pkgname" == "cross-ppc64-gcc49"
Obsoletes: cross-ppc-gcc49 <= 4.9.0+r209354 Obsoletes: cross-ppc-gcc49 <= 4.9.0+r209354
%endif %endif
%if 0%{?gcc_target_newlib:1}%{?gcc_target_glibc:1} || "%{cross_arch}" == "avr" %if 0%{!?gcc_accel:1}
# Generally only one cross for the same target triplet can be installed # Generally only one cross for the same target triplet can be installed
# at the same time as we are populating a non-version-specific sysroot # at the same time as we are populating a non-version-specific sysroot
Provides: %{gcc_target_arch}-gcc
Conflicts: %selfconflict %{gcc_target_arch}-gcc
%endif
%if 0%{?gcc_libc_bootstrap:1}
# The -bootstrap packages file-conflict with the non-bootstrap variants. # The -bootstrap packages file-conflict with the non-bootstrap variants.
# Even if we don't actually (want to) distribute the bootstrap variants # Even if we don't actually (want to) distribute the bootstrap variants
# the following avoids repo-checker spamming us endlessly. # the following avoids repo-checker spamming us endlessly.
Provides: %{gcc_target_arch}-gcc
Conflicts: %{gcc_target_arch}-gcc Conflicts: %{gcc_target_arch}-gcc
Conflicts: %{pkgname}-bootstrap
%endif %endif
#!BuildIgnore: gcc-PIE #!BuildIgnore: gcc-PIE
%if 0%{build_cp:1} %if %{build_cp}
# The cross compiler only packages the arch specific c++ headers, so # The cross compiler only packages the arch specific c++ headers, so
# we need to depend on the host libstdc++ devel headers (we wouldn't need # we need to depend on the host libstdc++ devel headers (we wouldn't need
# the libs, though) # the libs, though)
Requires: libstdc++6-devel-gcc13 Requires: libstdc++6-devel-gcc13
%endif %endif
%if 0%{!?gcc_accel:1} %if 0%{!?gcc_accel:1} && %{suse_version} < 1600
BuildRequires: update-alternatives BuildRequires: update-alternatives
Requires(post): update-alternatives Requires(post): update-alternatives
Requires(preun): update-alternatives Requires(preun): update-alternatives
@@ -588,11 +586,11 @@ amdgcn-amdhsa,\
--enable-gnu-indirect-function \ --enable-gnu-indirect-function \
%endif %endif
%endif %endif
--program-suffix=%{binsuffix} \
%ifarch %{disable_multilib_arch} %ifarch %{disable_multilib_arch}
--disable-multilib \ --disable-multilib \
%endif %endif
%if 0%{!?gcc_target_arch:1} %if 0%{!?gcc_target_arch:1}
--program-suffix=%{binsuffix} \
%ifarch ia64 %ifarch ia64
--with-system-libunwind \ --with-system-libunwind \
%else %else
@@ -600,6 +598,9 @@ amdgcn-amdhsa,\
%endif %endif
%endif %endif
%if 0%{?gcc_target_arch:1} %if 0%{?gcc_target_arch:1}
%if 0%{?gcc_accel:1} || %{suse_version} < 1600
--program-suffix=%{binsuffix} \
%endif
--program-prefix=%{gcc_target_arch}- \ --program-prefix=%{gcc_target_arch}- \
--target=%{gcc_target_arch} \ --target=%{gcc_target_arch} \
--disable-nls \ --disable-nls \
@@ -687,7 +688,7 @@ amdgcn-amdhsa,\
%endif %endif
%if %{suse_version} >= 1600 && !0%{?is_opensuse} %if %{suse_version} >= 1600 && !0%{?is_opensuse}
--with-cpu=power9 \ --with-cpu=power9 \
--with-tune=power9 \ --with-tune=power10 \
%else %else
%if %{suse_version} >= 1350 %if %{suse_version} >= 1350
--with-cpu=power8 \ --with-cpu=power8 \
@@ -756,7 +757,7 @@ amdgcn-amdhsa,\
%endif %endif
%if "%{TARGET_ARCH}" == "s390" || "%{TARGET_ARCH}" == "s390x" %if "%{TARGET_ARCH}" == "s390" || "%{TARGET_ARCH}" == "s390x"
%if %{suse_version} >= 1600 && !0%{?is_opensuse} %if %{suse_version} >= 1600 && !0%{?is_opensuse}
--with-tune=z14 --with-arch=z14 \ --with-tune=z15 --with-arch=z14 \
%else %else
%if %{suse_version} >= 1310 %if %{suse_version} >= 1310
--with-tune=zEC12 --with-arch=z196 \ --with-tune=zEC12 --with-arch=z196 \
@@ -862,7 +863,7 @@ rm -f $RPM_BUILD_ROOT%{_libdir}/libiberty.a
mkdir -p $RPM_BUILD_ROOT/%{?sysroot:%sysroot} mkdir -p $RPM_BUILD_ROOT/%{?sysroot:%sysroot}
make DESTDIR=$RPM_BUILD_ROOT install-target make DESTDIR=$RPM_BUILD_ROOT install-target
%if %{build_cp} %if %{build_cp}
# So we installed libstdc++ headers into %prefix where they conflict # So we installed libstdc++ headers into %%prefix where they conflict
# with other host compilers. Rip out the non-target specific parts # with other host compilers. Rip out the non-target specific parts
# again. Note not all cross targets support libstdc++, so create the # again. Note not all cross targets support libstdc++, so create the
# directory to make things easier. # directory to make things easier.
@@ -887,6 +888,7 @@ rm -rf $RPM_BUILD_ROOT%{_infodir}
# for accelerators remove all frontends but lto1 and also install-tools # for accelerators remove all frontends but lto1 and also install-tools
%if 0%{?gcc_accel:1} %if 0%{?gcc_accel:1}
rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1 rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1
rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/f951
rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1plus rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1plus
rm -rf $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/install-tools rm -rf $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/install-tools
rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}/install-tools rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}/install-tools
@@ -894,6 +896,8 @@ rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}/install-tools
# that is the place where we later search for (only) # that is the place where we later search for (only)
( cd $RPM_BUILD_ROOT%{targetlibsubdir} && tar cf - . ) | ( cd $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch} && tar xf - ) ( cd $RPM_BUILD_ROOT%{targetlibsubdir} && tar cf - . ) | ( cd $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch} && tar xf - )
rm -rf $RPM_BUILD_ROOT%{targetlibsubdir} rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}
# also remove installed libstdc++ headers
rm -rf $RPM_BUILD_ROOT%{_prefix}/include/c++
%endif %endif
# for amdgcn install the symlinks to the llvm tools # for amdgcn install the symlinks to the llvm tools
# follow alternatives symlinks to the hardcoded version requirement # follow alternatives symlinks to the hardcoded version requirement
@@ -958,7 +962,7 @@ rm -r env
# we provide update-alternatives for selecting a compiler version for # we provide update-alternatives for selecting a compiler version for
# crosses # crosses
%if 0%{!?gcc_accel:1} %if 0%{!?gcc_accel:1} && %{suse_version} < 1600
mkdir -p %{buildroot}%{_sysconfdir}/alternatives mkdir -p %{buildroot}%{_sysconfdir}/alternatives
for ex in gcc cpp \ for ex in gcc cpp \
%if %{build_cp} %if %{build_cp}
@@ -1014,15 +1018,19 @@ fi
%endif %endif
%else %else
%{_prefix}/bin/%{gcc_target_arch}-gcc%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc%{binsuffix}
%if %{suse_version} < 1600
%{_prefix}/bin/%{gcc_target_arch}-cpp%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-cpp%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcc-ar%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc-ar%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcc-nm%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc-nm%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-lto-dump%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-lto-dump%{binsuffix}
%endif
%if 0%{!?gcc_libc_bootstrap:1} && "%{cross_arch}" != "bpf" %if 0%{!?gcc_libc_bootstrap:1} && "%{cross_arch}" != "bpf"
%if %{suse_version} < 1600
%{_prefix}/bin/%{gcc_target_arch}-gcov%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcov%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcov-dump%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcov-dump%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcov-tool%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcov-tool%{binsuffix}
%endif
%{_prefix}/bin/%{gcc_target_arch}-gcov %{_prefix}/bin/%{gcc_target_arch}-gcov
%{_prefix}/bin/%{gcc_target_arch}-gcov-dump %{_prefix}/bin/%{gcc_target_arch}-gcov-dump
%{_prefix}/bin/%{gcc_target_arch}-gcov-tool %{_prefix}/bin/%{gcc_target_arch}-gcov-tool
@@ -1033,6 +1041,7 @@ fi
%{_prefix}/bin/%{gcc_target_arch}-gcc-nm %{_prefix}/bin/%{gcc_target_arch}-gcc-nm
%{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib %{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib
%{_prefix}/bin/%{gcc_target_arch}-lto-dump %{_prefix}/bin/%{gcc_target_arch}-lto-dump
%if %{suse_version} < 1600
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-cpp %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-cpp
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc-ar %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc-ar
@@ -1044,13 +1053,16 @@ fi
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-dump %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-dump
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-tool %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-tool
%endif %endif
%endif
%if %{build_cp} %if %{build_cp}
%{_prefix}/bin/%{gcc_target_arch}-c++%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-g++%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-c++ %{_prefix}/bin/%{gcc_target_arch}-c++
%{_prefix}/bin/%{gcc_target_arch}-g++ %{_prefix}/bin/%{gcc_target_arch}-g++
%if %{suse_version} < 1600
%{_prefix}/bin/%{gcc_target_arch}-c++%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-g++%{binsuffix}
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-c++ %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-c++
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-g++ %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-g++
%endif
%if 0%{!?gcc_libc_bootstrap:1} %if 0%{!?gcc_libc_bootstrap:1}
%if "%{cross_arch}" == "avr" || 0%{?gcc_target_newlib:1} || 0%{?gcc_target_glibc:1} %if "%{cross_arch}" == "avr" || 0%{?gcc_target_newlib:1} || 0%{?gcc_target_glibc:1}
%{_prefix}/include/c++ %{_prefix}/include/c++

View File

@@ -292,26 +292,24 @@ ExclusiveArch: i586 ppc64le ppc64 x86_64 s390x aarch64
%if "%pkgname" == "cross-ppc64-gcc49" %if "%pkgname" == "cross-ppc64-gcc49"
Obsoletes: cross-ppc-gcc49 <= 4.9.0+r209354 Obsoletes: cross-ppc-gcc49 <= 4.9.0+r209354
%endif %endif
%if 0%{?gcc_target_newlib:1}%{?gcc_target_glibc:1} || "%{cross_arch}" == "avr" %if 0%{!?gcc_accel:1}
# Generally only one cross for the same target triplet can be installed # Generally only one cross for the same target triplet can be installed
# at the same time as we are populating a non-version-specific sysroot # at the same time as we are populating a non-version-specific sysroot
Provides: %{gcc_target_arch}-gcc
Conflicts: %selfconflict %{gcc_target_arch}-gcc
%endif
%if 0%{?gcc_libc_bootstrap:1}
# The -bootstrap packages file-conflict with the non-bootstrap variants. # The -bootstrap packages file-conflict with the non-bootstrap variants.
# Even if we don't actually (want to) distribute the bootstrap variants # Even if we don't actually (want to) distribute the bootstrap variants
# the following avoids repo-checker spamming us endlessly. # the following avoids repo-checker spamming us endlessly.
Provides: %{gcc_target_arch}-gcc
Conflicts: %{gcc_target_arch}-gcc Conflicts: %{gcc_target_arch}-gcc
Conflicts: %{pkgname}-bootstrap
%endif %endif
#!BuildIgnore: gcc-PIE #!BuildIgnore: gcc-PIE
%if 0%{build_cp:1} %if %{build_cp}
# The cross compiler only packages the arch specific c++ headers, so # The cross compiler only packages the arch specific c++ headers, so
# we need to depend on the host libstdc++ devel headers (we wouldn't need # we need to depend on the host libstdc++ devel headers (we wouldn't need
# the libs, though) # the libs, though)
Requires: libstdc++6-devel-gcc13 Requires: libstdc++6-devel-gcc13
%endif %endif
%if 0%{!?gcc_accel:1} %if 0%{!?gcc_accel:1} && %{suse_version} < 1600
BuildRequires: update-alternatives BuildRequires: update-alternatives
Requires(post): update-alternatives Requires(post): update-alternatives
Requires(preun): update-alternatives Requires(preun): update-alternatives
@@ -587,11 +585,11 @@ amdgcn-amdhsa,\
--enable-gnu-indirect-function \ --enable-gnu-indirect-function \
%endif %endif
%endif %endif
--program-suffix=%{binsuffix} \
%ifarch %{disable_multilib_arch} %ifarch %{disable_multilib_arch}
--disable-multilib \ --disable-multilib \
%endif %endif
%if 0%{!?gcc_target_arch:1} %if 0%{!?gcc_target_arch:1}
--program-suffix=%{binsuffix} \
%ifarch ia64 %ifarch ia64
--with-system-libunwind \ --with-system-libunwind \
%else %else
@@ -599,6 +597,9 @@ amdgcn-amdhsa,\
%endif %endif
%endif %endif
%if 0%{?gcc_target_arch:1} %if 0%{?gcc_target_arch:1}
%if 0%{?gcc_accel:1} || %{suse_version} < 1600
--program-suffix=%{binsuffix} \
%endif
--program-prefix=%{gcc_target_arch}- \ --program-prefix=%{gcc_target_arch}- \
--target=%{gcc_target_arch} \ --target=%{gcc_target_arch} \
--disable-nls \ --disable-nls \
@@ -686,7 +687,7 @@ amdgcn-amdhsa,\
%endif %endif
%if %{suse_version} >= 1600 && !0%{?is_opensuse} %if %{suse_version} >= 1600 && !0%{?is_opensuse}
--with-cpu=power9 \ --with-cpu=power9 \
--with-tune=power9 \ --with-tune=power10 \
%else %else
%if %{suse_version} >= 1350 %if %{suse_version} >= 1350
--with-cpu=power8 \ --with-cpu=power8 \
@@ -755,7 +756,7 @@ amdgcn-amdhsa,\
%endif %endif
%if "%{TARGET_ARCH}" == "s390" || "%{TARGET_ARCH}" == "s390x" %if "%{TARGET_ARCH}" == "s390" || "%{TARGET_ARCH}" == "s390x"
%if %{suse_version} >= 1600 && !0%{?is_opensuse} %if %{suse_version} >= 1600 && !0%{?is_opensuse}
--with-tune=z14 --with-arch=z14 \ --with-tune=z15 --with-arch=z14 \
%else %else
%if %{suse_version} >= 1310 %if %{suse_version} >= 1310
--with-tune=zEC12 --with-arch=z196 \ --with-tune=zEC12 --with-arch=z196 \
@@ -861,7 +862,7 @@ rm -f $RPM_BUILD_ROOT%{_libdir}/libiberty.a
mkdir -p $RPM_BUILD_ROOT/%{?sysroot:%sysroot} mkdir -p $RPM_BUILD_ROOT/%{?sysroot:%sysroot}
make DESTDIR=$RPM_BUILD_ROOT install-target make DESTDIR=$RPM_BUILD_ROOT install-target
%if %{build_cp} %if %{build_cp}
# So we installed libstdc++ headers into %prefix where they conflict # So we installed libstdc++ headers into %%prefix where they conflict
# with other host compilers. Rip out the non-target specific parts # with other host compilers. Rip out the non-target specific parts
# again. Note not all cross targets support libstdc++, so create the # again. Note not all cross targets support libstdc++, so create the
# directory to make things easier. # directory to make things easier.
@@ -886,6 +887,7 @@ rm -rf $RPM_BUILD_ROOT%{_infodir}
# for accelerators remove all frontends but lto1 and also install-tools # for accelerators remove all frontends but lto1 and also install-tools
%if 0%{?gcc_accel:1} %if 0%{?gcc_accel:1}
rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1 rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1
rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/f951
rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1plus rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1plus
rm -rf $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/install-tools rm -rf $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/install-tools
rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}/install-tools rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}/install-tools
@@ -893,6 +895,8 @@ rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}/install-tools
# that is the place where we later search for (only) # that is the place where we later search for (only)
( cd $RPM_BUILD_ROOT%{targetlibsubdir} && tar cf - . ) | ( cd $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch} && tar xf - ) ( cd $RPM_BUILD_ROOT%{targetlibsubdir} && tar cf - . ) | ( cd $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch} && tar xf - )
rm -rf $RPM_BUILD_ROOT%{targetlibsubdir} rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}
# also remove installed libstdc++ headers
rm -rf $RPM_BUILD_ROOT%{_prefix}/include/c++
%endif %endif
# for amdgcn install the symlinks to the llvm tools # for amdgcn install the symlinks to the llvm tools
# follow alternatives symlinks to the hardcoded version requirement # follow alternatives symlinks to the hardcoded version requirement
@@ -957,7 +961,7 @@ rm -r env
# we provide update-alternatives for selecting a compiler version for # we provide update-alternatives for selecting a compiler version for
# crosses # crosses
%if 0%{!?gcc_accel:1} %if 0%{!?gcc_accel:1} && %{suse_version} < 1600
mkdir -p %{buildroot}%{_sysconfdir}/alternatives mkdir -p %{buildroot}%{_sysconfdir}/alternatives
for ex in gcc cpp \ for ex in gcc cpp \
%if %{build_cp} %if %{build_cp}
@@ -1013,15 +1017,19 @@ fi
%endif %endif
%else %else
%{_prefix}/bin/%{gcc_target_arch}-gcc%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc%{binsuffix}
%if %{suse_version} < 1600
%{_prefix}/bin/%{gcc_target_arch}-cpp%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-cpp%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcc-ar%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc-ar%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcc-nm%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc-nm%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-lto-dump%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-lto-dump%{binsuffix}
%endif
%if 0%{!?gcc_libc_bootstrap:1} && "%{cross_arch}" != "bpf" %if 0%{!?gcc_libc_bootstrap:1} && "%{cross_arch}" != "bpf"
%if %{suse_version} < 1600
%{_prefix}/bin/%{gcc_target_arch}-gcov%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcov%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcov-dump%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcov-dump%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcov-tool%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcov-tool%{binsuffix}
%endif
%{_prefix}/bin/%{gcc_target_arch}-gcov %{_prefix}/bin/%{gcc_target_arch}-gcov
%{_prefix}/bin/%{gcc_target_arch}-gcov-dump %{_prefix}/bin/%{gcc_target_arch}-gcov-dump
%{_prefix}/bin/%{gcc_target_arch}-gcov-tool %{_prefix}/bin/%{gcc_target_arch}-gcov-tool
@@ -1032,6 +1040,7 @@ fi
%{_prefix}/bin/%{gcc_target_arch}-gcc-nm %{_prefix}/bin/%{gcc_target_arch}-gcc-nm
%{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib %{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib
%{_prefix}/bin/%{gcc_target_arch}-lto-dump %{_prefix}/bin/%{gcc_target_arch}-lto-dump
%if %{suse_version} < 1600
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-cpp %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-cpp
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc-ar %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc-ar
@@ -1043,13 +1052,16 @@ fi
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-dump %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-dump
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-tool %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-tool
%endif %endif
%endif
%if %{build_cp} %if %{build_cp}
%{_prefix}/bin/%{gcc_target_arch}-c++%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-g++%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-c++ %{_prefix}/bin/%{gcc_target_arch}-c++
%{_prefix}/bin/%{gcc_target_arch}-g++ %{_prefix}/bin/%{gcc_target_arch}-g++
%if %{suse_version} < 1600
%{_prefix}/bin/%{gcc_target_arch}-c++%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-g++%{binsuffix}
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-c++ %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-c++
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-g++ %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-g++
%endif
%if 0%{!?gcc_libc_bootstrap:1} %if 0%{!?gcc_libc_bootstrap:1}
%if "%{cross_arch}" == "avr" || 0%{?gcc_target_newlib:1} || 0%{?gcc_target_glibc:1} %if "%{cross_arch}" == "avr" || 0%{?gcc_target_newlib:1} || 0%{?gcc_target_glibc:1}
%{_prefix}/include/c++ %{_prefix}/include/c++

View File

@@ -19,6 +19,7 @@
%define pkgname cross-riscv64-gcc13-bootstrap %define pkgname cross-riscv64-gcc13-bootstrap
%define cross_arch riscv64 %define cross_arch riscv64
%define gcc_target_arch riscv64-suse-linux %define gcc_target_arch riscv64-suse-linux
%define gcc_target_glibc 1
%define gcc_libc_bootstrap 1 %define gcc_libc_bootstrap 1
# nospeccleaner # nospeccleaner
@@ -292,26 +293,24 @@ ExclusiveArch: i586 ppc64le ppc64 x86_64 s390x aarch64
%if "%pkgname" == "cross-ppc64-gcc49" %if "%pkgname" == "cross-ppc64-gcc49"
Obsoletes: cross-ppc-gcc49 <= 4.9.0+r209354 Obsoletes: cross-ppc-gcc49 <= 4.9.0+r209354
%endif %endif
%if 0%{?gcc_target_newlib:1}%{?gcc_target_glibc:1} || "%{cross_arch}" == "avr" %if 0%{!?gcc_accel:1}
# Generally only one cross for the same target triplet can be installed # Generally only one cross for the same target triplet can be installed
# at the same time as we are populating a non-version-specific sysroot # at the same time as we are populating a non-version-specific sysroot
Provides: %{gcc_target_arch}-gcc
Conflicts: %selfconflict %{gcc_target_arch}-gcc
%endif
%if 0%{?gcc_libc_bootstrap:1}
# The -bootstrap packages file-conflict with the non-bootstrap variants. # The -bootstrap packages file-conflict with the non-bootstrap variants.
# Even if we don't actually (want to) distribute the bootstrap variants # Even if we don't actually (want to) distribute the bootstrap variants
# the following avoids repo-checker spamming us endlessly. # the following avoids repo-checker spamming us endlessly.
Provides: %{gcc_target_arch}-gcc
Conflicts: %{gcc_target_arch}-gcc Conflicts: %{gcc_target_arch}-gcc
Conflicts: %{pkgname}-bootstrap
%endif %endif
#!BuildIgnore: gcc-PIE #!BuildIgnore: gcc-PIE
%if 0%{build_cp:1} %if %{build_cp}
# The cross compiler only packages the arch specific c++ headers, so # The cross compiler only packages the arch specific c++ headers, so
# we need to depend on the host libstdc++ devel headers (we wouldn't need # we need to depend on the host libstdc++ devel headers (we wouldn't need
# the libs, though) # the libs, though)
Requires: libstdc++6-devel-gcc13 Requires: libstdc++6-devel-gcc13
%endif %endif
%if 0%{!?gcc_accel:1} %if 0%{!?gcc_accel:1} && %{suse_version} < 1600
BuildRequires: update-alternatives BuildRequires: update-alternatives
Requires(post): update-alternatives Requires(post): update-alternatives
Requires(preun): update-alternatives Requires(preun): update-alternatives
@@ -587,11 +586,11 @@ amdgcn-amdhsa,\
--enable-gnu-indirect-function \ --enable-gnu-indirect-function \
%endif %endif
%endif %endif
--program-suffix=%{binsuffix} \
%ifarch %{disable_multilib_arch} %ifarch %{disable_multilib_arch}
--disable-multilib \ --disable-multilib \
%endif %endif
%if 0%{!?gcc_target_arch:1} %if 0%{!?gcc_target_arch:1}
--program-suffix=%{binsuffix} \
%ifarch ia64 %ifarch ia64
--with-system-libunwind \ --with-system-libunwind \
%else %else
@@ -599,6 +598,9 @@ amdgcn-amdhsa,\
%endif %endif
%endif %endif
%if 0%{?gcc_target_arch:1} %if 0%{?gcc_target_arch:1}
%if 0%{?gcc_accel:1} || %{suse_version} < 1600
--program-suffix=%{binsuffix} \
%endif
--program-prefix=%{gcc_target_arch}- \ --program-prefix=%{gcc_target_arch}- \
--target=%{gcc_target_arch} \ --target=%{gcc_target_arch} \
--disable-nls \ --disable-nls \
@@ -686,7 +688,7 @@ amdgcn-amdhsa,\
%endif %endif
%if %{suse_version} >= 1600 && !0%{?is_opensuse} %if %{suse_version} >= 1600 && !0%{?is_opensuse}
--with-cpu=power9 \ --with-cpu=power9 \
--with-tune=power9 \ --with-tune=power10 \
%else %else
%if %{suse_version} >= 1350 %if %{suse_version} >= 1350
--with-cpu=power8 \ --with-cpu=power8 \
@@ -755,7 +757,7 @@ amdgcn-amdhsa,\
%endif %endif
%if "%{TARGET_ARCH}" == "s390" || "%{TARGET_ARCH}" == "s390x" %if "%{TARGET_ARCH}" == "s390" || "%{TARGET_ARCH}" == "s390x"
%if %{suse_version} >= 1600 && !0%{?is_opensuse} %if %{suse_version} >= 1600 && !0%{?is_opensuse}
--with-tune=z14 --with-arch=z14 \ --with-tune=z15 --with-arch=z14 \
%else %else
%if %{suse_version} >= 1310 %if %{suse_version} >= 1310
--with-tune=zEC12 --with-arch=z196 \ --with-tune=zEC12 --with-arch=z196 \
@@ -861,7 +863,7 @@ rm -f $RPM_BUILD_ROOT%{_libdir}/libiberty.a
mkdir -p $RPM_BUILD_ROOT/%{?sysroot:%sysroot} mkdir -p $RPM_BUILD_ROOT/%{?sysroot:%sysroot}
make DESTDIR=$RPM_BUILD_ROOT install-target make DESTDIR=$RPM_BUILD_ROOT install-target
%if %{build_cp} %if %{build_cp}
# So we installed libstdc++ headers into %prefix where they conflict # So we installed libstdc++ headers into %%prefix where they conflict
# with other host compilers. Rip out the non-target specific parts # with other host compilers. Rip out the non-target specific parts
# again. Note not all cross targets support libstdc++, so create the # again. Note not all cross targets support libstdc++, so create the
# directory to make things easier. # directory to make things easier.
@@ -886,6 +888,7 @@ rm -rf $RPM_BUILD_ROOT%{_infodir}
# for accelerators remove all frontends but lto1 and also install-tools # for accelerators remove all frontends but lto1 and also install-tools
%if 0%{?gcc_accel:1} %if 0%{?gcc_accel:1}
rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1 rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1
rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/f951
rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1plus rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1plus
rm -rf $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/install-tools rm -rf $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/install-tools
rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}/install-tools rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}/install-tools
@@ -893,6 +896,8 @@ rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}/install-tools
# that is the place where we later search for (only) # that is the place where we later search for (only)
( cd $RPM_BUILD_ROOT%{targetlibsubdir} && tar cf - . ) | ( cd $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch} && tar xf - ) ( cd $RPM_BUILD_ROOT%{targetlibsubdir} && tar cf - . ) | ( cd $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch} && tar xf - )
rm -rf $RPM_BUILD_ROOT%{targetlibsubdir} rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}
# also remove installed libstdc++ headers
rm -rf $RPM_BUILD_ROOT%{_prefix}/include/c++
%endif %endif
# for amdgcn install the symlinks to the llvm tools # for amdgcn install the symlinks to the llvm tools
# follow alternatives symlinks to the hardcoded version requirement # follow alternatives symlinks to the hardcoded version requirement
@@ -957,7 +962,7 @@ rm -r env
# we provide update-alternatives for selecting a compiler version for # we provide update-alternatives for selecting a compiler version for
# crosses # crosses
%if 0%{!?gcc_accel:1} %if 0%{!?gcc_accel:1} && %{suse_version} < 1600
mkdir -p %{buildroot}%{_sysconfdir}/alternatives mkdir -p %{buildroot}%{_sysconfdir}/alternatives
for ex in gcc cpp \ for ex in gcc cpp \
%if %{build_cp} %if %{build_cp}
@@ -1013,15 +1018,19 @@ fi
%endif %endif
%else %else
%{_prefix}/bin/%{gcc_target_arch}-gcc%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc%{binsuffix}
%if %{suse_version} < 1600
%{_prefix}/bin/%{gcc_target_arch}-cpp%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-cpp%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcc-ar%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc-ar%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcc-nm%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc-nm%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-lto-dump%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-lto-dump%{binsuffix}
%endif
%if 0%{!?gcc_libc_bootstrap:1} && "%{cross_arch}" != "bpf" %if 0%{!?gcc_libc_bootstrap:1} && "%{cross_arch}" != "bpf"
%if %{suse_version} < 1600
%{_prefix}/bin/%{gcc_target_arch}-gcov%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcov%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcov-dump%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcov-dump%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcov-tool%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcov-tool%{binsuffix}
%endif
%{_prefix}/bin/%{gcc_target_arch}-gcov %{_prefix}/bin/%{gcc_target_arch}-gcov
%{_prefix}/bin/%{gcc_target_arch}-gcov-dump %{_prefix}/bin/%{gcc_target_arch}-gcov-dump
%{_prefix}/bin/%{gcc_target_arch}-gcov-tool %{_prefix}/bin/%{gcc_target_arch}-gcov-tool
@@ -1032,6 +1041,7 @@ fi
%{_prefix}/bin/%{gcc_target_arch}-gcc-nm %{_prefix}/bin/%{gcc_target_arch}-gcc-nm
%{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib %{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib
%{_prefix}/bin/%{gcc_target_arch}-lto-dump %{_prefix}/bin/%{gcc_target_arch}-lto-dump
%if %{suse_version} < 1600
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-cpp %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-cpp
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc-ar %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc-ar
@@ -1043,13 +1053,16 @@ fi
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-dump %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-dump
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-tool %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-tool
%endif %endif
%endif
%if %{build_cp} %if %{build_cp}
%{_prefix}/bin/%{gcc_target_arch}-c++%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-g++%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-c++ %{_prefix}/bin/%{gcc_target_arch}-c++
%{_prefix}/bin/%{gcc_target_arch}-g++ %{_prefix}/bin/%{gcc_target_arch}-g++
%if %{suse_version} < 1600
%{_prefix}/bin/%{gcc_target_arch}-c++%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-g++%{binsuffix}
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-c++ %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-c++
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-g++ %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-g++
%endif
%if 0%{!?gcc_libc_bootstrap:1} %if 0%{!?gcc_libc_bootstrap:1}
%if "%{cross_arch}" == "avr" || 0%{?gcc_target_newlib:1} || 0%{?gcc_target_glibc:1} %if "%{cross_arch}" == "avr" || 0%{?gcc_target_newlib:1} || 0%{?gcc_target_glibc:1}
%{_prefix}/include/c++ %{_prefix}/include/c++

View File

@@ -292,26 +292,24 @@ ExclusiveArch: i586 ppc64le ppc64 x86_64 s390x aarch64
%if "%pkgname" == "cross-ppc64-gcc49" %if "%pkgname" == "cross-ppc64-gcc49"
Obsoletes: cross-ppc-gcc49 <= 4.9.0+r209354 Obsoletes: cross-ppc-gcc49 <= 4.9.0+r209354
%endif %endif
%if 0%{?gcc_target_newlib:1}%{?gcc_target_glibc:1} || "%{cross_arch}" == "avr" %if 0%{!?gcc_accel:1}
# Generally only one cross for the same target triplet can be installed # Generally only one cross for the same target triplet can be installed
# at the same time as we are populating a non-version-specific sysroot # at the same time as we are populating a non-version-specific sysroot
Provides: %{gcc_target_arch}-gcc
Conflicts: %selfconflict %{gcc_target_arch}-gcc
%endif
%if 0%{?gcc_libc_bootstrap:1}
# The -bootstrap packages file-conflict with the non-bootstrap variants. # The -bootstrap packages file-conflict with the non-bootstrap variants.
# Even if we don't actually (want to) distribute the bootstrap variants # Even if we don't actually (want to) distribute the bootstrap variants
# the following avoids repo-checker spamming us endlessly. # the following avoids repo-checker spamming us endlessly.
Provides: %{gcc_target_arch}-gcc
Conflicts: %{gcc_target_arch}-gcc Conflicts: %{gcc_target_arch}-gcc
Conflicts: %{pkgname}-bootstrap
%endif %endif
#!BuildIgnore: gcc-PIE #!BuildIgnore: gcc-PIE
%if 0%{build_cp:1} %if %{build_cp}
# The cross compiler only packages the arch specific c++ headers, so # The cross compiler only packages the arch specific c++ headers, so
# we need to depend on the host libstdc++ devel headers (we wouldn't need # we need to depend on the host libstdc++ devel headers (we wouldn't need
# the libs, though) # the libs, though)
Requires: libstdc++6-devel-gcc13 Requires: libstdc++6-devel-gcc13
%endif %endif
%if 0%{!?gcc_accel:1} %if 0%{!?gcc_accel:1} && %{suse_version} < 1600
BuildRequires: update-alternatives BuildRequires: update-alternatives
Requires(post): update-alternatives Requires(post): update-alternatives
Requires(preun): update-alternatives Requires(preun): update-alternatives
@@ -587,11 +585,11 @@ amdgcn-amdhsa,\
--enable-gnu-indirect-function \ --enable-gnu-indirect-function \
%endif %endif
%endif %endif
--program-suffix=%{binsuffix} \
%ifarch %{disable_multilib_arch} %ifarch %{disable_multilib_arch}
--disable-multilib \ --disable-multilib \
%endif %endif
%if 0%{!?gcc_target_arch:1} %if 0%{!?gcc_target_arch:1}
--program-suffix=%{binsuffix} \
%ifarch ia64 %ifarch ia64
--with-system-libunwind \ --with-system-libunwind \
%else %else
@@ -599,6 +597,9 @@ amdgcn-amdhsa,\
%endif %endif
%endif %endif
%if 0%{?gcc_target_arch:1} %if 0%{?gcc_target_arch:1}
%if 0%{?gcc_accel:1} || %{suse_version} < 1600
--program-suffix=%{binsuffix} \
%endif
--program-prefix=%{gcc_target_arch}- \ --program-prefix=%{gcc_target_arch}- \
--target=%{gcc_target_arch} \ --target=%{gcc_target_arch} \
--disable-nls \ --disable-nls \
@@ -686,7 +687,7 @@ amdgcn-amdhsa,\
%endif %endif
%if %{suse_version} >= 1600 && !0%{?is_opensuse} %if %{suse_version} >= 1600 && !0%{?is_opensuse}
--with-cpu=power9 \ --with-cpu=power9 \
--with-tune=power9 \ --with-tune=power10 \
%else %else
%if %{suse_version} >= 1350 %if %{suse_version} >= 1350
--with-cpu=power8 \ --with-cpu=power8 \
@@ -755,7 +756,7 @@ amdgcn-amdhsa,\
%endif %endif
%if "%{TARGET_ARCH}" == "s390" || "%{TARGET_ARCH}" == "s390x" %if "%{TARGET_ARCH}" == "s390" || "%{TARGET_ARCH}" == "s390x"
%if %{suse_version} >= 1600 && !0%{?is_opensuse} %if %{suse_version} >= 1600 && !0%{?is_opensuse}
--with-tune=z14 --with-arch=z14 \ --with-tune=z15 --with-arch=z14 \
%else %else
%if %{suse_version} >= 1310 %if %{suse_version} >= 1310
--with-tune=zEC12 --with-arch=z196 \ --with-tune=zEC12 --with-arch=z196 \
@@ -861,7 +862,7 @@ rm -f $RPM_BUILD_ROOT%{_libdir}/libiberty.a
mkdir -p $RPM_BUILD_ROOT/%{?sysroot:%sysroot} mkdir -p $RPM_BUILD_ROOT/%{?sysroot:%sysroot}
make DESTDIR=$RPM_BUILD_ROOT install-target make DESTDIR=$RPM_BUILD_ROOT install-target
%if %{build_cp} %if %{build_cp}
# So we installed libstdc++ headers into %prefix where they conflict # So we installed libstdc++ headers into %%prefix where they conflict
# with other host compilers. Rip out the non-target specific parts # with other host compilers. Rip out the non-target specific parts
# again. Note not all cross targets support libstdc++, so create the # again. Note not all cross targets support libstdc++, so create the
# directory to make things easier. # directory to make things easier.
@@ -886,6 +887,7 @@ rm -rf $RPM_BUILD_ROOT%{_infodir}
# for accelerators remove all frontends but lto1 and also install-tools # for accelerators remove all frontends but lto1 and also install-tools
%if 0%{?gcc_accel:1} %if 0%{?gcc_accel:1}
rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1 rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1
rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/f951
rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1plus rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1plus
rm -rf $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/install-tools rm -rf $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/install-tools
rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}/install-tools rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}/install-tools
@@ -893,6 +895,8 @@ rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}/install-tools
# that is the place where we later search for (only) # that is the place where we later search for (only)
( cd $RPM_BUILD_ROOT%{targetlibsubdir} && tar cf - . ) | ( cd $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch} && tar xf - ) ( cd $RPM_BUILD_ROOT%{targetlibsubdir} && tar cf - . ) | ( cd $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch} && tar xf - )
rm -rf $RPM_BUILD_ROOT%{targetlibsubdir} rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}
# also remove installed libstdc++ headers
rm -rf $RPM_BUILD_ROOT%{_prefix}/include/c++
%endif %endif
# for amdgcn install the symlinks to the llvm tools # for amdgcn install the symlinks to the llvm tools
# follow alternatives symlinks to the hardcoded version requirement # follow alternatives symlinks to the hardcoded version requirement
@@ -957,7 +961,7 @@ rm -r env
# we provide update-alternatives for selecting a compiler version for # we provide update-alternatives for selecting a compiler version for
# crosses # crosses
%if 0%{!?gcc_accel:1} %if 0%{!?gcc_accel:1} && %{suse_version} < 1600
mkdir -p %{buildroot}%{_sysconfdir}/alternatives mkdir -p %{buildroot}%{_sysconfdir}/alternatives
for ex in gcc cpp \ for ex in gcc cpp \
%if %{build_cp} %if %{build_cp}
@@ -1013,15 +1017,19 @@ fi
%endif %endif
%else %else
%{_prefix}/bin/%{gcc_target_arch}-gcc%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc%{binsuffix}
%if %{suse_version} < 1600
%{_prefix}/bin/%{gcc_target_arch}-cpp%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-cpp%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcc-ar%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc-ar%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcc-nm%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc-nm%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-lto-dump%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-lto-dump%{binsuffix}
%endif
%if 0%{!?gcc_libc_bootstrap:1} && "%{cross_arch}" != "bpf" %if 0%{!?gcc_libc_bootstrap:1} && "%{cross_arch}" != "bpf"
%if %{suse_version} < 1600
%{_prefix}/bin/%{gcc_target_arch}-gcov%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcov%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcov-dump%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcov-dump%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcov-tool%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcov-tool%{binsuffix}
%endif
%{_prefix}/bin/%{gcc_target_arch}-gcov %{_prefix}/bin/%{gcc_target_arch}-gcov
%{_prefix}/bin/%{gcc_target_arch}-gcov-dump %{_prefix}/bin/%{gcc_target_arch}-gcov-dump
%{_prefix}/bin/%{gcc_target_arch}-gcov-tool %{_prefix}/bin/%{gcc_target_arch}-gcov-tool
@@ -1032,6 +1040,7 @@ fi
%{_prefix}/bin/%{gcc_target_arch}-gcc-nm %{_prefix}/bin/%{gcc_target_arch}-gcc-nm
%{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib %{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib
%{_prefix}/bin/%{gcc_target_arch}-lto-dump %{_prefix}/bin/%{gcc_target_arch}-lto-dump
%if %{suse_version} < 1600
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-cpp %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-cpp
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc-ar %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc-ar
@@ -1043,13 +1052,16 @@ fi
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-dump %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-dump
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-tool %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-tool
%endif %endif
%endif
%if %{build_cp} %if %{build_cp}
%{_prefix}/bin/%{gcc_target_arch}-c++%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-g++%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-c++ %{_prefix}/bin/%{gcc_target_arch}-c++
%{_prefix}/bin/%{gcc_target_arch}-g++ %{_prefix}/bin/%{gcc_target_arch}-g++
%if %{suse_version} < 1600
%{_prefix}/bin/%{gcc_target_arch}-c++%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-g++%{binsuffix}
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-c++ %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-c++
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-g++ %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-g++
%endif
%if 0%{!?gcc_libc_bootstrap:1} %if 0%{!?gcc_libc_bootstrap:1}
%if "%{cross_arch}" == "avr" || 0%{?gcc_target_newlib:1} || 0%{?gcc_target_glibc:1} %if "%{cross_arch}" == "avr" || 0%{?gcc_target_newlib:1} || 0%{?gcc_target_glibc:1}
%{_prefix}/include/c++ %{_prefix}/include/c++

View File

@@ -293,26 +293,24 @@ ExclusiveArch: i586 ppc64le ppc64 x86_64 s390x aarch64 riscv64
%if "%pkgname" == "cross-ppc64-gcc49" %if "%pkgname" == "cross-ppc64-gcc49"
Obsoletes: cross-ppc-gcc49 <= 4.9.0+r209354 Obsoletes: cross-ppc-gcc49 <= 4.9.0+r209354
%endif %endif
%if 0%{?gcc_target_newlib:1}%{?gcc_target_glibc:1} || "%{cross_arch}" == "avr" %if 0%{!?gcc_accel:1}
# Generally only one cross for the same target triplet can be installed # Generally only one cross for the same target triplet can be installed
# at the same time as we are populating a non-version-specific sysroot # at the same time as we are populating a non-version-specific sysroot
Provides: %{gcc_target_arch}-gcc
Conflicts: %selfconflict %{gcc_target_arch}-gcc
%endif
%if 0%{?gcc_libc_bootstrap:1}
# The -bootstrap packages file-conflict with the non-bootstrap variants. # The -bootstrap packages file-conflict with the non-bootstrap variants.
# Even if we don't actually (want to) distribute the bootstrap variants # Even if we don't actually (want to) distribute the bootstrap variants
# the following avoids repo-checker spamming us endlessly. # the following avoids repo-checker spamming us endlessly.
Provides: %{gcc_target_arch}-gcc
Conflicts: %{gcc_target_arch}-gcc Conflicts: %{gcc_target_arch}-gcc
Conflicts: %{pkgname}-bootstrap
%endif %endif
#!BuildIgnore: gcc-PIE #!BuildIgnore: gcc-PIE
%if 0%{build_cp:1} %if %{build_cp}
# The cross compiler only packages the arch specific c++ headers, so # The cross compiler only packages the arch specific c++ headers, so
# we need to depend on the host libstdc++ devel headers (we wouldn't need # we need to depend on the host libstdc++ devel headers (we wouldn't need
# the libs, though) # the libs, though)
Requires: libstdc++6-devel-gcc13 Requires: libstdc++6-devel-gcc13
%endif %endif
%if 0%{!?gcc_accel:1} %if 0%{!?gcc_accel:1} && %{suse_version} < 1600
BuildRequires: update-alternatives BuildRequires: update-alternatives
Requires(post): update-alternatives Requires(post): update-alternatives
Requires(preun): update-alternatives Requires(preun): update-alternatives
@@ -588,11 +586,11 @@ amdgcn-amdhsa,\
--enable-gnu-indirect-function \ --enable-gnu-indirect-function \
%endif %endif
%endif %endif
--program-suffix=%{binsuffix} \
%ifarch %{disable_multilib_arch} %ifarch %{disable_multilib_arch}
--disable-multilib \ --disable-multilib \
%endif %endif
%if 0%{!?gcc_target_arch:1} %if 0%{!?gcc_target_arch:1}
--program-suffix=%{binsuffix} \
%ifarch ia64 %ifarch ia64
--with-system-libunwind \ --with-system-libunwind \
%else %else
@@ -600,6 +598,9 @@ amdgcn-amdhsa,\
%endif %endif
%endif %endif
%if 0%{?gcc_target_arch:1} %if 0%{?gcc_target_arch:1}
%if 0%{?gcc_accel:1} || %{suse_version} < 1600
--program-suffix=%{binsuffix} \
%endif
--program-prefix=%{gcc_target_arch}- \ --program-prefix=%{gcc_target_arch}- \
--target=%{gcc_target_arch} \ --target=%{gcc_target_arch} \
--disable-nls \ --disable-nls \
@@ -687,7 +688,7 @@ amdgcn-amdhsa,\
%endif %endif
%if %{suse_version} >= 1600 && !0%{?is_opensuse} %if %{suse_version} >= 1600 && !0%{?is_opensuse}
--with-cpu=power9 \ --with-cpu=power9 \
--with-tune=power9 \ --with-tune=power10 \
%else %else
%if %{suse_version} >= 1350 %if %{suse_version} >= 1350
--with-cpu=power8 \ --with-cpu=power8 \
@@ -756,7 +757,7 @@ amdgcn-amdhsa,\
%endif %endif
%if "%{TARGET_ARCH}" == "s390" || "%{TARGET_ARCH}" == "s390x" %if "%{TARGET_ARCH}" == "s390" || "%{TARGET_ARCH}" == "s390x"
%if %{suse_version} >= 1600 && !0%{?is_opensuse} %if %{suse_version} >= 1600 && !0%{?is_opensuse}
--with-tune=z14 --with-arch=z14 \ --with-tune=z15 --with-arch=z14 \
%else %else
%if %{suse_version} >= 1310 %if %{suse_version} >= 1310
--with-tune=zEC12 --with-arch=z196 \ --with-tune=zEC12 --with-arch=z196 \
@@ -862,7 +863,7 @@ rm -f $RPM_BUILD_ROOT%{_libdir}/libiberty.a
mkdir -p $RPM_BUILD_ROOT/%{?sysroot:%sysroot} mkdir -p $RPM_BUILD_ROOT/%{?sysroot:%sysroot}
make DESTDIR=$RPM_BUILD_ROOT install-target make DESTDIR=$RPM_BUILD_ROOT install-target
%if %{build_cp} %if %{build_cp}
# So we installed libstdc++ headers into %prefix where they conflict # So we installed libstdc++ headers into %%prefix where they conflict
# with other host compilers. Rip out the non-target specific parts # with other host compilers. Rip out the non-target specific parts
# again. Note not all cross targets support libstdc++, so create the # again. Note not all cross targets support libstdc++, so create the
# directory to make things easier. # directory to make things easier.
@@ -887,6 +888,7 @@ rm -rf $RPM_BUILD_ROOT%{_infodir}
# for accelerators remove all frontends but lto1 and also install-tools # for accelerators remove all frontends but lto1 and also install-tools
%if 0%{?gcc_accel:1} %if 0%{?gcc_accel:1}
rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1 rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1
rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/f951
rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1plus rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1plus
rm -rf $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/install-tools rm -rf $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/install-tools
rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}/install-tools rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}/install-tools
@@ -894,6 +896,8 @@ rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}/install-tools
# that is the place where we later search for (only) # that is the place where we later search for (only)
( cd $RPM_BUILD_ROOT%{targetlibsubdir} && tar cf - . ) | ( cd $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch} && tar xf - ) ( cd $RPM_BUILD_ROOT%{targetlibsubdir} && tar cf - . ) | ( cd $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch} && tar xf - )
rm -rf $RPM_BUILD_ROOT%{targetlibsubdir} rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}
# also remove installed libstdc++ headers
rm -rf $RPM_BUILD_ROOT%{_prefix}/include/c++
%endif %endif
# for amdgcn install the symlinks to the llvm tools # for amdgcn install the symlinks to the llvm tools
# follow alternatives symlinks to the hardcoded version requirement # follow alternatives symlinks to the hardcoded version requirement
@@ -958,7 +962,7 @@ rm -r env
# we provide update-alternatives for selecting a compiler version for # we provide update-alternatives for selecting a compiler version for
# crosses # crosses
%if 0%{!?gcc_accel:1} %if 0%{!?gcc_accel:1} && %{suse_version} < 1600
mkdir -p %{buildroot}%{_sysconfdir}/alternatives mkdir -p %{buildroot}%{_sysconfdir}/alternatives
for ex in gcc cpp \ for ex in gcc cpp \
%if %{build_cp} %if %{build_cp}
@@ -1014,15 +1018,19 @@ fi
%endif %endif
%else %else
%{_prefix}/bin/%{gcc_target_arch}-gcc%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc%{binsuffix}
%if %{suse_version} < 1600
%{_prefix}/bin/%{gcc_target_arch}-cpp%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-cpp%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcc-ar%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc-ar%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcc-nm%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc-nm%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-lto-dump%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-lto-dump%{binsuffix}
%endif
%if 0%{!?gcc_libc_bootstrap:1} && "%{cross_arch}" != "bpf" %if 0%{!?gcc_libc_bootstrap:1} && "%{cross_arch}" != "bpf"
%if %{suse_version} < 1600
%{_prefix}/bin/%{gcc_target_arch}-gcov%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcov%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcov-dump%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcov-dump%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcov-tool%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcov-tool%{binsuffix}
%endif
%{_prefix}/bin/%{gcc_target_arch}-gcov %{_prefix}/bin/%{gcc_target_arch}-gcov
%{_prefix}/bin/%{gcc_target_arch}-gcov-dump %{_prefix}/bin/%{gcc_target_arch}-gcov-dump
%{_prefix}/bin/%{gcc_target_arch}-gcov-tool %{_prefix}/bin/%{gcc_target_arch}-gcov-tool
@@ -1033,6 +1041,7 @@ fi
%{_prefix}/bin/%{gcc_target_arch}-gcc-nm %{_prefix}/bin/%{gcc_target_arch}-gcc-nm
%{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib %{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib
%{_prefix}/bin/%{gcc_target_arch}-lto-dump %{_prefix}/bin/%{gcc_target_arch}-lto-dump
%if %{suse_version} < 1600
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-cpp %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-cpp
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc-ar %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc-ar
@@ -1044,13 +1053,16 @@ fi
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-dump %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-dump
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-tool %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-tool
%endif %endif
%endif
%if %{build_cp} %if %{build_cp}
%{_prefix}/bin/%{gcc_target_arch}-c++%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-g++%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-c++ %{_prefix}/bin/%{gcc_target_arch}-c++
%{_prefix}/bin/%{gcc_target_arch}-g++ %{_prefix}/bin/%{gcc_target_arch}-g++
%if %{suse_version} < 1600
%{_prefix}/bin/%{gcc_target_arch}-c++%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-g++%{binsuffix}
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-c++ %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-c++
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-g++ %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-g++
%endif
%if 0%{!?gcc_libc_bootstrap:1} %if 0%{!?gcc_libc_bootstrap:1}
%if "%{cross_arch}" == "avr" || 0%{?gcc_target_newlib:1} || 0%{?gcc_target_glibc:1} %if "%{cross_arch}" == "avr" || 0%{?gcc_target_newlib:1} || 0%{?gcc_target_glibc:1}
%{_prefix}/include/c++ %{_prefix}/include/c++

View File

@@ -292,26 +292,24 @@ ExclusiveArch: i586 ppc64le ppc64 x86_64 s390x aarch64 riscv64
%if "%pkgname" == "cross-ppc64-gcc49" %if "%pkgname" == "cross-ppc64-gcc49"
Obsoletes: cross-ppc-gcc49 <= 4.9.0+r209354 Obsoletes: cross-ppc-gcc49 <= 4.9.0+r209354
%endif %endif
%if 0%{?gcc_target_newlib:1}%{?gcc_target_glibc:1} || "%{cross_arch}" == "avr" %if 0%{!?gcc_accel:1}
# Generally only one cross for the same target triplet can be installed # Generally only one cross for the same target triplet can be installed
# at the same time as we are populating a non-version-specific sysroot # at the same time as we are populating a non-version-specific sysroot
Provides: %{gcc_target_arch}-gcc
Conflicts: %selfconflict %{gcc_target_arch}-gcc
%endif
%if 0%{?gcc_libc_bootstrap:1}
# The -bootstrap packages file-conflict with the non-bootstrap variants. # The -bootstrap packages file-conflict with the non-bootstrap variants.
# Even if we don't actually (want to) distribute the bootstrap variants # Even if we don't actually (want to) distribute the bootstrap variants
# the following avoids repo-checker spamming us endlessly. # the following avoids repo-checker spamming us endlessly.
Provides: %{gcc_target_arch}-gcc
Conflicts: %{gcc_target_arch}-gcc Conflicts: %{gcc_target_arch}-gcc
Conflicts: %{pkgname}-bootstrap
%endif %endif
#!BuildIgnore: gcc-PIE #!BuildIgnore: gcc-PIE
%if 0%{build_cp:1} %if %{build_cp}
# The cross compiler only packages the arch specific c++ headers, so # The cross compiler only packages the arch specific c++ headers, so
# we need to depend on the host libstdc++ devel headers (we wouldn't need # we need to depend on the host libstdc++ devel headers (we wouldn't need
# the libs, though) # the libs, though)
Requires: libstdc++6-devel-gcc13 Requires: libstdc++6-devel-gcc13
%endif %endif
%if 0%{!?gcc_accel:1} %if 0%{!?gcc_accel:1} && %{suse_version} < 1600
BuildRequires: update-alternatives BuildRequires: update-alternatives
Requires(post): update-alternatives Requires(post): update-alternatives
Requires(preun): update-alternatives Requires(preun): update-alternatives
@@ -587,11 +585,11 @@ amdgcn-amdhsa,\
--enable-gnu-indirect-function \ --enable-gnu-indirect-function \
%endif %endif
%endif %endif
--program-suffix=%{binsuffix} \
%ifarch %{disable_multilib_arch} %ifarch %{disable_multilib_arch}
--disable-multilib \ --disable-multilib \
%endif %endif
%if 0%{!?gcc_target_arch:1} %if 0%{!?gcc_target_arch:1}
--program-suffix=%{binsuffix} \
%ifarch ia64 %ifarch ia64
--with-system-libunwind \ --with-system-libunwind \
%else %else
@@ -599,6 +597,9 @@ amdgcn-amdhsa,\
%endif %endif
%endif %endif
%if 0%{?gcc_target_arch:1} %if 0%{?gcc_target_arch:1}
%if 0%{?gcc_accel:1} || %{suse_version} < 1600
--program-suffix=%{binsuffix} \
%endif
--program-prefix=%{gcc_target_arch}- \ --program-prefix=%{gcc_target_arch}- \
--target=%{gcc_target_arch} \ --target=%{gcc_target_arch} \
--disable-nls \ --disable-nls \
@@ -686,7 +687,7 @@ amdgcn-amdhsa,\
%endif %endif
%if %{suse_version} >= 1600 && !0%{?is_opensuse} %if %{suse_version} >= 1600 && !0%{?is_opensuse}
--with-cpu=power9 \ --with-cpu=power9 \
--with-tune=power9 \ --with-tune=power10 \
%else %else
%if %{suse_version} >= 1350 %if %{suse_version} >= 1350
--with-cpu=power8 \ --with-cpu=power8 \
@@ -755,7 +756,7 @@ amdgcn-amdhsa,\
%endif %endif
%if "%{TARGET_ARCH}" == "s390" || "%{TARGET_ARCH}" == "s390x" %if "%{TARGET_ARCH}" == "s390" || "%{TARGET_ARCH}" == "s390x"
%if %{suse_version} >= 1600 && !0%{?is_opensuse} %if %{suse_version} >= 1600 && !0%{?is_opensuse}
--with-tune=z14 --with-arch=z14 \ --with-tune=z15 --with-arch=z14 \
%else %else
%if %{suse_version} >= 1310 %if %{suse_version} >= 1310
--with-tune=zEC12 --with-arch=z196 \ --with-tune=zEC12 --with-arch=z196 \
@@ -861,7 +862,7 @@ rm -f $RPM_BUILD_ROOT%{_libdir}/libiberty.a
mkdir -p $RPM_BUILD_ROOT/%{?sysroot:%sysroot} mkdir -p $RPM_BUILD_ROOT/%{?sysroot:%sysroot}
make DESTDIR=$RPM_BUILD_ROOT install-target make DESTDIR=$RPM_BUILD_ROOT install-target
%if %{build_cp} %if %{build_cp}
# So we installed libstdc++ headers into %prefix where they conflict # So we installed libstdc++ headers into %%prefix where they conflict
# with other host compilers. Rip out the non-target specific parts # with other host compilers. Rip out the non-target specific parts
# again. Note not all cross targets support libstdc++, so create the # again. Note not all cross targets support libstdc++, so create the
# directory to make things easier. # directory to make things easier.
@@ -886,6 +887,7 @@ rm -rf $RPM_BUILD_ROOT%{_infodir}
# for accelerators remove all frontends but lto1 and also install-tools # for accelerators remove all frontends but lto1 and also install-tools
%if 0%{?gcc_accel:1} %if 0%{?gcc_accel:1}
rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1 rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1
rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/f951
rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1plus rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1plus
rm -rf $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/install-tools rm -rf $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/install-tools
rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}/install-tools rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}/install-tools
@@ -893,6 +895,8 @@ rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}/install-tools
# that is the place where we later search for (only) # that is the place where we later search for (only)
( cd $RPM_BUILD_ROOT%{targetlibsubdir} && tar cf - . ) | ( cd $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch} && tar xf - ) ( cd $RPM_BUILD_ROOT%{targetlibsubdir} && tar cf - . ) | ( cd $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch} && tar xf - )
rm -rf $RPM_BUILD_ROOT%{targetlibsubdir} rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}
# also remove installed libstdc++ headers
rm -rf $RPM_BUILD_ROOT%{_prefix}/include/c++
%endif %endif
# for amdgcn install the symlinks to the llvm tools # for amdgcn install the symlinks to the llvm tools
# follow alternatives symlinks to the hardcoded version requirement # follow alternatives symlinks to the hardcoded version requirement
@@ -957,7 +961,7 @@ rm -r env
# we provide update-alternatives for selecting a compiler version for # we provide update-alternatives for selecting a compiler version for
# crosses # crosses
%if 0%{!?gcc_accel:1} %if 0%{!?gcc_accel:1} && %{suse_version} < 1600
mkdir -p %{buildroot}%{_sysconfdir}/alternatives mkdir -p %{buildroot}%{_sysconfdir}/alternatives
for ex in gcc cpp \ for ex in gcc cpp \
%if %{build_cp} %if %{build_cp}
@@ -1013,15 +1017,19 @@ fi
%endif %endif
%else %else
%{_prefix}/bin/%{gcc_target_arch}-gcc%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc%{binsuffix}
%if %{suse_version} < 1600
%{_prefix}/bin/%{gcc_target_arch}-cpp%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-cpp%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcc-ar%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc-ar%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcc-nm%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc-nm%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-lto-dump%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-lto-dump%{binsuffix}
%endif
%if 0%{!?gcc_libc_bootstrap:1} && "%{cross_arch}" != "bpf" %if 0%{!?gcc_libc_bootstrap:1} && "%{cross_arch}" != "bpf"
%if %{suse_version} < 1600
%{_prefix}/bin/%{gcc_target_arch}-gcov%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcov%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcov-dump%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcov-dump%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcov-tool%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcov-tool%{binsuffix}
%endif
%{_prefix}/bin/%{gcc_target_arch}-gcov %{_prefix}/bin/%{gcc_target_arch}-gcov
%{_prefix}/bin/%{gcc_target_arch}-gcov-dump %{_prefix}/bin/%{gcc_target_arch}-gcov-dump
%{_prefix}/bin/%{gcc_target_arch}-gcov-tool %{_prefix}/bin/%{gcc_target_arch}-gcov-tool
@@ -1032,6 +1040,7 @@ fi
%{_prefix}/bin/%{gcc_target_arch}-gcc-nm %{_prefix}/bin/%{gcc_target_arch}-gcc-nm
%{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib %{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib
%{_prefix}/bin/%{gcc_target_arch}-lto-dump %{_prefix}/bin/%{gcc_target_arch}-lto-dump
%if %{suse_version} < 1600
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-cpp %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-cpp
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc-ar %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc-ar
@@ -1043,13 +1052,16 @@ fi
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-dump %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-dump
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-tool %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-tool
%endif %endif
%endif
%if %{build_cp} %if %{build_cp}
%{_prefix}/bin/%{gcc_target_arch}-c++%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-g++%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-c++ %{_prefix}/bin/%{gcc_target_arch}-c++
%{_prefix}/bin/%{gcc_target_arch}-g++ %{_prefix}/bin/%{gcc_target_arch}-g++
%if %{suse_version} < 1600
%{_prefix}/bin/%{gcc_target_arch}-c++%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-g++%{binsuffix}
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-c++ %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-c++
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-g++ %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-g++
%endif
%if 0%{!?gcc_libc_bootstrap:1} %if 0%{!?gcc_libc_bootstrap:1}
%if "%{cross_arch}" == "avr" || 0%{?gcc_target_newlib:1} || 0%{?gcc_target_glibc:1} %if "%{cross_arch}" == "avr" || 0%{?gcc_target_newlib:1} || 0%{?gcc_target_glibc:1}
%{_prefix}/include/c++ %{_prefix}/include/c++

View File

@@ -19,6 +19,7 @@
%define pkgname cross-s390x-gcc13-bootstrap %define pkgname cross-s390x-gcc13-bootstrap
%define cross_arch s390x %define cross_arch s390x
%define gcc_target_arch s390x-suse-linux %define gcc_target_arch s390x-suse-linux
%define gcc_target_glibc 1
%define gcc_libc_bootstrap 1 %define gcc_libc_bootstrap 1
# nospeccleaner # nospeccleaner
@@ -292,26 +293,24 @@ ExclusiveArch: i586 ppc64le ppc64 x86_64 aarch64 riscv64
%if "%pkgname" == "cross-ppc64-gcc49" %if "%pkgname" == "cross-ppc64-gcc49"
Obsoletes: cross-ppc-gcc49 <= 4.9.0+r209354 Obsoletes: cross-ppc-gcc49 <= 4.9.0+r209354
%endif %endif
%if 0%{?gcc_target_newlib:1}%{?gcc_target_glibc:1} || "%{cross_arch}" == "avr" %if 0%{!?gcc_accel:1}
# Generally only one cross for the same target triplet can be installed # Generally only one cross for the same target triplet can be installed
# at the same time as we are populating a non-version-specific sysroot # at the same time as we are populating a non-version-specific sysroot
Provides: %{gcc_target_arch}-gcc
Conflicts: %selfconflict %{gcc_target_arch}-gcc
%endif
%if 0%{?gcc_libc_bootstrap:1}
# The -bootstrap packages file-conflict with the non-bootstrap variants. # The -bootstrap packages file-conflict with the non-bootstrap variants.
# Even if we don't actually (want to) distribute the bootstrap variants # Even if we don't actually (want to) distribute the bootstrap variants
# the following avoids repo-checker spamming us endlessly. # the following avoids repo-checker spamming us endlessly.
Provides: %{gcc_target_arch}-gcc
Conflicts: %{gcc_target_arch}-gcc Conflicts: %{gcc_target_arch}-gcc
Conflicts: %{pkgname}-bootstrap
%endif %endif
#!BuildIgnore: gcc-PIE #!BuildIgnore: gcc-PIE
%if 0%{build_cp:1} %if %{build_cp}
# The cross compiler only packages the arch specific c++ headers, so # The cross compiler only packages the arch specific c++ headers, so
# we need to depend on the host libstdc++ devel headers (we wouldn't need # we need to depend on the host libstdc++ devel headers (we wouldn't need
# the libs, though) # the libs, though)
Requires: libstdc++6-devel-gcc13 Requires: libstdc++6-devel-gcc13
%endif %endif
%if 0%{!?gcc_accel:1} %if 0%{!?gcc_accel:1} && %{suse_version} < 1600
BuildRequires: update-alternatives BuildRequires: update-alternatives
Requires(post): update-alternatives Requires(post): update-alternatives
Requires(preun): update-alternatives Requires(preun): update-alternatives
@@ -587,11 +586,11 @@ amdgcn-amdhsa,\
--enable-gnu-indirect-function \ --enable-gnu-indirect-function \
%endif %endif
%endif %endif
--program-suffix=%{binsuffix} \
%ifarch %{disable_multilib_arch} %ifarch %{disable_multilib_arch}
--disable-multilib \ --disable-multilib \
%endif %endif
%if 0%{!?gcc_target_arch:1} %if 0%{!?gcc_target_arch:1}
--program-suffix=%{binsuffix} \
%ifarch ia64 %ifarch ia64
--with-system-libunwind \ --with-system-libunwind \
%else %else
@@ -599,6 +598,9 @@ amdgcn-amdhsa,\
%endif %endif
%endif %endif
%if 0%{?gcc_target_arch:1} %if 0%{?gcc_target_arch:1}
%if 0%{?gcc_accel:1} || %{suse_version} < 1600
--program-suffix=%{binsuffix} \
%endif
--program-prefix=%{gcc_target_arch}- \ --program-prefix=%{gcc_target_arch}- \
--target=%{gcc_target_arch} \ --target=%{gcc_target_arch} \
--disable-nls \ --disable-nls \
@@ -686,7 +688,7 @@ amdgcn-amdhsa,\
%endif %endif
%if %{suse_version} >= 1600 && !0%{?is_opensuse} %if %{suse_version} >= 1600 && !0%{?is_opensuse}
--with-cpu=power9 \ --with-cpu=power9 \
--with-tune=power9 \ --with-tune=power10 \
%else %else
%if %{suse_version} >= 1350 %if %{suse_version} >= 1350
--with-cpu=power8 \ --with-cpu=power8 \
@@ -755,7 +757,7 @@ amdgcn-amdhsa,\
%endif %endif
%if "%{TARGET_ARCH}" == "s390" || "%{TARGET_ARCH}" == "s390x" %if "%{TARGET_ARCH}" == "s390" || "%{TARGET_ARCH}" == "s390x"
%if %{suse_version} >= 1600 && !0%{?is_opensuse} %if %{suse_version} >= 1600 && !0%{?is_opensuse}
--with-tune=z14 --with-arch=z14 \ --with-tune=z15 --with-arch=z14 \
%else %else
%if %{suse_version} >= 1310 %if %{suse_version} >= 1310
--with-tune=zEC12 --with-arch=z196 \ --with-tune=zEC12 --with-arch=z196 \
@@ -861,7 +863,7 @@ rm -f $RPM_BUILD_ROOT%{_libdir}/libiberty.a
mkdir -p $RPM_BUILD_ROOT/%{?sysroot:%sysroot} mkdir -p $RPM_BUILD_ROOT/%{?sysroot:%sysroot}
make DESTDIR=$RPM_BUILD_ROOT install-target make DESTDIR=$RPM_BUILD_ROOT install-target
%if %{build_cp} %if %{build_cp}
# So we installed libstdc++ headers into %prefix where they conflict # So we installed libstdc++ headers into %%prefix where they conflict
# with other host compilers. Rip out the non-target specific parts # with other host compilers. Rip out the non-target specific parts
# again. Note not all cross targets support libstdc++, so create the # again. Note not all cross targets support libstdc++, so create the
# directory to make things easier. # directory to make things easier.
@@ -886,6 +888,7 @@ rm -rf $RPM_BUILD_ROOT%{_infodir}
# for accelerators remove all frontends but lto1 and also install-tools # for accelerators remove all frontends but lto1 and also install-tools
%if 0%{?gcc_accel:1} %if 0%{?gcc_accel:1}
rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1 rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1
rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/f951
rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1plus rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1plus
rm -rf $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/install-tools rm -rf $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/install-tools
rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}/install-tools rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}/install-tools
@@ -893,6 +896,8 @@ rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}/install-tools
# that is the place where we later search for (only) # that is the place where we later search for (only)
( cd $RPM_BUILD_ROOT%{targetlibsubdir} && tar cf - . ) | ( cd $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch} && tar xf - ) ( cd $RPM_BUILD_ROOT%{targetlibsubdir} && tar cf - . ) | ( cd $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch} && tar xf - )
rm -rf $RPM_BUILD_ROOT%{targetlibsubdir} rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}
# also remove installed libstdc++ headers
rm -rf $RPM_BUILD_ROOT%{_prefix}/include/c++
%endif %endif
# for amdgcn install the symlinks to the llvm tools # for amdgcn install the symlinks to the llvm tools
# follow alternatives symlinks to the hardcoded version requirement # follow alternatives symlinks to the hardcoded version requirement
@@ -957,7 +962,7 @@ rm -r env
# we provide update-alternatives for selecting a compiler version for # we provide update-alternatives for selecting a compiler version for
# crosses # crosses
%if 0%{!?gcc_accel:1} %if 0%{!?gcc_accel:1} && %{suse_version} < 1600
mkdir -p %{buildroot}%{_sysconfdir}/alternatives mkdir -p %{buildroot}%{_sysconfdir}/alternatives
for ex in gcc cpp \ for ex in gcc cpp \
%if %{build_cp} %if %{build_cp}
@@ -1013,15 +1018,19 @@ fi
%endif %endif
%else %else
%{_prefix}/bin/%{gcc_target_arch}-gcc%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc%{binsuffix}
%if %{suse_version} < 1600
%{_prefix}/bin/%{gcc_target_arch}-cpp%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-cpp%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcc-ar%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc-ar%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcc-nm%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc-nm%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-lto-dump%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-lto-dump%{binsuffix}
%endif
%if 0%{!?gcc_libc_bootstrap:1} && "%{cross_arch}" != "bpf" %if 0%{!?gcc_libc_bootstrap:1} && "%{cross_arch}" != "bpf"
%if %{suse_version} < 1600
%{_prefix}/bin/%{gcc_target_arch}-gcov%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcov%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcov-dump%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcov-dump%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcov-tool%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcov-tool%{binsuffix}
%endif
%{_prefix}/bin/%{gcc_target_arch}-gcov %{_prefix}/bin/%{gcc_target_arch}-gcov
%{_prefix}/bin/%{gcc_target_arch}-gcov-dump %{_prefix}/bin/%{gcc_target_arch}-gcov-dump
%{_prefix}/bin/%{gcc_target_arch}-gcov-tool %{_prefix}/bin/%{gcc_target_arch}-gcov-tool
@@ -1032,6 +1041,7 @@ fi
%{_prefix}/bin/%{gcc_target_arch}-gcc-nm %{_prefix}/bin/%{gcc_target_arch}-gcc-nm
%{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib %{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib
%{_prefix}/bin/%{gcc_target_arch}-lto-dump %{_prefix}/bin/%{gcc_target_arch}-lto-dump
%if %{suse_version} < 1600
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-cpp %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-cpp
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc-ar %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc-ar
@@ -1043,13 +1053,16 @@ fi
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-dump %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-dump
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-tool %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-tool
%endif %endif
%endif
%if %{build_cp} %if %{build_cp}
%{_prefix}/bin/%{gcc_target_arch}-c++%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-g++%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-c++ %{_prefix}/bin/%{gcc_target_arch}-c++
%{_prefix}/bin/%{gcc_target_arch}-g++ %{_prefix}/bin/%{gcc_target_arch}-g++
%if %{suse_version} < 1600
%{_prefix}/bin/%{gcc_target_arch}-c++%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-g++%{binsuffix}
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-c++ %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-c++
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-g++ %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-g++
%endif
%if 0%{!?gcc_libc_bootstrap:1} %if 0%{!?gcc_libc_bootstrap:1}
%if "%{cross_arch}" == "avr" || 0%{?gcc_target_newlib:1} || 0%{?gcc_target_glibc:1} %if "%{cross_arch}" == "avr" || 0%{?gcc_target_newlib:1} || 0%{?gcc_target_glibc:1}
%{_prefix}/include/c++ %{_prefix}/include/c++

View File

@@ -292,26 +292,24 @@ ExclusiveArch: i586 ppc64le ppc64 x86_64 aarch64 riscv64
%if "%pkgname" == "cross-ppc64-gcc49" %if "%pkgname" == "cross-ppc64-gcc49"
Obsoletes: cross-ppc-gcc49 <= 4.9.0+r209354 Obsoletes: cross-ppc-gcc49 <= 4.9.0+r209354
%endif %endif
%if 0%{?gcc_target_newlib:1}%{?gcc_target_glibc:1} || "%{cross_arch}" == "avr" %if 0%{!?gcc_accel:1}
# Generally only one cross for the same target triplet can be installed # Generally only one cross for the same target triplet can be installed
# at the same time as we are populating a non-version-specific sysroot # at the same time as we are populating a non-version-specific sysroot
Provides: %{gcc_target_arch}-gcc
Conflicts: %selfconflict %{gcc_target_arch}-gcc
%endif
%if 0%{?gcc_libc_bootstrap:1}
# The -bootstrap packages file-conflict with the non-bootstrap variants. # The -bootstrap packages file-conflict with the non-bootstrap variants.
# Even if we don't actually (want to) distribute the bootstrap variants # Even if we don't actually (want to) distribute the bootstrap variants
# the following avoids repo-checker spamming us endlessly. # the following avoids repo-checker spamming us endlessly.
Provides: %{gcc_target_arch}-gcc
Conflicts: %{gcc_target_arch}-gcc Conflicts: %{gcc_target_arch}-gcc
Conflicts: %{pkgname}-bootstrap
%endif %endif
#!BuildIgnore: gcc-PIE #!BuildIgnore: gcc-PIE
%if 0%{build_cp:1} %if %{build_cp}
# The cross compiler only packages the arch specific c++ headers, so # The cross compiler only packages the arch specific c++ headers, so
# we need to depend on the host libstdc++ devel headers (we wouldn't need # we need to depend on the host libstdc++ devel headers (we wouldn't need
# the libs, though) # the libs, though)
Requires: libstdc++6-devel-gcc13 Requires: libstdc++6-devel-gcc13
%endif %endif
%if 0%{!?gcc_accel:1} %if 0%{!?gcc_accel:1} && %{suse_version} < 1600
BuildRequires: update-alternatives BuildRequires: update-alternatives
Requires(post): update-alternatives Requires(post): update-alternatives
Requires(preun): update-alternatives Requires(preun): update-alternatives
@@ -587,11 +585,11 @@ amdgcn-amdhsa,\
--enable-gnu-indirect-function \ --enable-gnu-indirect-function \
%endif %endif
%endif %endif
--program-suffix=%{binsuffix} \
%ifarch %{disable_multilib_arch} %ifarch %{disable_multilib_arch}
--disable-multilib \ --disable-multilib \
%endif %endif
%if 0%{!?gcc_target_arch:1} %if 0%{!?gcc_target_arch:1}
--program-suffix=%{binsuffix} \
%ifarch ia64 %ifarch ia64
--with-system-libunwind \ --with-system-libunwind \
%else %else
@@ -599,6 +597,9 @@ amdgcn-amdhsa,\
%endif %endif
%endif %endif
%if 0%{?gcc_target_arch:1} %if 0%{?gcc_target_arch:1}
%if 0%{?gcc_accel:1} || %{suse_version} < 1600
--program-suffix=%{binsuffix} \
%endif
--program-prefix=%{gcc_target_arch}- \ --program-prefix=%{gcc_target_arch}- \
--target=%{gcc_target_arch} \ --target=%{gcc_target_arch} \
--disable-nls \ --disable-nls \
@@ -686,7 +687,7 @@ amdgcn-amdhsa,\
%endif %endif
%if %{suse_version} >= 1600 && !0%{?is_opensuse} %if %{suse_version} >= 1600 && !0%{?is_opensuse}
--with-cpu=power9 \ --with-cpu=power9 \
--with-tune=power9 \ --with-tune=power10 \
%else %else
%if %{suse_version} >= 1350 %if %{suse_version} >= 1350
--with-cpu=power8 \ --with-cpu=power8 \
@@ -755,7 +756,7 @@ amdgcn-amdhsa,\
%endif %endif
%if "%{TARGET_ARCH}" == "s390" || "%{TARGET_ARCH}" == "s390x" %if "%{TARGET_ARCH}" == "s390" || "%{TARGET_ARCH}" == "s390x"
%if %{suse_version} >= 1600 && !0%{?is_opensuse} %if %{suse_version} >= 1600 && !0%{?is_opensuse}
--with-tune=z14 --with-arch=z14 \ --with-tune=z15 --with-arch=z14 \
%else %else
%if %{suse_version} >= 1310 %if %{suse_version} >= 1310
--with-tune=zEC12 --with-arch=z196 \ --with-tune=zEC12 --with-arch=z196 \
@@ -861,7 +862,7 @@ rm -f $RPM_BUILD_ROOT%{_libdir}/libiberty.a
mkdir -p $RPM_BUILD_ROOT/%{?sysroot:%sysroot} mkdir -p $RPM_BUILD_ROOT/%{?sysroot:%sysroot}
make DESTDIR=$RPM_BUILD_ROOT install-target make DESTDIR=$RPM_BUILD_ROOT install-target
%if %{build_cp} %if %{build_cp}
# So we installed libstdc++ headers into %prefix where they conflict # So we installed libstdc++ headers into %%prefix where they conflict
# with other host compilers. Rip out the non-target specific parts # with other host compilers. Rip out the non-target specific parts
# again. Note not all cross targets support libstdc++, so create the # again. Note not all cross targets support libstdc++, so create the
# directory to make things easier. # directory to make things easier.
@@ -886,6 +887,7 @@ rm -rf $RPM_BUILD_ROOT%{_infodir}
# for accelerators remove all frontends but lto1 and also install-tools # for accelerators remove all frontends but lto1 and also install-tools
%if 0%{?gcc_accel:1} %if 0%{?gcc_accel:1}
rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1 rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1
rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/f951
rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1plus rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1plus
rm -rf $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/install-tools rm -rf $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/install-tools
rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}/install-tools rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}/install-tools
@@ -893,6 +895,8 @@ rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}/install-tools
# that is the place where we later search for (only) # that is the place where we later search for (only)
( cd $RPM_BUILD_ROOT%{targetlibsubdir} && tar cf - . ) | ( cd $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch} && tar xf - ) ( cd $RPM_BUILD_ROOT%{targetlibsubdir} && tar cf - . ) | ( cd $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch} && tar xf - )
rm -rf $RPM_BUILD_ROOT%{targetlibsubdir} rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}
# also remove installed libstdc++ headers
rm -rf $RPM_BUILD_ROOT%{_prefix}/include/c++
%endif %endif
# for amdgcn install the symlinks to the llvm tools # for amdgcn install the symlinks to the llvm tools
# follow alternatives symlinks to the hardcoded version requirement # follow alternatives symlinks to the hardcoded version requirement
@@ -957,7 +961,7 @@ rm -r env
# we provide update-alternatives for selecting a compiler version for # we provide update-alternatives for selecting a compiler version for
# crosses # crosses
%if 0%{!?gcc_accel:1} %if 0%{!?gcc_accel:1} && %{suse_version} < 1600
mkdir -p %{buildroot}%{_sysconfdir}/alternatives mkdir -p %{buildroot}%{_sysconfdir}/alternatives
for ex in gcc cpp \ for ex in gcc cpp \
%if %{build_cp} %if %{build_cp}
@@ -1013,15 +1017,19 @@ fi
%endif %endif
%else %else
%{_prefix}/bin/%{gcc_target_arch}-gcc%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc%{binsuffix}
%if %{suse_version} < 1600
%{_prefix}/bin/%{gcc_target_arch}-cpp%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-cpp%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcc-ar%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc-ar%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcc-nm%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc-nm%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-lto-dump%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-lto-dump%{binsuffix}
%endif
%if 0%{!?gcc_libc_bootstrap:1} && "%{cross_arch}" != "bpf" %if 0%{!?gcc_libc_bootstrap:1} && "%{cross_arch}" != "bpf"
%if %{suse_version} < 1600
%{_prefix}/bin/%{gcc_target_arch}-gcov%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcov%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcov-dump%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcov-dump%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcov-tool%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcov-tool%{binsuffix}
%endif
%{_prefix}/bin/%{gcc_target_arch}-gcov %{_prefix}/bin/%{gcc_target_arch}-gcov
%{_prefix}/bin/%{gcc_target_arch}-gcov-dump %{_prefix}/bin/%{gcc_target_arch}-gcov-dump
%{_prefix}/bin/%{gcc_target_arch}-gcov-tool %{_prefix}/bin/%{gcc_target_arch}-gcov-tool
@@ -1032,6 +1040,7 @@ fi
%{_prefix}/bin/%{gcc_target_arch}-gcc-nm %{_prefix}/bin/%{gcc_target_arch}-gcc-nm
%{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib %{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib
%{_prefix}/bin/%{gcc_target_arch}-lto-dump %{_prefix}/bin/%{gcc_target_arch}-lto-dump
%if %{suse_version} < 1600
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-cpp %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-cpp
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc-ar %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc-ar
@@ -1043,13 +1052,16 @@ fi
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-dump %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-dump
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-tool %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-tool
%endif %endif
%endif
%if %{build_cp} %if %{build_cp}
%{_prefix}/bin/%{gcc_target_arch}-c++%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-g++%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-c++ %{_prefix}/bin/%{gcc_target_arch}-c++
%{_prefix}/bin/%{gcc_target_arch}-g++ %{_prefix}/bin/%{gcc_target_arch}-g++
%if %{suse_version} < 1600
%{_prefix}/bin/%{gcc_target_arch}-c++%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-g++%{binsuffix}
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-c++ %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-c++
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-g++ %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-g++
%endif
%if 0%{!?gcc_libc_bootstrap:1} %if 0%{!?gcc_libc_bootstrap:1}
%if "%{cross_arch}" == "avr" || 0%{?gcc_target_newlib:1} || 0%{?gcc_target_glibc:1} %if "%{cross_arch}" == "avr" || 0%{?gcc_target_newlib:1} || 0%{?gcc_target_glibc:1}
%{_prefix}/include/c++ %{_prefix}/include/c++

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@@ -19,7 +19,8 @@
%define pkgname cross-x86_64-gcc13 %define pkgname cross-x86_64-gcc13
%define cross_arch x86_64 %define cross_arch x86_64
%define gcc_target_arch x86_64-suse-linux %define gcc_target_arch x86_64-suse-linux
%define gcc_icecream 1 %define gcc_target_glibc 1
%define gcc_libc_bootstrap 1
# nospeccleaner # nospeccleaner
%define build_cp 0%{!?gcc_accel:1} %define build_cp 0%{!?gcc_accel:1}
@@ -292,26 +293,24 @@ ExclusiveArch: i586 ppc64le ppc64 s390x aarch64 riscv64
%if "%pkgname" == "cross-ppc64-gcc49" %if "%pkgname" == "cross-ppc64-gcc49"
Obsoletes: cross-ppc-gcc49 <= 4.9.0+r209354 Obsoletes: cross-ppc-gcc49 <= 4.9.0+r209354
%endif %endif
%if 0%{?gcc_target_newlib:1}%{?gcc_target_glibc:1} || "%{cross_arch}" == "avr" %if 0%{!?gcc_accel:1}
# Generally only one cross for the same target triplet can be installed # Generally only one cross for the same target triplet can be installed
# at the same time as we are populating a non-version-specific sysroot # at the same time as we are populating a non-version-specific sysroot
Provides: %{gcc_target_arch}-gcc
Conflicts: %selfconflict %{gcc_target_arch}-gcc
%endif
%if 0%{?gcc_libc_bootstrap:1}
# The -bootstrap packages file-conflict with the non-bootstrap variants. # The -bootstrap packages file-conflict with the non-bootstrap variants.
# Even if we don't actually (want to) distribute the bootstrap variants # Even if we don't actually (want to) distribute the bootstrap variants
# the following avoids repo-checker spamming us endlessly. # the following avoids repo-checker spamming us endlessly.
Provides: %{gcc_target_arch}-gcc
Conflicts: %{gcc_target_arch}-gcc Conflicts: %{gcc_target_arch}-gcc
Conflicts: %{pkgname}-bootstrap
%endif %endif
#!BuildIgnore: gcc-PIE #!BuildIgnore: gcc-PIE
%if 0%{build_cp:1} %if %{build_cp}
# The cross compiler only packages the arch specific c++ headers, so # The cross compiler only packages the arch specific c++ headers, so
# we need to depend on the host libstdc++ devel headers (we wouldn't need # we need to depend on the host libstdc++ devel headers (we wouldn't need
# the libs, though) # the libs, though)
Requires: libstdc++6-devel-gcc13 Requires: libstdc++6-devel-gcc13
%endif %endif
%if 0%{!?gcc_accel:1} %if 0%{!?gcc_accel:1} && %{suse_version} < 1600
BuildRequires: update-alternatives BuildRequires: update-alternatives
Requires(post): update-alternatives Requires(post): update-alternatives
Requires(preun): update-alternatives Requires(preun): update-alternatives
@@ -587,11 +586,11 @@ amdgcn-amdhsa,\
--enable-gnu-indirect-function \ --enable-gnu-indirect-function \
%endif %endif
%endif %endif
--program-suffix=%{binsuffix} \
%ifarch %{disable_multilib_arch} %ifarch %{disable_multilib_arch}
--disable-multilib \ --disable-multilib \
%endif %endif
%if 0%{!?gcc_target_arch:1} %if 0%{!?gcc_target_arch:1}
--program-suffix=%{binsuffix} \
%ifarch ia64 %ifarch ia64
--with-system-libunwind \ --with-system-libunwind \
%else %else
@@ -599,6 +598,9 @@ amdgcn-amdhsa,\
%endif %endif
%endif %endif
%if 0%{?gcc_target_arch:1} %if 0%{?gcc_target_arch:1}
%if 0%{?gcc_accel:1} || %{suse_version} < 1600
--program-suffix=%{binsuffix} \
%endif
--program-prefix=%{gcc_target_arch}- \ --program-prefix=%{gcc_target_arch}- \
--target=%{gcc_target_arch} \ --target=%{gcc_target_arch} \
--disable-nls \ --disable-nls \
@@ -686,7 +688,7 @@ amdgcn-amdhsa,\
%endif %endif
%if %{suse_version} >= 1600 && !0%{?is_opensuse} %if %{suse_version} >= 1600 && !0%{?is_opensuse}
--with-cpu=power9 \ --with-cpu=power9 \
--with-tune=power9 \ --with-tune=power10 \
%else %else
%if %{suse_version} >= 1350 %if %{suse_version} >= 1350
--with-cpu=power8 \ --with-cpu=power8 \
@@ -755,7 +757,7 @@ amdgcn-amdhsa,\
%endif %endif
%if "%{TARGET_ARCH}" == "s390" || "%{TARGET_ARCH}" == "s390x" %if "%{TARGET_ARCH}" == "s390" || "%{TARGET_ARCH}" == "s390x"
%if %{suse_version} >= 1600 && !0%{?is_opensuse} %if %{suse_version} >= 1600 && !0%{?is_opensuse}
--with-tune=z14 --with-arch=z14 \ --with-tune=z15 --with-arch=z14 \
%else %else
%if %{suse_version} >= 1310 %if %{suse_version} >= 1310
--with-tune=zEC12 --with-arch=z196 \ --with-tune=zEC12 --with-arch=z196 \
@@ -861,7 +863,7 @@ rm -f $RPM_BUILD_ROOT%{_libdir}/libiberty.a
mkdir -p $RPM_BUILD_ROOT/%{?sysroot:%sysroot} mkdir -p $RPM_BUILD_ROOT/%{?sysroot:%sysroot}
make DESTDIR=$RPM_BUILD_ROOT install-target make DESTDIR=$RPM_BUILD_ROOT install-target
%if %{build_cp} %if %{build_cp}
# So we installed libstdc++ headers into %prefix where they conflict # So we installed libstdc++ headers into %%prefix where they conflict
# with other host compilers. Rip out the non-target specific parts # with other host compilers. Rip out the non-target specific parts
# again. Note not all cross targets support libstdc++, so create the # again. Note not all cross targets support libstdc++, so create the
# directory to make things easier. # directory to make things easier.
@@ -886,6 +888,7 @@ rm -rf $RPM_BUILD_ROOT%{_infodir}
# for accelerators remove all frontends but lto1 and also install-tools # for accelerators remove all frontends but lto1 and also install-tools
%if 0%{?gcc_accel:1} %if 0%{?gcc_accel:1}
rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1 rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1
rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/f951
rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1plus rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1plus
rm -rf $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/install-tools rm -rf $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/install-tools
rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}/install-tools rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}/install-tools
@@ -893,6 +896,8 @@ rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}/install-tools
# that is the place where we later search for (only) # that is the place where we later search for (only)
( cd $RPM_BUILD_ROOT%{targetlibsubdir} && tar cf - . ) | ( cd $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch} && tar xf - ) ( cd $RPM_BUILD_ROOT%{targetlibsubdir} && tar cf - . ) | ( cd $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch} && tar xf - )
rm -rf $RPM_BUILD_ROOT%{targetlibsubdir} rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}
# also remove installed libstdc++ headers
rm -rf $RPM_BUILD_ROOT%{_prefix}/include/c++
%endif %endif
# for amdgcn install the symlinks to the llvm tools # for amdgcn install the symlinks to the llvm tools
# follow alternatives symlinks to the hardcoded version requirement # follow alternatives symlinks to the hardcoded version requirement
@@ -957,7 +962,7 @@ rm -r env
# we provide update-alternatives for selecting a compiler version for # we provide update-alternatives for selecting a compiler version for
# crosses # crosses
%if 0%{!?gcc_accel:1} %if 0%{!?gcc_accel:1} && %{suse_version} < 1600
mkdir -p %{buildroot}%{_sysconfdir}/alternatives mkdir -p %{buildroot}%{_sysconfdir}/alternatives
for ex in gcc cpp \ for ex in gcc cpp \
%if %{build_cp} %if %{build_cp}
@@ -1013,15 +1018,19 @@ fi
%endif %endif
%else %else
%{_prefix}/bin/%{gcc_target_arch}-gcc%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc%{binsuffix}
%if %{suse_version} < 1600
%{_prefix}/bin/%{gcc_target_arch}-cpp%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-cpp%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcc-ar%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc-ar%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcc-nm%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc-nm%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-lto-dump%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-lto-dump%{binsuffix}
%endif
%if 0%{!?gcc_libc_bootstrap:1} && "%{cross_arch}" != "bpf" %if 0%{!?gcc_libc_bootstrap:1} && "%{cross_arch}" != "bpf"
%if %{suse_version} < 1600
%{_prefix}/bin/%{gcc_target_arch}-gcov%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcov%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcov-dump%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcov-dump%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcov-tool%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcov-tool%{binsuffix}
%endif
%{_prefix}/bin/%{gcc_target_arch}-gcov %{_prefix}/bin/%{gcc_target_arch}-gcov
%{_prefix}/bin/%{gcc_target_arch}-gcov-dump %{_prefix}/bin/%{gcc_target_arch}-gcov-dump
%{_prefix}/bin/%{gcc_target_arch}-gcov-tool %{_prefix}/bin/%{gcc_target_arch}-gcov-tool
@@ -1032,6 +1041,7 @@ fi
%{_prefix}/bin/%{gcc_target_arch}-gcc-nm %{_prefix}/bin/%{gcc_target_arch}-gcc-nm
%{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib %{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib
%{_prefix}/bin/%{gcc_target_arch}-lto-dump %{_prefix}/bin/%{gcc_target_arch}-lto-dump
%if %{suse_version} < 1600
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-cpp %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-cpp
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc-ar %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc-ar
@@ -1043,13 +1053,16 @@ fi
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-dump %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-dump
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-tool %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-tool
%endif %endif
%endif
%if %{build_cp} %if %{build_cp}
%{_prefix}/bin/%{gcc_target_arch}-c++%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-g++%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-c++ %{_prefix}/bin/%{gcc_target_arch}-c++
%{_prefix}/bin/%{gcc_target_arch}-g++ %{_prefix}/bin/%{gcc_target_arch}-g++
%if %{suse_version} < 1600
%{_prefix}/bin/%{gcc_target_arch}-c++%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-g++%{binsuffix}
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-c++ %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-c++
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-g++ %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-g++
%endif
%if 0%{!?gcc_libc_bootstrap:1} %if 0%{!?gcc_libc_bootstrap:1}
%if "%{cross_arch}" == "avr" || 0%{?gcc_target_newlib:1} || 0%{?gcc_target_glibc:1} %if "%{cross_arch}" == "avr" || 0%{?gcc_target_newlib:1} || 0%{?gcc_target_glibc:1}
%{_prefix}/include/c++ %{_prefix}/include/c++

View File

@@ -195,26 +195,24 @@ ExclusiveArch: i586 ppc64le ppc64 x86_64 s390x aarch64 riscv64
%if "%pkgname" == "cross-ppc64-gcc49" %if "%pkgname" == "cross-ppc64-gcc49"
Obsoletes: cross-ppc-gcc49 <= 4.9.0+r209354 Obsoletes: cross-ppc-gcc49 <= 4.9.0+r209354
%endif %endif
%if 0%{?gcc_target_newlib:1}%{?gcc_target_glibc:1} || "%{cross_arch}" == "avr" %if 0%{!?gcc_accel:1}
# Generally only one cross for the same target triplet can be installed # Generally only one cross for the same target triplet can be installed
# at the same time as we are populating a non-version-specific sysroot # at the same time as we are populating a non-version-specific sysroot
Provides: %{gcc_target_arch}-gcc
Conflicts: %selfconflict %{gcc_target_arch}-gcc
%endif
%if 0%{?gcc_libc_bootstrap:1}
# The -bootstrap packages file-conflict with the non-bootstrap variants. # The -bootstrap packages file-conflict with the non-bootstrap variants.
# Even if we don't actually (want to) distribute the bootstrap variants # Even if we don't actually (want to) distribute the bootstrap variants
# the following avoids repo-checker spamming us endlessly. # the following avoids repo-checker spamming us endlessly.
Provides: %{gcc_target_arch}-gcc
Conflicts: %{gcc_target_arch}-gcc Conflicts: %{gcc_target_arch}-gcc
Conflicts: %{pkgname}-bootstrap
%endif %endif
#!BuildIgnore: gcc-PIE #!BuildIgnore: gcc-PIE
%if 0%{build_cp:1} %if %{build_cp}
# The cross compiler only packages the arch specific c++ headers, so # The cross compiler only packages the arch specific c++ headers, so
# we need to depend on the host libstdc++ devel headers (we wouldn't need # we need to depend on the host libstdc++ devel headers (we wouldn't need
# the libs, though) # the libs, though)
Requires: libstdc++6-devel-gcc@base_ver@ Requires: libstdc++6-devel-gcc@base_ver@
%endif %endif
%if 0%{!?gcc_accel:1} %if 0%{!?gcc_accel:1} && %{suse_version} < 1600
BuildRequires: update-alternatives BuildRequires: update-alternatives
Requires(post): update-alternatives Requires(post): update-alternatives
Requires(preun): update-alternatives Requires(preun): update-alternatives
@@ -307,7 +305,7 @@ rm -f $RPM_BUILD_ROOT%{_libdir}/libiberty.a
mkdir -p $RPM_BUILD_ROOT/%{?sysroot:%sysroot} mkdir -p $RPM_BUILD_ROOT/%{?sysroot:%sysroot}
make DESTDIR=$RPM_BUILD_ROOT install-target make DESTDIR=$RPM_BUILD_ROOT install-target
%if %{build_cp} %if %{build_cp}
# So we installed libstdc++ headers into %prefix where they conflict # So we installed libstdc++ headers into %%prefix where they conflict
# with other host compilers. Rip out the non-target specific parts # with other host compilers. Rip out the non-target specific parts
# again. Note not all cross targets support libstdc++, so create the # again. Note not all cross targets support libstdc++, so create the
# directory to make things easier. # directory to make things easier.
@@ -332,6 +330,7 @@ rm -rf $RPM_BUILD_ROOT%{_infodir}
# for accelerators remove all frontends but lto1 and also install-tools # for accelerators remove all frontends but lto1 and also install-tools
%if 0%{?gcc_accel:1} %if 0%{?gcc_accel:1}
rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1 rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1
rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/f951
rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1plus rm -f $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/cc1plus
rm -rf $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/install-tools rm -rf $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch}/install-tools
rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}/install-tools rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}/install-tools
@@ -339,6 +338,8 @@ rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}/install-tools
# that is the place where we later search for (only) # that is the place where we later search for (only)
( cd $RPM_BUILD_ROOT%{targetlibsubdir} && tar cf - . ) | ( cd $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch} && tar xf - ) ( cd $RPM_BUILD_ROOT%{targetlibsubdir} && tar cf - . ) | ( cd $RPM_BUILD_ROOT%{libsubdir}/accel/%{gcc_target_arch} && tar xf - )
rm -rf $RPM_BUILD_ROOT%{targetlibsubdir} rm -rf $RPM_BUILD_ROOT%{targetlibsubdir}
# also remove installed libstdc++ headers
rm -rf $RPM_BUILD_ROOT%{_prefix}/include/c++
%endif %endif
# for amdgcn install the symlinks to the llvm tools # for amdgcn install the symlinks to the llvm tools
# follow alternatives symlinks to the hardcoded version requirement # follow alternatives symlinks to the hardcoded version requirement
@@ -403,7 +404,7 @@ rm -r env
# we provide update-alternatives for selecting a compiler version for # we provide update-alternatives for selecting a compiler version for
# crosses # crosses
%if 0%{!?gcc_accel:1} %if 0%{!?gcc_accel:1} && %{suse_version} < 1600
mkdir -p %{buildroot}%{_sysconfdir}/alternatives mkdir -p %{buildroot}%{_sysconfdir}/alternatives
for ex in gcc cpp \ for ex in gcc cpp \
%if %{build_cp} %if %{build_cp}
@@ -459,15 +460,19 @@ fi
%endif %endif
%else %else
%{_prefix}/bin/%{gcc_target_arch}-gcc%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc%{binsuffix}
%if %{suse_version} < 1600
%{_prefix}/bin/%{gcc_target_arch}-cpp%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-cpp%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcc-ar%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc-ar%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcc-nm%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc-nm%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-lto-dump%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-lto-dump%{binsuffix}
%endif
%if 0%{!?gcc_libc_bootstrap:1} && "%{cross_arch}" != "bpf" %if 0%{!?gcc_libc_bootstrap:1} && "%{cross_arch}" != "bpf"
%if %{suse_version} < 1600
%{_prefix}/bin/%{gcc_target_arch}-gcov%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcov%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcov-dump%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcov-dump%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-gcov-tool%{binsuffix} %{_prefix}/bin/%{gcc_target_arch}-gcov-tool%{binsuffix}
%endif
%{_prefix}/bin/%{gcc_target_arch}-gcov %{_prefix}/bin/%{gcc_target_arch}-gcov
%{_prefix}/bin/%{gcc_target_arch}-gcov-dump %{_prefix}/bin/%{gcc_target_arch}-gcov-dump
%{_prefix}/bin/%{gcc_target_arch}-gcov-tool %{_prefix}/bin/%{gcc_target_arch}-gcov-tool
@@ -478,6 +483,7 @@ fi
%{_prefix}/bin/%{gcc_target_arch}-gcc-nm %{_prefix}/bin/%{gcc_target_arch}-gcc-nm
%{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib %{_prefix}/bin/%{gcc_target_arch}-gcc-ranlib
%{_prefix}/bin/%{gcc_target_arch}-lto-dump %{_prefix}/bin/%{gcc_target_arch}-lto-dump
%if %{suse_version} < 1600
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-cpp %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-cpp
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc-ar %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcc-ar
@@ -489,13 +495,16 @@ fi
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-dump %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-dump
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-tool %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-gcov-tool
%endif %endif
%endif
%if %{build_cp} %if %{build_cp}
%{_prefix}/bin/%{gcc_target_arch}-c++%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-g++%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-c++ %{_prefix}/bin/%{gcc_target_arch}-c++
%{_prefix}/bin/%{gcc_target_arch}-g++ %{_prefix}/bin/%{gcc_target_arch}-g++
%if %{suse_version} < 1600
%{_prefix}/bin/%{gcc_target_arch}-c++%{binsuffix}
%{_prefix}/bin/%{gcc_target_arch}-g++%{binsuffix}
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-c++ %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-c++
%ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-g++ %ghost %{_sysconfdir}/alternatives/%{gcc_target_arch}-g++
%endif
%if 0%{!?gcc_libc_bootstrap:1} %if 0%{!?gcc_libc_bootstrap:1}
%if "%{cross_arch}" == "avr" || 0%{?gcc_target_newlib:1} || 0%{?gcc_target_glibc:1} %if "%{cross_arch}" == "avr" || 0%{?gcc_target_newlib:1} || 0%{?gcc_target_glibc:1}
%{_prefix}/include/c++ %{_prefix}/include/c++
@@ -529,4 +538,4 @@ fi
%exclude %{_prefix}/%{gcc_target_arch}/bin %exclude %{_prefix}/%{gcc_target_arch}/bin
%endif %endif
%changelog -n cross-%{pkgname}-gcc@base_ver@ %changelog -n %{pkgname}

View File

@@ -1591,11 +1591,11 @@ amdgcn-amdhsa,\
--enable-gnu-indirect-function \ --enable-gnu-indirect-function \
%endif %endif
%endif %endif
--program-suffix=%{binsuffix} \
%ifarch %{disable_multilib_arch} %ifarch %{disable_multilib_arch}
--disable-multilib \ --disable-multilib \
%endif %endif
%if 0%{!?gcc_target_arch:1} %if 0%{!?gcc_target_arch:1}
--program-suffix=%{binsuffix} \
%ifarch ia64 %ifarch ia64
--with-system-libunwind \ --with-system-libunwind \
%else %else
@@ -1603,6 +1603,9 @@ amdgcn-amdhsa,\
%endif %endif
%endif %endif
%if 0%{?gcc_target_arch:1} %if 0%{?gcc_target_arch:1}
%if 0%{?gcc_accel:1} || %{suse_version} < 1600
--program-suffix=%{binsuffix} \
%endif
--program-prefix=%{gcc_target_arch}- \ --program-prefix=%{gcc_target_arch}- \
--target=%{gcc_target_arch} \ --target=%{gcc_target_arch} \
--disable-nls \ --disable-nls \
@@ -1690,7 +1693,7 @@ amdgcn-amdhsa,\
%endif %endif
%if %{suse_version} >= 1600 && !0%{?is_opensuse} %if %{suse_version} >= 1600 && !0%{?is_opensuse}
--with-cpu=power9 \ --with-cpu=power9 \
--with-tune=power9 \ --with-tune=power10 \
%else %else
%if %{suse_version} >= 1350 %if %{suse_version} >= 1350
--with-cpu=power8 \ --with-cpu=power8 \
@@ -1759,7 +1762,7 @@ amdgcn-amdhsa,\
%endif %endif
%if "%{TARGET_ARCH}" == "s390" || "%{TARGET_ARCH}" == "s390x" %if "%{TARGET_ARCH}" == "s390" || "%{TARGET_ARCH}" == "s390x"
%if %{suse_version} >= 1600 && !0%{?is_opensuse} %if %{suse_version} >= 1600 && !0%{?is_opensuse}
--with-tune=z14 --with-arch=z14 \ --with-tune=z15 --with-arch=z14 \
%else %else
%if %{suse_version} >= 1310 %if %{suse_version} >= 1310
--with-tune=zEC12 --with-arch=z196 \ --with-tune=zEC12 --with-arch=z196 \

View File

@@ -777,11 +777,11 @@ amdgcn-amdhsa,\
--enable-gnu-indirect-function \ --enable-gnu-indirect-function \
%endif %endif
%endif %endif
--program-suffix=%{binsuffix} \
%ifarch %{disable_multilib_arch} %ifarch %{disable_multilib_arch}
--disable-multilib \ --disable-multilib \
%endif %endif
%if 0%{!?gcc_target_arch:1} %if 0%{!?gcc_target_arch:1}
--program-suffix=%{binsuffix} \
%ifarch ia64 %ifarch ia64
--with-system-libunwind \ --with-system-libunwind \
%else %else
@@ -789,6 +789,9 @@ amdgcn-amdhsa,\
%endif %endif
%endif %endif
%if 0%{?gcc_target_arch:1} %if 0%{?gcc_target_arch:1}
%if 0%{?gcc_accel:1} || %{suse_version} < 1600
--program-suffix=%{binsuffix} \
%endif
--program-prefix=%{gcc_target_arch}- \ --program-prefix=%{gcc_target_arch}- \
--target=%{gcc_target_arch} \ --target=%{gcc_target_arch} \
--disable-nls \ --disable-nls \
@@ -876,7 +879,7 @@ amdgcn-amdhsa,\
%endif %endif
%if %{suse_version} >= 1600 && !0%{?is_opensuse} %if %{suse_version} >= 1600 && !0%{?is_opensuse}
--with-cpu=power9 \ --with-cpu=power9 \
--with-tune=power9 \ --with-tune=power10 \
%else %else
%if %{suse_version} >= 1350 %if %{suse_version} >= 1350
--with-cpu=power8 \ --with-cpu=power8 \
@@ -945,7 +948,7 @@ amdgcn-amdhsa,\
%endif %endif
%if "%{TARGET_ARCH}" == "s390" || "%{TARGET_ARCH}" == "s390x" %if "%{TARGET_ARCH}" == "s390" || "%{TARGET_ARCH}" == "s390x"
%if %{suse_version} >= 1600 && !0%{?is_opensuse} %if %{suse_version} >= 1600 && !0%{?is_opensuse}
--with-tune=z14 --with-arch=z14 \ --with-tune=z15 --with-arch=z14 \
%else %else
%if %{suse_version} >= 1310 %if %{suse_version} >= 1310
--with-tune=zEC12 --with-arch=z196 \ --with-tune=zEC12 --with-arch=z196 \

View File

@@ -1,3 +1,21 @@
-------------------------------------------------------------------
Thu Jul 17 07:20:37 UTC 2025 - Richard Biener <rguenther@suse.com>
- Remove all %gcc_icecream mode cross-compilers and the corresponding
icecream backend subpackages. Instead use glibc-bootstrap only
configs for cross-x86_64-gcc (ipxe,ovmf,qemu), cross-ppc64-gcc (qemu)
and cross-arm-gcc (ovmf).
- Prune the use of update-alternatives from openSUSE Factory and
SLFO.
- Adjust crosses to conflict consistently where they did not
already and make them use unsuffixed binaries.
-------------------------------------------------------------------
Wed Jul 2 10:31:10 UTC 2025 - Richard Biener <rguenther@suse.com>
- Tune for power10 for SLES 16. [jsc#PED-12029]
- Tune for z15 for SLES 16. [jsc#PED-253]
------------------------------------------------------------------- -------------------------------------------------------------------
Thu Jun 5 17:02:16 UTC 2025 - Richard Biener <rguenther@suse.com> Thu Jun 5 17:02:16 UTC 2025 - Richard Biener <rguenther@suse.com>

View File

@@ -2601,11 +2601,11 @@ amdgcn-amdhsa,\
--enable-gnu-indirect-function \ --enable-gnu-indirect-function \
%endif %endif
%endif %endif
--program-suffix=%{binsuffix} \
%ifarch %{disable_multilib_arch} %ifarch %{disable_multilib_arch}
--disable-multilib \ --disable-multilib \
%endif %endif
%if 0%{!?gcc_target_arch:1} %if 0%{!?gcc_target_arch:1}
--program-suffix=%{binsuffix} \
%ifarch ia64 %ifarch ia64
--with-system-libunwind \ --with-system-libunwind \
%else %else
@@ -2613,6 +2613,9 @@ amdgcn-amdhsa,\
%endif %endif
%endif %endif
%if 0%{?gcc_target_arch:1} %if 0%{?gcc_target_arch:1}
%if 0%{?gcc_accel:1} || %{suse_version} < 1600
--program-suffix=%{binsuffix} \
%endif
--program-prefix=%{gcc_target_arch}- \ --program-prefix=%{gcc_target_arch}- \
--target=%{gcc_target_arch} \ --target=%{gcc_target_arch} \
--disable-nls \ --disable-nls \
@@ -2700,7 +2703,7 @@ amdgcn-amdhsa,\
%endif %endif
%if %{suse_version} >= 1600 && !0%{?is_opensuse} %if %{suse_version} >= 1600 && !0%{?is_opensuse}
--with-cpu=power9 \ --with-cpu=power9 \
--with-tune=power9 \ --with-tune=power10 \
%else %else
%if %{suse_version} >= 1350 %if %{suse_version} >= 1350
--with-cpu=power8 \ --with-cpu=power8 \
@@ -2769,7 +2772,7 @@ amdgcn-amdhsa,\
%endif %endif
%if "%{TARGET_ARCH}" == "s390" || "%{TARGET_ARCH}" == "s390x" %if "%{TARGET_ARCH}" == "s390" || "%{TARGET_ARCH}" == "s390x"
%if %{suse_version} >= 1600 && !0%{?is_opensuse} %if %{suse_version} >= 1600 && !0%{?is_opensuse}
--with-tune=z14 --with-arch=z14 \ --with-tune=z15 --with-arch=z14 \
%else %else
%if %{suse_version} >= 1310 %if %{suse_version} >= 1310
--with-tune=zEC12 --with-arch=z196 \ --with-tune=zEC12 --with-arch=z196 \