From 7902e772bfd199e58c1b7b0599d063c89e34fd12 Mon Sep 17 00:00:00 2001 From: nessi Date: Tue, 17 Mar 2026 19:29:37 +0100 Subject: [PATCH] docs: add clang/lld/llvm prerequisites for Linux Windows cross-builds Add apt install instructions for clang, lld, llvm, and nsis to README Ubuntu-to-Windows build section. Add clang-cl availability check to cargo-xwin wrapper script with helpful error message directing users to install LLVM/Clang toolchain when missing. --- README.md | 2 ++ desktop-client/scripts/cargo-xwin | 8 ++++++++ 2 files changed, 10 insertions(+) diff --git a/README.md b/README.md index d4e1820..48ce645 100644 --- a/README.md +++ b/README.md @@ -63,6 +63,8 @@ Ubuntu-to-Windows `Setup.exe` build: ```bash cd desktop-client +sudo apt update +sudo apt install -y clang lld llvm nsis cargo install --locked cargo-xwin rustup target add x86_64-pc-windows-msvc npm install diff --git a/desktop-client/scripts/cargo-xwin b/desktop-client/scripts/cargo-xwin index d744160..0640353 100644 --- a/desktop-client/scripts/cargo-xwin +++ b/desktop-client/scripts/cargo-xwin @@ -1,4 +1,12 @@ #!/usr/bin/env bash set -eu +if ! command -v clang-cl >/dev/null 2>&1; then + echo "clang-cl is required for Windows cross-builds on Linux." + echo "Install LLVM/Clang toolchain first, for example on Ubuntu:" + echo " sudo apt update" + echo " sudo apt install -y clang lld llvm" + exit 1 +fi + exec cargo xwin "$@"