mirror of
https://src.fedoraproject.org/rpms/llvm.git
synced 2024-12-01 03:32:55 +00:00
Disable LTO on i686
We're reaching a memory limit while linking libLLVM.so .
This commit is contained in:
parent
15eacb3329
commit
c7a62f31ea
1 changed files with 21 additions and 7 deletions
28
llvm.spec
28
llvm.spec
|
@ -24,6 +24,16 @@
|
||||||
%bcond_with compat_build
|
%bcond_with compat_build
|
||||||
%bcond_without check
|
%bcond_without check
|
||||||
|
|
||||||
|
%ifarch %ix86
|
||||||
|
# Disable LTO on x86 in order to reduce memory consumption
|
||||||
|
%bcond_with lto_build
|
||||||
|
%elif %{with snapshot_build}
|
||||||
|
# Disable LTO to speed up builds
|
||||||
|
%bcond_with lto_build
|
||||||
|
%else
|
||||||
|
%bcond_without lto_build
|
||||||
|
%endif
|
||||||
|
|
||||||
%global maj_ver 17
|
%global maj_ver 17
|
||||||
%global min_ver 0
|
%global min_ver 0
|
||||||
%global patch_ver 0
|
%global patch_ver 0
|
||||||
|
@ -90,7 +100,7 @@
|
||||||
|
|
||||||
Name: %{pkg_name}
|
Name: %{pkg_name}
|
||||||
Version: %{maj_ver}.%{min_ver}.%{patch_ver}%{?rc_ver:~rc%{rc_ver}}%{?llvm_snapshot_version_suffix:~%{llvm_snapshot_version_suffix}}
|
Version: %{maj_ver}.%{min_ver}.%{patch_ver}%{?rc_ver:~rc%{rc_ver}}%{?llvm_snapshot_version_suffix:~%{llvm_snapshot_version_suffix}}
|
||||||
Release: 3%{?dist}
|
Release: 4%{?dist}
|
||||||
Summary: The Low Level Virtual Machine
|
Summary: The Low Level Virtual Machine
|
||||||
|
|
||||||
License: Apache-2.0 WITH LLVM-exception OR NCSA
|
License: Apache-2.0 WITH LLVM-exception OR NCSA
|
||||||
|
@ -261,8 +271,7 @@ mv %{third_party_srcdir} third-party
|
||||||
|
|
||||||
%build
|
%build
|
||||||
|
|
||||||
# Disable LTO to speed up builds
|
%if %{without lto_build}
|
||||||
%if %{with snapshot_build}
|
|
||||||
%global _lto_cflags %nil
|
%global _lto_cflags %nil
|
||||||
%endif
|
%endif
|
||||||
|
|
||||||
|
@ -353,8 +362,10 @@ export ASMFLAGS="%{build_cflags}"
|
||||||
-DLLVM_INSTALL_SPHINX_HTML_DIR=%{_pkgdocdir}/html \
|
-DLLVM_INSTALL_SPHINX_HTML_DIR=%{_pkgdocdir}/html \
|
||||||
-DSPHINX_EXECUTABLE=%{_bindir}/sphinx-build-3 \
|
-DSPHINX_EXECUTABLE=%{_bindir}/sphinx-build-3 \
|
||||||
-DLLVM_INCLUDE_BENCHMARKS=OFF \
|
-DLLVM_INCLUDE_BENCHMARKS=OFF \
|
||||||
-DCMAKE_SHARED_LINKER_FLAGS="$LDFLAGS -Wl,-z,cet-report=error" \
|
%if %{with lto_build}
|
||||||
-DLLVM_UNITTEST_LINK_FLAGS="-Wl,-plugin-opt=O0"
|
-DLLVM_UNITTEST_LINK_FLAGS="-Wl,-plugin-opt=O0" \
|
||||||
|
%endif
|
||||||
|
-DCMAKE_SHARED_LINKER_FLAGS="$LDFLAGS -Wl,-z,cet-report=error"
|
||||||
|
|
||||||
# Build libLLVM.so first. This ensures that when libLLVM.so is linking, there
|
# Build libLLVM.so first. This ensures that when libLLVM.so is linking, there
|
||||||
# are no other compile jobs running. This will help reduce OOM errors on the
|
# are no other compile jobs running. This will help reduce OOM errors on the
|
||||||
|
@ -601,11 +612,14 @@ fi
|
||||||
%endif
|
%endif
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
%{?llvm_snapshot_changelog_entry}
|
||||||
|
|
||||||
|
* Wed Aug 16 2023 Tulio Magno Quites Machado Filho <tuliom@redhat.com> - 17.0.0~rc1-4
|
||||||
|
- Disable LTO on i686
|
||||||
|
|
||||||
* Mon Aug 14 2023 Tulio Magno Quites Machado Filho <tuliom@redhat.com> - 17.0.0~rc1-3
|
* Mon Aug 14 2023 Tulio Magno Quites Machado Filho <tuliom@redhat.com> - 17.0.0~rc1-3
|
||||||
- Re-add patch removed by mistake
|
- Re-add patch removed by mistake
|
||||||
|
|
||||||
%{?llvm_snapshot_changelog_entry}
|
|
||||||
|
|
||||||
* Tue Aug 01 2023 Tulio Magno Quites Machado Filho <tuliom@redhat.com> - 17.0.0~rc1-2
|
* Tue Aug 01 2023 Tulio Magno Quites Machado Filho <tuliom@redhat.com> - 17.0.0~rc1-2
|
||||||
- Enable LLVM_UNREACHABLE_OPTIMIZE temporarily
|
- Enable LLVM_UNREACHABLE_OPTIMIZE temporarily
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue