diff --git a/pocl.changes b/pocl.changes index cabf46f..d1f0d6f 100644 --- a/pocl.changes +++ b/pocl.changes @@ -1,3 +1,13 @@ +------------------------------------------------------------------- +Sat Jun 4 14:33:49 UTC 2022 - Aaron Puchert + +- Use LLVM 13 on Tumbleweed, since LLVM 14 does not yet work + according to upstream. (gh#pocl/pocl#1047, gh#pocl/pocl#1048) +- Require at least version 6 of clang-devel, older versions are + not supported. (Otherwise configuration will fail.) +- Strip prefix from CMAKE_INSTALL_LIBDIR on older distributions + to fix paths there. + ------------------------------------------------------------------- Sat Oct 30 11:37:16 UTC 2021 - Martin Hauke diff --git a/pocl.spec b/pocl.spec index cdb9747..82e74e0 100644 --- a/pocl.spec +++ b/pocl.spec @@ -1,7 +1,7 @@ # # spec file for package pocl # -# Copyright (c) 2021 SUSE LLC +# Copyright (c) 2022 SUSE LLC # Copyright (c) 2014 Guillaume GARDET # # All modifications and additions to the file contributed by third parties @@ -31,7 +31,11 @@ URL: http://portablecl.org/ Source0: https://github.com/pocl/pocl/archive/v%{version}.tar.gz#/%{name}-%{version}.tar.gz Source99: pocl-rpmlintrc Patch0: link_against_libclang-cpp_so.patch -BuildRequires: clang-devel +%if 0%{?suse_version} > 1500 +BuildRequires: clang13-devel +%else +BuildRequires: clang-devel >= 6.0.0 +%endif BuildRequires: cmake BuildRequires: gcc-c++ BuildRequires: ninja @@ -88,6 +92,11 @@ This subpackage provides the development files needed for pocl. %setup -q %patch0 -p1 +%if 0%{?suse_version} > 1500 +# Make sure we use the right LLVM version. +sed -i 's/find_program_or_die( *\([^ ]*\) *"\([^"]*\)" *"\([^"]*\)" *)/find_program_or_die(\1 "\2-%{pkg_version clang13-devel}" "\3")/g' cmake/LLVM.cmake +%endif + %build %define __builder ninja %cmake \ @@ -102,6 +111,9 @@ This subpackage provides the development files needed for pocl. %endif %ifarch aarch64 -DLLC_HOST_CPU=cortex-a53 \ +%endif +%if 0%{?suse_version} <= 1500 && 0%{?sle_version} <= 150300 + -DCMAKE_INSTALL_LIBDIR:PATH=%{_lib} \ %endif -DWITH_LLVM_CONFIG=%{_bindir}/llvm-config @@ -112,8 +124,6 @@ sed -i 's/-Wl,--no-undefined//g' build.ninja %install %cmake_install -# TODO: check packaging instructions -sed -i 's|%{_prefix}%{_prefix}/|%{_prefix}/|g' %{buildroot}%{_datadir}/OpenCL/vendors/pocl.icd # Unbundle vecmath #rm -vf %%{buildroot}/%%{_libdir}/pocl/vecmath/ #ln -vs %%{_includedir}/vecmath %%{buildroot}/%%{_libdir}/pocl/vecmath