1
0
forked from pool/spirv-tools

15.4 compiler selection

OBS-URL: https://build.opensuse.org/package/show/X11:Wayland/spirv-tools?expand=0&rev=100
This commit is contained in:
Jan Engelhardt 2023-05-30 22:35:02 +00:00 committed by Git OBS Bridge
parent 6864323f51
commit 6096414317

View File

@ -32,7 +32,11 @@ Source9: baselibs.conf
Patch1: ver.diff
BuildRequires: bison
BuildRequires: cmake >= 3.17.2
%if 0%{?suse_version} >= 1599
BuildRequires: gcc-c++
%else
BuildRequires: gcc11-c++
%endif
BuildRequires: pkg-config
BuildRequires: python3-base
BuildRequires: python3-xml
@ -69,6 +73,9 @@ find . -type f -name CMakeLists.txt -exec \
perl -i -pe 's{\@PACKAGE_VERSION\@}{%version}' CMakeLists.txt {} +
%build
%if 0%{?suse_version} && 0%{?suse_version} < 1599
export CXX=g++-11
%endif
%cmake -DSPIRV-Headers_SOURCE_DIR="%_prefix" \
-DSPIRV_TOOLS_BUILD_STATIC:BOOL=OFF -DBUILD_SHARED_LIBS:BOOL=ON
%cmake_build