]> git.pld-linux.org Git - packages/llvm.git/blobdiff - llvm.spec
disable memory profiling runtime on x32
[packages/llvm.git] / llvm.spec
index 3fb9d6151d7bc9a5fa522c5ae92148323bd5ecd9..2b2073bccdb294f8268e74f4bed343f748058f28 100644 (file)
--- a/llvm.spec
+++ b/llvm.spec
@@ -10,6 +10,8 @@
 #      %{_datadir}/clang/clang-rename.el
 # - no content in doc package (it used to contain parts of clang apidocs and some examples)
 # - system isl in polly?
+# - dependencies and files for lua module
+# - figure out whether we need obj.MLIRCAPIIR files
 #
 # Conditional build:
 %bcond_without lldb                    # LLDB debugger
@@ -35,6 +37,7 @@
 %bcond_without target_riscv            # RISCV target support
 %bcond_without target_sparc            # Sparc target support
 %bcond_without target_systemz          # SystemZ target support
+%bcond_without target_ve               # VE target support
 %bcond_without target_webassembly      # WebAssembly target support
 %bcond_without target_x86              # X86 target support
 %bcond_without target_xcore            # XCore target support
@@ -56,7 +59,7 @@
 %define                with_lowmem             1
 %endif
 
-%define                targets_to_build        %{?with_target_aarch64:AArch64;}%{?with_target_amdgpu:AMDGPU;}%{?with_target_arm:ARM;}%{?with_target_avr:AVR;}%{?with_target_bpf:BPF;}%{?with_target_hexagon:Hexagon;}%{?with_target_lanai:Lanai;}%{?with_target_mips:Mips;}%{?with_target_msp430:MSP430;}%{?with_target_nvptx:NVPTX;}%{?with_target_powerpc:PowerPC;}%{?with_target_riscv:RISCV;}%{?with_target_sparc:Sparc;}%{?with_target_systemz:SystemZ;}%{?with_target_webassembly:WebAssembly;}%{?with_target_x86:X86;}%{?with_target_xcore:XCore;}
+%define                targets_to_build        %{?with_target_aarch64:AArch64;}%{?with_target_amdgpu:AMDGPU;}%{?with_target_arm:ARM;}%{?with_target_avr:AVR;}%{?with_target_bpf:BPF;}%{?with_target_hexagon:Hexagon;}%{?with_target_lanai:Lanai;}%{?with_target_mips:Mips;}%{?with_target_msp430:MSP430;}%{?with_target_nvptx:NVPTX;}%{?with_target_powerpc:PowerPC;}%{?with_target_riscv:RISCV;}%{?with_target_sparc:Sparc;}%{?with_target_systemz:SystemZ;}%{?with_target_ve:VE;}%{?with_target_webassembly:WebAssembly;}%{?with_target_x86:X86;}%{?with_target_xcore:XCore;}
 
 %if %{without mlir}
 %undefine      with_flang
 Summary:       The Low Level Virtual Machine (An Optimizing Compiler Infrastructure)
 Summary(pl.UTF-8):     Niskopoziomowa maszyna wirtualna (infrastruktura kompilatora optymalizującego)
 Name:          llvm
-Version:       13.0.0
-Release:       4
+Version:       14.0.4
+Release:       1
 License:       Apache 2.0 with LLVM exceptions
 Group:         Development/Languages
 #Source0Download: https://github.com/llvm/llvm-project/releases/
 Source0:       https://github.com/llvm/llvm-project/releases/download/llvmorg-%{version}/%{name}-%{version}.src.tar.xz
-# Source0-md5: 8c24626dce3ee9d87d1079ebf0897db5
+# Source0-md5: 8aad3395466b23d3d34e98dbe386b018
 Source1:       https://github.com/llvm/llvm-project/releases/download/llvmorg-%{version}/clang-%{version}.src.tar.xz
-# Source1-md5: 020cbac6e5786094fe4f96f72e290763
+# Source1-md5: 335980de1f61d2641acc83bdf0ab0faf
 Source2:       https://github.com/llvm/llvm-project/releases/download/llvmorg-%{version}/compiler-rt-%{version}.src.tar.xz
-# Source2-md5: e2e136656d27d60c5f40e20260f63c07
+# Source2-md5: 1068037dce5e42a0eeb2217484f501fd
 Source3:       https://github.com/llvm/llvm-project/releases/download/llvmorg-%{version}/lldb-%{version}.src.tar.xz
-# Source3-md5: 0956c6078d1fd3bee22d064e2addd784
+# Source3-md5: 8741b5d30a5390a7daef639cf4042f0c
 Source4:       https://github.com/llvm/llvm-project/releases/download/llvmorg-%{version}/polly-%{version}.src.tar.xz
-# Source4-md5: 4bde9e5c4d739576cf2d804d50c822d6
+# Source4-md5: 5d37eabbfb147314187fc8abe7880796
 Source5:       https://github.com/llvm/llvm-project/releases/download/llvmorg-%{version}/clang-tools-extra-%{version}.src.tar.xz
-# Source5-md5: f86778fc0d97508b4d7c244d93ebf944
+# Source5-md5: 2c71885c8bad1724cea3d021224a69a1
 Source6:       https://github.com/llvm/llvm-project/releases/download/llvmorg-%{version}/lld-%{version}.src.tar.xz
-# Source6-md5: e4f95d6cb895ebedf2c3224585682159
+# Source6-md5: cd93e87550e48b1a8ae3ee638861f47c
 Source7:       https://github.com/llvm/llvm-project/releases/download/llvmorg-%{version}/flang-%{version}.src.tar.xz
-# Source7-md5: 4125a570905dd2755748e6f33442b74d
-# "mlir" subdir extracted from https://github.com/llvm/llvm-project/releases/download/llvmorg-13.0.0/llvm-project-13.0.0.src.tar.xz
+# Source7-md5: ce6eebfe98c5372c969cd1da6145bfb6
+# "mlir" subdir extracted from https://github.com/llvm/llvm-project/releases/download/llvmorg-13.0.1/llvm-project-13.0.1.src.tar.xz
 Source8:       mlir-%{version}.tar.xz
-# Source8-md5: de6a9476ef2a52b59d7c29a8bb786719
+# Source8-md5: 34fbb0505b40478016d9e518b0fcf24c
 Patch1:                %{name}-pld.patch
 Patch2:                %{name}-python-modules.patch
 Patch3:                x32-gcc-toolchain.patch
@@ -98,6 +101,7 @@ Patch6:              %{name}-flang.patch
 Patch7:                llvm12-build_fixes.patch
 Patch8:                %{name}-selective_bindings.patch
 Patch9:                %{name}-libexecdir.patch
+Patch10:       compiler-rt-paths.patch
 URL:           https://llvm.org/
 BuildRequires: bash
 BuildRequires: binutils-devel
@@ -123,6 +127,7 @@ BuildRequires:      perl-tools-pod
 BuildRequires: python3 >= 1:3
 BuildRequires: python3-PyYAML
 BuildRequires: python3-pygments >= 2.0
+BuildRequires: rpm-build >= 4.6
 BuildRequires: rpm-pythonprov
 BuildRequires: rpmbuild(macros) >= 1.742
 %{?with_doc:BuildRequires:     sphinx-pdg}
@@ -142,12 +147,14 @@ BuildRequires:    tcl-devel
 %if %{with rt} && %{with multilib}
 %ifarch %{x8664}
 BuildRequires: gcc-c++-multilib-32
+BuildRequires: glibc-devel(ix86)
 BuildRequires: libstdc++-multilib-32-devel
 %endif
 %ifarch x32
 BuildRequires: gcc-c++-multilib-32
 BuildRequires: gcc-c++-multilib-64
 BuildRequires: glibc-devel(x86_64)
+BuildRequires: glibc-devel(ix86)
 BuildRequires: libstdc++-multilib-32-devel
 BuildRequires: libstdc++-multilib-64-devel
 %endif
@@ -181,7 +188,7 @@ Requires:   %{name}-libs = %{version}-%{release}
 ExcludeArch:   ppc64
 BuildRoot:     %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
 
-%define                abi     13
+%define                abi     14
 %define                _sysconfdir     /etc/%{name}
 
 %define                specflags_ppc   -fno-var-tracking-assignments
@@ -681,9 +688,12 @@ Integracja narzędzi Clang do formatowania i zmiany nazw z Vimem.
 %patch7 -p1
 %patch8 -p1
 %patch9 -p1
+%if %{with rt}
+%patch10 -p1
+%endif
 
 grep -rl /usr/bin/env projects tools utils | xargs sed -i -e '1{
-       s,^#!.*bin/env python,#!%{__python3},
+       s,^#!.*bin/env python3\?,#!%{__python3},
        s,^#!.*bin/env perl,#!%{__perl},
 }'
 
@@ -716,6 +726,7 @@ export LDFLAGS="%{rpmldflags} -Wl,--reduce-memory-overheads"
        -DLLVM_BINUTILS_INCDIR:STRING=%{_includedir} \
        -DLLVM_BUILD_LLVM_DYLIB:BOOL=ON \
        -DLLVM_ENABLE_ASSERTIONS:BOOL=OFF \
+       -DLLVM_TOOLS_INSTALL_DIR=%(realpath -m "--relative-to=%{_prefix}" "%{_bindir}") \
 %if %{with apidocs}
        -DLLVM_ENABLE_DOXYGEN:BOOL=ON \
 %endif
@@ -725,6 +736,7 @@ export LDFLAGS="%{rpmldflags} -Wl,--reduce-memory-overheads"
 %if %{with doc}
        -DLLVM_ENABLE_SPHINX:BOOL=ON \
 %endif
+       -DLLVM_INCLUDE_BENCHMARKS:BOOL=OFF \
        %{?with_z3:-DLLVM_ENABLE_Z3_SOLVER:BOOL=ON} \
 %if "%{_lib}" == "lib64"
        -DLLVM_LIBDIR_SUFFIX:STRING=64 \
@@ -741,7 +753,12 @@ export LDFLAGS="%{rpmldflags} -Wl,--reduce-memory-overheads"
 %if %{with polly}
        %{cmake_on_off target_nvptx POLLY_ENABLE_GPGPU_CODEGEN} \
 %endif
-       -DSPHINX_WARNINGS_AS_ERRORS=OFF
+       -DSPHINX_WARNINGS_AS_ERRORS=OFF \
+%if %{with rt}
+%ifarch x32
+       -DCOMPILER_RT_BUILD_MEMPROF:BOOL=OFF
+%endif
+%endif
 
 %{__make} \
        VERBOSE=1 \
@@ -762,7 +779,7 @@ export LDFLAGS="%{rpmldflags} -Wl,--reduce-memory-overheads"
 %{__make} -C tools/clang/docs docs-clang-man
 %{__make} -C tools/lld/docs docs-lld-html
 # workaround failed import of _lldb
-cp -pnL %{_lib}/python%{py3_ver}/site-packages/lldb/_lldb.so tools/lldb/docs/lldb
+cp -pnL %{_lib}/liblldb.so tools/lldb/docs/lldb/_lldb.so
 %{__make} \
        LD_LIBRARY_PATH=$(pwd)/%{_lib} \
        -C tools/lldb/docs lldb-python-doc-package
@@ -873,6 +890,7 @@ rm -rf $RPM_BUILD_ROOT
 %attr(755,root,root) %{_bindir}/llvm-cxxdump
 %attr(755,root,root) %{_bindir}/llvm-cxxfilt
 %attr(755,root,root) %{_bindir}/llvm-cxxmap
+%attr(755,root,root) %{_bindir}/llvm-debuginfod-find
 %attr(755,root,root) %{_bindir}/llvm-diff
 %attr(755,root,root) %{_bindir}/llvm-dis
 %attr(755,root,root) %{_bindir}/llvm-dlltool
@@ -918,6 +936,7 @@ rm -rf $RPM_BUILD_ROOT
 %attr(755,root,root) %{_bindir}/llvm-symbolizer
 %attr(755,root,root) %{_bindir}/llvm-tapi-diff
 %attr(755,root,root) %{_bindir}/llvm-tblgen
+%attr(755,root,root) %{_bindir}/llvm-tli-checker
 %attr(755,root,root) %{_bindir}/llvm-undname
 %attr(755,root,root) %{_bindir}/llvm-windres
 %attr(755,root,root) %{_bindir}/llvm-xray
@@ -967,6 +986,7 @@ rm -rf $RPM_BUILD_ROOT
 %{_mandir}/man1/llvm-strip.1*
 %{_mandir}/man1/llvm-symbolizer.1*
 %{_mandir}/man1/llvm-tblgen.1*
+%{_mandir}/man1/llvm-tli-checker.1*
 %{_mandir}/man1/opt.1*
 %{_mandir}/man1/tblgen.1*
 %endif
@@ -977,9 +997,9 @@ rm -rf $RPM_BUILD_ROOT
 %attr(755,root,root) %{_libdir}/libLLVM-%{abi}.so
 # non-soname symlink
 %attr(755,root,root) %{_libdir}/libLLVM-%{version}.so
-%attr(755,root,root) %{_libdir}/libLTO.so.13
-%attr(755,root,root) %{_libdir}/libRemarks.so.13
-%attr(755,root,root) %{_libdir}/libclang-cpp.so.13
+%attr(755,root,root) %{_libdir}/libLTO.so.14
+%attr(755,root,root) %{_libdir}/libRemarks.so.14
+%attr(755,root,root) %{_libdir}/libclang-cpp.so.14
 
 %files devel
 %defattr(644,root,root,755)
@@ -1009,18 +1029,20 @@ rm -rf $RPM_BUILD_ROOT
 %files mlir
 %defattr(644,root,root,755)
 %attr(755,root,root) %{_bindir}/mlir-cpu-runner
-%attr(755,root,root) %{_bindir}/mlir-linalg-ods-gen
 %attr(755,root,root) %{_bindir}/mlir-linalg-ods-yaml-gen
 %attr(755,root,root) %{_bindir}/mlir-lsp-server
 %attr(755,root,root) %{_bindir}/mlir-opt
+%attr(755,root,root) %{_bindir}/mlir-pdll
 %attr(755,root,root) %{_bindir}/mlir-reduce
 %attr(755,root,root) %{_bindir}/mlir-tblgen
 %attr(755,root,root) %{_bindir}/mlir-translate
-%attr(755,root,root) %{_libdir}/libMLIR.so.13
-%attr(755,root,root) %{_libdir}/libmlir_async_runtime.so.13
-%attr(755,root,root) %{_libdir}/libmlir_c_runner_utils.so.13
-%attr(755,root,root) %{_libdir}/libmlir_runner_utils.so.13
+%attr(755,root,root) %{_libdir}/libMLIR.so.14
+%attr(755,root,root) %{_libdir}/libmlir_async_runtime.so.14
+%attr(755,root,root) %{_libdir}/libmlir_c_runner_utils.so.14
+%attr(755,root,root) %{_libdir}/libmlir_runner_utils.so.14
+%if %{with doc}
 %{_mandir}/man1/mlir-tblgen.1*
+%endif
 
 %files mlir-devel
 %defattr(644,root,root,755)
@@ -1061,6 +1083,8 @@ rm -rf $RPM_BUILD_ROOT
 %attr(755,root,root) %{_bindir}/clang-cpp
 %attr(755,root,root) %{_bindir}/clang-doc
 %attr(755,root,root) %{_bindir}/clang-format
+%attr(755,root,root) %{_bindir}/clang-linker-wrapper
+%attr(755,root,root) %{_bindir}/clang-nvlink-wrapper
 %attr(755,root,root) %{_bindir}/clang-offload-bundler
 %attr(755,root,root) %{_bindir}/clang-offload-wrapper
 %attr(755,root,root) %{_bindir}/clang-repl
@@ -1152,7 +1176,7 @@ rm -rf $RPM_BUILD_ROOT
 
 %files -n clang-libs
 %defattr(644,root,root,755)
-%attr(755,root,root) %{_libdir}/libclang.so.%{abi}
+%attr(755,root,root) %{_libdir}/libclang.so.13
 %attr(755,root,root) %{_libdir}/libclang.so.*.*.*
 
 %files -n clang-devel
@@ -1263,8 +1287,6 @@ rm -rf $RPM_BUILD_ROOT
 %doc tools/lld/{LICENSE.TXT,README.md}
 %attr(755,root,root) %{_bindir}/ld.lld
 %attr(755,root,root) %{_bindir}/ld64.lld
-%attr(755,root,root) %{_bindir}/ld64.lld.darwinnew
-%attr(755,root,root) %{_bindir}/ld64.lld.darwinold
 %attr(755,root,root) %{_bindir}/lld
 %attr(755,root,root) %{_bindir}/lld-link
 %attr(755,root,root) %{_bindir}/wasm-ld
@@ -1284,8 +1306,8 @@ rm -rf $RPM_BUILD_ROOT
 %attr(755,root,root) %{_bindir}/lldb-server
 %attr(755,root,root) %{_bindir}/lldb-vscode
 %attr(755,root,root) %{_libdir}/liblldb.so.%{version}
-%attr(755,root,root) %ghost %{_libdir}/liblldb.so.13
-%attr(755,root,root) %ghost %{_libdir}/liblldbIntelFeatures.so.13
+%attr(755,root,root) %ghost %{_libdir}/liblldb.so.14
+%attr(755,root,root) %ghost %{_libdir}/liblldbIntelFeatures.so.14
 %dir %{py3_sitedir}/lldb
 %attr(755,root,root) %{py3_sitedir}/lldb/lldb-argdumper
 %{py3_sitedir}/lldb/formatters
@@ -1297,7 +1319,7 @@ rm -rf $RPM_BUILD_ROOT
 %{py3_sitedir}/lldb/plugins/__pycache__
 %{py3_sitedir}/lldb/plugins/__init__.py
 %{py3_sitedir}/lldb/plugins/scripted_process.py
-%attr(755,root,root) %{py3_sitedir}/lldb/_lldb.so
+%attr(755,root,root) %{py3_sitedir}/lldb/_lldb.cpython-*-linux-gnu.so
 
 %files -n lldb-devel
 %defattr(644,root,root,755)
@@ -1319,6 +1341,8 @@ rm -rf $RPM_BUILD_ROOT
 %defattr(644,root,root,755)
 %{_libdir}/ocaml/llvm/libllvm*.a
 %{_libdir}/ocaml/llvm/llvm*.a
+%{_libdir}/ocaml/llvm/llvm*.cmt
+%{_libdir}/ocaml/llvm/llvm*.cmti
 %{_libdir}/ocaml/llvm/llvm*.cmx
 %{_libdir}/ocaml/llvm/llvm*.cmxa
 %{_libdir}/ocaml/llvm/llvm*.mli
This page took 0.179055 seconds and 4 git commands to generate.