Enable multilib for 32-bit Proton bridge support in distrobox install (#52)

* Add distrobox installer/uninstaller for immutable distros

Adds install-distrobox-dev.sh and uninstall-distrobox-dev.sh under
tools/distro/distrobox/, for setting up monocoque + simapi/simd inside
an Arch Linux distrobox container on immutable distros (Bazzite,
Silverblue, etc.) where native package managers aren't available.

The installer enables the multilib repo and installs wine + lib32-glibc
so the 32-bit Proton bridge executables (e.g. acbridge.exe) have the
32-bit dynamic linker they need — without this, bridge processes fail
silently with a bare "No such file or directory".

Fixes two bugs found before submitting:
- install script's chmod/help-text referenced wrapper script names
  without the -dev suffix used by the actual `cat >` heredocs, which
  would abort the script under set -e on the first chmod
- uninstall script targeted the "simracing" container/install dir
  instead of "simracing-dev", which would silently no-op (or worse,
  target the wrong container) for anyone who also has a non-dev
  simracing container

* Fix typo'd URL to simracing-utilities in install script

The repo is actually named cescofry/simracing-utilties (missing "i"),
not simracing-utilities as originally written - the correctly-spelled
URL 404s.

* Fold fixes into the existing install-distrobox.sh instead of a -dev copy

The previous two commits on this branch added new install-distrobox-dev.sh/
uninstall-distrobox-dev.sh files, but tools/distro/distrobox/install-distrobox.sh
and uninstall-distrobox.sh already exist upstream (#41, #47) — the "-dev"
files were a personal working copy (container renamed to simracing-dev)
that should never have been committed as new files.

This removes the -dev files and instead patches the real
install-distrobox.sh directly with the actual fixes:
- Enable the multilib repo and install wine/lib32-glibc, so the 32-bit
  Proton bridge executables (e.g. acbridge.exe) have the 32-bit dynamic
  linker they need — without this they fail silently with a bare
  "No such file or directory".
- Fix the simracing-utilities URL typo (real repo is simracing-utilties).

uninstall-distrobox.sh needed no changes — the container/install-dir
mismatch found earlier was an artifact of the -dev copy's own renaming,
not a bug in the real upstream script.

* Enable multilib + wine/lib32-glibc, fix simracing-utilities URL typo

These are the actual fixes intended by the previous commit's message —
they didn't get staged there because a stale pathspec in the same `git
add` invocation aborted it before reaching this file.
This commit is contained in:
David Scott
2026-09-02 00:35:30 -04:00
committed by GitHub
parent 340752857d
commit 501d72fb1e
+26 -2
View File
@@ -135,9 +135,33 @@ log_info "Installing packages inside container (this may take a few minutes)..."
distrobox enter --root "$CONTAINER" -- bash -c '
set -euo pipefail
# Enable the multilib repo for 32-bit runtime support — Proton bridge
# apps (e.g. acbridge.exe) are 32-bit wine processes and fail with a
# bare "No such file or directory" (not a permissions/PATH error) when
# /lib/ld-linux.so.2, the 32-bit dynamic linker, is missing. A fresh
# Arch container image does not ship multilib enabled by default, and
# (confirmed on a real install) not even the commented-out [multilib]
# stanza is present to uncomment — it has to be appended outright.
# Idempotent so re-running this script is still safe.
if ! grep -q "^\[multilib\]" /etc/pacman.conf; then
echo "Enabling multilib repository (needed for 32-bit wine/Proton bridge support)..."
cat >> /etc/pacman.conf << "PACMANCONF_EOF"
[multilib]
Include = /etc/pacman.d/mirrorlist
PACMANCONF_EOF
fi
# Install build dependencies
echo "Installing build dependencies..."
sudo pacman -Syu --needed --noconfirm base-devel git mingw-w64-gcc
# wine + lib32-glibc pull in the well-tested 32-bit dependency chain
# the Proton-bundled wine build each game uses needs to actually
# execute (this Arch wine package is not run directly — each game
# launches its own Proton version bridge via BridgeScripts.txt-style
# commands — installing the package is just the simplest reliable way
# to get every lib32-* dependency it needs without hand-picking each
# one).
sudo pacman -Syu --needed --noconfirm base-devel git mingw-w64-gcc wine lib32-glibc
# Install yay (AUR helper) if not present
if ! command -v yay &>/dev/null; then
@@ -252,5 +276,5 @@ echo " start-simd & start-monocoque & $INSTALL_DIR/simshmbridge/assets/a
echo ""
echo " For tools that automate steps 1 and 3 (Moza auto-detection, Steam launch"
echo " option configuration, unified game launcher), visit:"
echo " https://github.com/cescofry/simracing-utilities"
echo " https://github.com/cescofry/simracing-utilties"
echo ""