Files
VIctory-xmem/docs/BUILD.md

2.2 KiB

Build and setup

Back to README

Requirements

Required tools:

git curl unzip tar xz python3 pkg-config ninja glslangValidator
clang-cl lld-link llvm-lib
x86_64-w64-mingw32-gcc x86_64-w64-mingw32-g++
x86_64-w64-mingw32-strip widl cargo rustup make flex bison
systemd-run unshare

wine is also required when Proton is not used.

Mesa pkg-config requirements:

libdrm >= 2.4.133
libdrm_amdgpu >= 2.4.133
xcb
xcb-randr
x11-xcb
xcb-dri3 >= 1.13
xcb-present >= 1.13
xcb-shm
xcb-sync
xshmfence >= 1.1
xcb-xfixes
xrandr >= 1.3
wayland-client >= 1.18
wayland-server >= 1.18
wayland-protocols >= 1.49

Setup, build and update

setup.sh

Do not run as root or with sudo. setup.sh refuses to.

Command Effect
./setup.sh Runs sdk dlls mesa vkd3d wine prefix victory
./setup.sh fsr4 Optional FSR 4 step; also needs files from Proton
./setup.sh win11 Optional: the prefix reports Windows 11, which VICTORY_FIDELITYFX_FRAMEGEN=4 needs (with an MLFG-capable amdxc64.dll from ./setup.sh fsr4). It changes the version for the whole prefix; undo with (source ./env.sh; "$WINE_BIN" winecfg -v win10)
./setup.sh <step> Rebuilds one step

It fetches and builds:

  • Mesa 26.3.1
  • vkd3d-proton commit 71cae091b06571e51446cf2a937f0b04c237c04d
  • xwin 0.10.0
  • DXC 1.9.2609 (dxc_2026_09_29)
  • DXVK 3.1.1 (dxgi.dll)
  • d3dcompiler_47.dll from fxc2
  • FSR 4 SDK 2.4.0; driver amdxcffx64 v4.1.1
  • Wine source and a patched Wine server, unless Proton is used

Dependencies are built under deps/. Saves, caches and logs are kept in local/.

Proton is auto-detected unless USE_SYSTEM_WINE=1. PROTON= overrides the detection.

build.sh

  • Builds the Windows target x86_64-pc-windows-msvc with clang-cl, lld-link, llvm-lib and the xwin Windows SDK.
  • Uses -C target-cpu=x86-64-v3.
  • Runs under systemd-run --user with a memory cap and nice.
  • Default build timeout: 1800 seconds.
  • PROFILE=diag builds the diagnostics profile.

update.sh

update.sh fetches origin/main, lists new commits, merges, then runs ./build.sh.

  • It refuses root, non-git checkouts and tracked uncommitted changes.
  • It aborts on a merge conflict.
  • It never pushes.