!12 Add toolchain_clang build support

From: @liyunfei33 
Reviewed-by: @cf-zhao 
Signed-off-by: @cf-zhao
This commit is contained in:
openeuler-ci-bot 2024-07-15 03:31:48 +00:00 committed by Gitee
commit 105bd4ff11
No known key found for this signature in database
GPG Key ID: 173E9B9CA92EEF8F

View File

@ -1,5 +1,10 @@
%bcond_without sys_llvm %bcond_without sys_llvm
%bcond_with check %bcond_with check
%bcond_without toolchain_clang
%if %{with toolchain_clang}
%global toolchain clang
%endif
%global toolchain clang %global toolchain clang
@ -32,7 +37,7 @@
Name: %{pkg_name} Name: %{pkg_name}
Version: %{openmp_version} Version: %{openmp_version}
Release: 1 Release: 2
Summary: OpenMP runtime for clang Summary: OpenMP runtime for clang
License: Apache License 2.0 License: Apache License 2.0
@ -93,6 +98,10 @@ OpenMP header files.
-DOPENMP_LIBDIR_SUFFIX=64 \ -DOPENMP_LIBDIR_SUFFIX=64 \
%else %else
-DOPENMP_LIBDIR_SUFFIX= \ -DOPENMP_LIBDIR_SUFFIX= \
%endif
%if "%{toolchain}" == "clang"
-DCMAKE_C_COMPILER=clang \
-DCMAKE_CXX_COMPILER=clang++ \
%endif %endif
-DCMAKE_SKIP_RPATH:BOOL=ON -DCMAKE_SKIP_RPATH:BOOL=ON
@ -139,6 +148,9 @@ rm -rf %{buildroot}%{install_libdir}/libarcher_static.a
%{install_libdir}/libomptarget.so %{install_libdir}/libomptarget.so
%changelog %changelog
* Fri Jul 5 2024 liyunfei <liyunfei33@huawei.com> - 17.0.6-2
- Add toolchain_clang build support
* Mon Dec 4 2023 zhoujing <zhoujing106@huawei.com> - 17.0.6-1 * Mon Dec 4 2023 zhoujing <zhoujing106@huawei.com> - 17.0.6-1
- Update to 17.0.6 - Update to 17.0.6