From a5efd38385a4c917efcf2f815c6013244abbcc4b Mon Sep 17 00:00:00 2001 From: Rob Ballantyne Date: Tue, 5 Mar 2024 11:54:19 +0000 Subject: [PATCH] Fix proton install --- .../opt/ai-dock/bin/preflight.d/30-steam.sh | 11 +++++------ .../opt/ai-dock/bin/build/layer1/init.sh | 12 ++++++------ .../opt/ai-dock/share/proton/toolmanifest.vdf | 2 +- 3 files changed, 12 insertions(+), 13 deletions(-) diff --git a/build/COPY_ROOT/opt/ai-dock/bin/preflight.d/30-steam.sh b/build/COPY_ROOT/opt/ai-dock/bin/preflight.d/30-steam.sh index cf1e074..719c211 100644 --- a/build/COPY_ROOT/opt/ai-dock/bin/preflight.d/30-steam.sh +++ b/build/COPY_ROOT/opt/ai-dock/bin/preflight.d/30-steam.sh @@ -1,9 +1,8 @@ mkdir -p /opt/ai-dock/lib/steam-native -steam_dir="${home_dir}"/.steam/debian-installation/ -proton_compat_dir="${steam_dir}/compatibilitytools.d/${GE_PROTON_VERSION}" -proton_binary_path="/opt/proton/${GE_PROTON_VERSION}/proton" +steam_dir="${home_dir}/.steam/debian-installation/" +proton_compat_dir="${steam_dir}/compatibilitytools.d/" +proton_dir="/opt/proton/${GE_PROTON_VERSION}" + mkdir -p "${proton_compat_dir}" -cp /opt/ai-dock/share/proton/* "${proton_compat_dir}" -sed -i "s#PROTON_NAME#${GE_PROTON_VERSION}#g" "${proton_compat_dir}/compatibilitytool.vdf" -sed -i "s#PROTON_BINARY_PATH#${proton_binary_path}#g" "${proton_compat_dir}/toolmanifest.vdf" \ No newline at end of file +ln -s "${proton_dir}" "${proton_compat_dir}/${GE_PROTON_VERSION}" \ No newline at end of file diff --git a/build/COPY_ROOT_EXTRA/opt/ai-dock/bin/build/layer1/init.sh b/build/COPY_ROOT_EXTRA/opt/ai-dock/bin/build/layer1/init.sh index d3bedbd..ed33d96 100755 --- a/build/COPY_ROOT_EXTRA/opt/ai-dock/bin/build/layer1/init.sh +++ b/build/COPY_ROOT_EXTRA/opt/ai-dock/bin/build/layer1/init.sh @@ -1,8 +1,8 @@ #!/bin/bash set -eo pipefail -# Override this file to add extras to your build umask 002 -# Wine, Winetricks, Lutris, and PlayOnLinux, this process must be consistent with https://wiki.winehq.org/Ubuntu +# Override this file to add extras to your build +# Wine, Winetricks, Lutris, this process must be consistent with https://wiki.winehq.org/Ubuntu mkdir -pm755 /etc/apt/keyrings curl -fsSL -o /etc/apt/keyrings/winehq-archive.key "https://dl.winehq.org/wine-builds/winehq.key" @@ -10,9 +10,7 @@ curl -fsSL -o "/etc/apt/sources.list.d/winehq-$(grep UBUNTU_CODENAME= /etc/os-re apt-get update apt-get install --install-recommends -y \ winehq-${WINE_BRANCH} -apt-get install --no-install-recommends -y \ - q4wine \ - playonlinux + export LUTRIS_VERSION="$(curl -fsSL "https://api.github.com/repos/lutris/lutris/releases/latest" | jq -r '.tag_name' | sed 's/[^0-9\.\-]*//g')" env-store LUTRIS_VERSION curl -fsSL -O "https://github.com/lutris/lutris/releases/download/v${LUTRIS_VERSION}/lutris_${LUTRIS_VERSION}_all.deb" @@ -34,6 +32,9 @@ export GE_PROTON_VERSION="$(curl -fsSL "https://api.github.com/repos/GloriousEgg env-store GE_PROTON_VERSION mkdir -p /opt/proton wget -c "https://github.com/GloriousEggroll/proton-ge-custom/releases/download/${GE_PROTON_VERSION}/${GE_PROTON_VERSION}.tar.gz" -O - | tar xz -C /opt/proton +proton_dir="/opt/proton/${GE_PROTON_VERSION}" +cp /opt/ai-dock/share/proton/*.vdf "${proton_dir}" +sed -i "s#PROTON_NAME#${GE_PROTON_VERSION}#g" "${proton_dir}/compatibilitytool.vdf" dpkg-divert --add /usr/games/steam $APT_INSTALL \ @@ -70,7 +71,6 @@ dpkg-divert --add /opt/google/chrome/google-chrome cp -f /opt/google/chrome/google-chrome /opt/google/chrome/google-chrome.distrib cp -f /opt/ai-dock/share/google-chrome/bin/google-chrome /opt/google/chrome/google-chrome - rm -rf /tmp/* fix-permissions -o container \ No newline at end of file diff --git a/build/COPY_ROOT_EXTRA/opt/ai-dock/share/proton/toolmanifest.vdf b/build/COPY_ROOT_EXTRA/opt/ai-dock/share/proton/toolmanifest.vdf index b8dc077..6405447 100644 --- a/build/COPY_ROOT_EXTRA/opt/ai-dock/share/proton/toolmanifest.vdf +++ b/build/COPY_ROOT_EXTRA/opt/ai-dock/share/proton/toolmanifest.vdf @@ -1,5 +1,5 @@ "manifest" { "version" "2" - "commandline" "'PROTON_BINARY_PATH' %verb%" + "commandline" "/proton %verb%" } \ No newline at end of file