ci: build our own version of the LLVM SPIRV translator

Debian stable and Fedora do not package the required version for
intel-clc.

Signed-off-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Reviewed-by: David Heidelberg <david.heidelberg@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18788>
This commit is contained in:
Lionel Landwerlin
2022-09-22 18:56:45 +03:00
committed by Marge Bot
parent 05b1f3fd97
commit 78b1e0340e
5 changed files with 32 additions and 7 deletions

View File

@@ -0,0 +1,19 @@
#!/bin/bash
set -ex
wget https://github.com/KhronosGroup/SPIRV-LLVM-Translator/archive/refs/tags/v13.0.0.tar.gz
tar -xvf v13.0.0.tar.gz && rm v13.0.0.tar.gz
mkdir SPIRV-LLVM-Translator-13.0.0/build
pushd SPIRV-LLVM-Translator-13.0.0/build
cmake .. -G Ninja -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=/usr
ninja
ninja install
# For some reason llvm-spirv is not installed by default
ninja llvm-spirv
cp tools/llvm-spirv/llvm-spirv /usr/bin/
popd
du -sh SPIRV-LLVM-Translator-13.0.0
rm -rf SPIRV-LLVM-Translator-13.0.0

View File

@@ -29,7 +29,6 @@ apt-get install -y --no-remove \
libclang-cpp11-dev \
libgbm-dev \
libglvnd-dev \
libllvmspirvlib-dev \
liblua5.3-dev \
libxcb-dri2-0-dev \
libxcb-dri3-dev \
@@ -69,6 +68,8 @@ tar -xvf $XORGMACROS_VERSION.tar.bz2 && rm $XORGMACROS_VERSION.tar.bz2
cd $XORGMACROS_VERSION; ./configure; make install; cd ..
rm -rf $XORGMACROS_VERSION
. .gitlab-ci/container/build-llvm-spirv.sh
. .gitlab-ci/container/build-libdrm.sh
. .gitlab-ci/container/build-wayland.sh

View File

@@ -19,6 +19,7 @@ STABLE_EPHEMERAL=" \
bison \
bzip2 \
ccache \
cmake \
clang-11 \
flex \
glslang-tools \
@@ -35,6 +36,8 @@ STABLE_EPHEMERAL=" \
libwayland-dev \
libx11-xcb-dev \
libxext-dev \
llvm-13-dev \
llvm-11-dev \
make \
meson \
patch \
@@ -43,6 +46,7 @@ STABLE_EPHEMERAL=" \
python3-pip \
python3-setuptools \
python3-wheel \
spirv-tools \
wayland-protocols \
xz-utils \
"
@@ -118,6 +122,10 @@ pip3 install git+http://gitlab.freedesktop.org/freedesktop/ci-templates@34f4ade9
# Needed for manipulation with traces yaml files.
pip3 install yq
############### Build LLVM-SPIRV translator
. .gitlab-ci/container/build-llvm-spirv.sh
############### Build libdrm
. .gitlab-ci/container/build-libdrm.sh

View File

@@ -20,7 +20,6 @@ STABLE_EPHEMERAL=" \
libclang-cpp13-dev \
libclang-cpp11-dev \
libgles2-mesa-dev \
libllvmspirvlib-dev \
libpciaccess-dev \
libpng-dev \
libudev-dev \
@@ -32,7 +31,6 @@ STABLE_EPHEMERAL=" \
libxrender-dev \
llvm-13-dev \
llvm-11-dev \
llvm-spirv \
make \
meson \
ocl-icd-opencl-dev \
@@ -56,7 +54,6 @@ apt-get install -y --no-remove \
libegl1 \
libepoxy0 \
libfdt1 \
libllvmspirvlib11 \
libxcb-shm0 \
ocl-icd-libopencl1 \
python3-lxml \