1#!/bin/bash 2 3set -ex 4 5VKD3D_PROTON_COMMIT="5b73139f182d86cd58a757e4b5f0d4cfad96d319" 6 7VKD3D_PROTON_DST_DIR="/vkd3d-proton-tests" 8VKD3D_PROTON_SRC_DIR="/vkd3d-proton-src" 9VKD3D_PROTON_BUILD_DIR="/vkd3d-proton-$VKD3D_PROTON_VERSION" 10 11function build_arch { 12 local arch="$1" 13 shift 14 15 meson "$@" \ 16 -Denable_tests=true \ 17 --buildtype release \ 18 --prefix "$VKD3D_PROTON_DST_DIR" \ 19 --strip \ 20 --bindir "x${arch}" \ 21 --libdir "x${arch}" \ 22 "$VKD3D_PROTON_BUILD_DIR/build.${arch}" 23 24 ninja -C "$VKD3D_PROTON_BUILD_DIR/build.${arch}" install 25 26 install -D -m755 -t "${VKD3D_PROTON_DST_DIR}/x${arch}/bin" "$VKD3D_PROTON_BUILD_DIR/build.${arch}/tests/d3d12" 27} 28 29git clone https://github.com/HansKristian-Work/vkd3d-proton.git --single-branch -b master --no-checkout "$VKD3D_PROTON_SRC_DIR" 30pushd "$VKD3D_PROTON_SRC_DIR" 31git checkout "$VKD3D_PROTON_COMMIT" 32git submodule update --init --recursive 33git submodule update --recursive 34build_arch 64 35build_arch 86 36popd 37 38rm -rf "$VKD3D_PROTON_BUILD_DIR" 39rm -rf "$VKD3D_PROTON_SRC_DIR" 40