!15 Add toolchain_clang build support
From: @liyunfei33 Reviewed-by: @cf-zhao Signed-off-by: @cf-zhao
This commit is contained in:
commit
955b6790f5
14
lld.spec
14
lld.spec
@ -1,5 +1,10 @@
|
||||
%bcond_without sys_llvm
|
||||
%bcond_without check
|
||||
%bcond_without toolchain_clang
|
||||
|
||||
%if %{with toolchain_clang}
|
||||
%global toolchain clang
|
||||
%endif
|
||||
|
||||
%global maj_ver 17
|
||||
%global min_ver 0
|
||||
@ -32,7 +37,7 @@
|
||||
|
||||
Name: %{pkg_name}
|
||||
Version: %{maj_ver}.%{min_ver}.%{patch_ver}
|
||||
Release: 2
|
||||
Release: 3
|
||||
Summary: The LLVM Linker
|
||||
|
||||
License: NCSA
|
||||
@ -104,6 +109,10 @@ cd _build
|
||||
-DLLVM_LIT_ARGS="-sv \
|
||||
--path %{install_prefix}" \
|
||||
-DLLVM_COMMON_CMAKE_UTILS=%{install_datadir}/llvm/cmake \
|
||||
%if "%{toolchain}" == "clang"
|
||||
-DCMAKE_C_COMPILER=clang \
|
||||
-DCMAKE_CXX_COMPILER=clang++ \
|
||||
%endif
|
||||
-DLLVM_MAIN_SRC_DIR=%{install_prefix}/src
|
||||
|
||||
%ninja_build
|
||||
@ -131,6 +140,9 @@ rm %{buildroot}%{install_includedir}/mach-o/compact_unwind_encoding.h
|
||||
%{install_libdir}/liblld*.so.*
|
||||
|
||||
%changelog
|
||||
* Fri Jul 5 2024 liyunfei <liyunfei33@huawei.com> - 17.0.6-3
|
||||
- Add toolchain_clang build support
|
||||
|
||||
* Mon Mar 25 2024 zhanglimin <zhanglimin@loongson.cn> - 17.0.6-2
|
||||
- Supoort `relax` feature on LoongArch
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user