From 7eac7bb317e8d9a33b482ae4cd6e38d8c1f0355081ad9480df54e397aa8fa4ef Mon Sep 17 00:00:00 2001 From: Stefan Dirsch Date: Sat, 28 Jan 2023 19:16:05 +0000 Subject: [PATCH] Accepting request 1061754 from home:aaronpuchert:branches:X11:XOrg - Add support for SPIR-V targets on Tumbleweed. OBS-URL: https://build.opensuse.org/request/show/1061754 OBS-URL: https://build.opensuse.org/package/show/X11:XOrg/libclc?expand=0&rev=56 --- libclc.changes | 5 +++++ libclc.spec | 10 ++++++---- 2 files changed, 11 insertions(+), 4 deletions(-) diff --git a/libclc.changes b/libclc.changes index fc7fcc9..8544745 100644 --- a/libclc.changes +++ b/libclc.changes @@ -1,3 +1,8 @@ +------------------------------------------------------------------- +Sat Jan 28 14:28:38 UTC 2023 - Aaron Puchert + +- Add support for SPIR-V targets on Tumbleweed. + ------------------------------------------------------------------- Sat Nov 5 11:05:57 UTC 2022 - Stefan Dirsch diff --git a/libclc.spec b/libclc.spec index 19f8624..525f68d 100644 --- a/libclc.spec +++ b/libclc.spec @@ -1,7 +1,7 @@ # # spec file for package libclc # -# Copyright (c) 2022 SUSE LLC +# Copyright (c) 2023 SUSE LLC # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed @@ -35,6 +35,7 @@ BuildRequires: cmake %if 0%{?suse_version} >= 1550 BuildRequires: clang-devel BuildRequires: llvm-devel +BuildRequires: pkgconfig(LLVMSPIRVLib) %else %if 0%{?sle_version} >= 150500 BuildRequires: clang15-devel @@ -70,7 +71,6 @@ Library requirements of the OpenCL C programming language. %define _lto_cflags %{nil} # For now we turn off opaque pointers - Clang uses them by default, but Mesa doesn't support them yet. -# TODO: For building all targets, we need llvm-spirv. %cmake \ -DCMAKE_C_COMPILER=clang \ -DCMAKE_CXX_COMPILER=clang++ \ @@ -78,8 +78,10 @@ Library requirements of the OpenCL C programming language. -DCMAKE_CLC_FLAGS="-Xclang -no-opaque-pointers" \ -DCMAKE_LLAsm_FLAGS="-Xclang -no-opaque-pointers" \ %endif - -DENABLE_RUNTIME_SUBNORMAL:BOOL=ON \ - -DLIBCLC_TARGETS_TO_BUILD="amdgcn--;amdgcn--amdhsa;amdgcn-mesa-mesa3d;r600--;nvptx--;nvptx64--;nvptx--nvidiacl;nvptx64--nvidiacl" +%if 0%{?suse_version} < 1550 + -DLIBCLC_TARGETS_TO_BUILD="amdgcn--;amdgcn--amdhsa;amdgcn-mesa-mesa3d;r600--;nvptx--;nvptx64--;nvptx--nvidiacl;nvptx64--nvidiacl" \ +%endif + -DENABLE_RUNTIME_SUBNORMAL:BOOL=ON %cmake_build %install