diff options
author | Lionel Landwerlin <lionel.g.landwerlin@intel.com> | 2022-09-22 18:56:45 +0300 |
---|---|---|
committer | Marge Bot <emma+marge@anholt.net> | 2022-09-27 20:53:11 +0000 |
commit | 78b1e0340ea4a13c5b5cbb246c73697fe41a1299 (patch) | |
tree | 1d3be1c922f39908c489a332a4ffeccdb26b2631 /.gitlab-ci | |
parent | 05b1f3fd9794a29bca6cc83fe8b06cec68281eff (diff) | |
download | mesa-78b1e0340ea4a13c5b5cbb246c73697fe41a1299.tar.gz mesa-78b1e0340ea4a13c5b5cbb246c73697fe41a1299.tar.bz2 mesa-78b1e0340ea4a13c5b5cbb246c73697fe41a1299.zip |
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>
Diffstat (limited to '.gitlab-ci')
-rw-r--r-- | .gitlab-ci/container/build-llvm-spirv.sh | 19 | ||||
-rw-r--r-- | .gitlab-ci/container/debian/x86_build.sh | 3 | ||||
-rw-r--r-- | .gitlab-ci/container/debian/x86_test-base.sh | 8 | ||||
-rw-r--r-- | .gitlab-ci/container/debian/x86_test-gl.sh | 3 | ||||
-rw-r--r-- | .gitlab-ci/image-tags.yml | 6 |
5 files changed, 32 insertions, 7 deletions
diff --git a/.gitlab-ci/container/build-llvm-spirv.sh b/.gitlab-ci/container/build-llvm-spirv.sh new file mode 100644 index 00000000000..ff70e540fff --- /dev/null +++ b/.gitlab-ci/container/build-llvm-spirv.sh @@ -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 diff --git a/.gitlab-ci/container/debian/x86_build.sh b/.gitlab-ci/container/debian/x86_build.sh index 3bae3ee1f38..0119b792cb5 100644 --- a/.gitlab-ci/container/debian/x86_build.sh +++ b/.gitlab-ci/container/debian/x86_build.sh @@ -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 diff --git a/.gitlab-ci/container/debian/x86_test-base.sh b/.gitlab-ci/container/debian/x86_test-base.sh index d40eb5dff19..8811352ed97 100644 --- a/.gitlab-ci/container/debian/x86_test-base.sh +++ b/.gitlab-ci/container/debian/x86_test-base.sh @@ -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 diff --git a/.gitlab-ci/container/debian/x86_test-gl.sh b/.gitlab-ci/container/debian/x86_test-gl.sh index b56d2e4ea3f..4a34a471bce 100644 --- a/.gitlab-ci/container/debian/x86_test-gl.sh +++ b/.gitlab-ci/container/debian/x86_test-gl.sh @@ -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 \ diff --git a/.gitlab-ci/image-tags.yml b/.gitlab-ci/image-tags.yml index 900bb2e3470..d4f196de1c6 100644 --- a/.gitlab-ci/image-tags.yml +++ b/.gitlab-ci/image-tags.yml @@ -1,9 +1,9 @@ variables: DEBIAN_X86_BUILD_BASE_IMAGE: "debian/x86_build-base" - DEBIAN_BASE_TAG: "2022-09-22-python3-ply-2" + DEBIAN_BASE_TAG: "2022-09-22-llvm-spirv" DEBIAN_X86_BUILD_IMAGE_PATH: "debian/x86_build" - DEBIAN_BUILD_TAG: "2022-09-22-python3-ply-2" + DEBIAN_BUILD_TAG: "2022-09-22-llvm-spirv" DEBIAN_X86_BUILD_MINGW_IMAGE_PATH: "debian/x86_build-mingw" DEBIAN_BUILD_MINGW_TAG: "2022-08-25-shellcheck" @@ -11,7 +11,7 @@ variables: DEBIAN_X86_TEST_BASE_IMAGE: "debian/x86_test-base" DEBIAN_X86_TEST_IMAGE_PATH: "debian/x86_test-gl" - DEBIAN_X86_TEST_GL_TAG: "2022-09-14-add-jq" + DEBIAN_X86_TEST_GL_TAG: "2022-09-22-llvm-spirv" DEBIAN_X86_TEST_VK_TAG: "2022-09-14-add-jq" FEDORA_X86_BUILD_TAG: "2022-09-22-python3-ply-2" |