Add dependency on libomp-devel

This fixes compiling with -fopenmp, because clang needs libomp-devel
to be installed so it can find omp.h.
This commit is contained in:
Tom Stellard 2020-03-20 18:43:23 +00:00
parent fd397b2953
commit 7a3aee27c2
2 changed files with 29 additions and 1 deletions

View File

@ -4,7 +4,7 @@
%global min_ver 0 %global min_ver 0
%global patch_ver 0 %global patch_ver 0
%global rc_ver 5 %global rc_ver 5
%global baserelease 0.8 %global baserelease 0.9
%global clang_tools_binaries \ %global clang_tools_binaries \
%{_bindir}/clang-apply-replacements \ %{_bindir}/clang-apply-replacements \
@ -159,6 +159,9 @@ as libraries and designed to be loosely-coupled and extensible.
%package libs %package libs
Summary: Runtime library for clang Summary: Runtime library for clang
Recommends: compiler-rt%{?_isa} = %{version} Recommends: compiler-rt%{?_isa} = %{version}
# libomp-devel is required, so clang can find the omp.h header when compiling
# with -fopenmp.
Recommends: libomp-devel%{_isa} = %{version}
Recommends: libomp%{_isa} = %{version} Recommends: libomp%{_isa} = %{version}
%description libs %description libs
@ -456,6 +459,9 @@ LD_LIBRARY_PATH=%{buildroot}%{_libdir} ninja check-all -C _build || \
%endif %endif
%changelog %changelog
* Fri Mar 20 2020 Tom Stellard <tstellar@redhat.com> - 10.0.0-0.9.rc5
- Add dependency on libomp-devel
* Fri Mar 20 2020 sguelton@redhat.com - 10.0.0-0.8.rc5 * Fri Mar 20 2020 sguelton@redhat.com - 10.0.0-0.8.rc5
- 10.0.0 rc5 - 10.0.0 rc5

22
tests/tests-libomp.yml Normal file
View File

@ -0,0 +1,22 @@
- hosts: localhost
pre_tasks:
# We want to make sure libomp is not already present on the system to ensure
# that clang pulls in the correct libomp dependencies when it is installed.
- name: Uninstall libomp
package:
name: "{{ item }}"
state: absent
with_items:
- libomp
- libomp-devel
roles:
- role: standard-test-basic
tags:
- classic
repositories:
- repo: "https://src.fedoraproject.org/tests/clang.git"
dest: "clang"
required_packages:
- clang
tests:
- clang/libomp