How about linux? #515

Open
opened 2026-11-24 01:14:33 +00:00 by fabox-os · 5 comments
fabox-os commented 2026-11-24 01:14:33 +00:00 (Migrated from github.com)
Contributor

Imported from ivall/xcl. Originally posted by fabox-os on 2026-11-24T01:14:33Z.


Do you consider implement vulkan for linux as well for the retail title run natively?

<!-- greyfinch-sync:ivall/xcl:issue:6572350938 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/issues/520). Originally posted by [fabox-os](https://github.com/fabox-os) on 2026-11-24T01:14:33Z. --- Do you consider implement vulkan for linux as well for the retail title run natively?
MJ26gaming commented 2026-11-24 07:05:22 +00:00 (Migrated from github.com)
Author
Contributor

Imported from ivall/xcl. Originally posted by MJ26gaming on 2026-11-24T01:44:45Z.


I am currently running a new retail game on both my windows laptop (8945hs + 4070 mobile) and my Cachy desktop (7700 + 9070 xt) with wine and directx compat layers

Significantly worse performance on the desktop

<!-- greyfinch-sync:ivall/xcl:comment:7119405165 --> Imported from [ivall/xcl](https://github.com/ivall/xcl/issues/520#issuecomment-7119405165). Originally posted by [MJ26gaming](https://github.com/MJ26gaming) on 2026-11-24T01:44:45Z. --- I am currently running a new retail game on both my windows laptop (8945hs + 4070 mobile) and my Cachy desktop (7700 + 9070 xt) with wine and directx compat layers Significantly worse performance on the desktop
ddm-j commented 2026-11-24 07:05:23 +00:00 (Migrated from github.com)
Author
Contributor

Imported from ivall/xcl. Originally posted by ddm-j on 2026-11-24T01:49:54Z.


I think it'll be easier to get proton/wine working than native

<!-- greyfinch-sync:ivall/xcl:comment:7119487233 --> Imported from [ivall/xcl](https://github.com/ivall/xcl/issues/520#issuecomment-7119487233). Originally posted by [ddm-j](https://github.com/ddm-j) on 2026-11-24T01:49:54Z. --- I think it'll be easier to get proton/wine working than native
pickles976 commented 2026-11-24 07:05:48 +00:00 (Migrated from github.com)
Author
Contributor

Imported from ivall/xcl. Originally posted by pickles976 on 2026-11-24T03:14:49Z.


Concrete data point: the whole workspace builds on Linux, unmodified, as x86_64-pc-windows-gnu, with llvm-mingw as the linker — no source changes, ~15 min on a laptop.

What I used (Ubuntu 22.04, rustup stable):

# llvm-mingw toolchain (clang-as-linker, no distro mingw, no sudo):
#   https://github.com/mstorsjo/llvm-mingw/releases  (20261117-ucrt snapshot)
rustup target add x86_64-pc-windows-gnu

.cargo/config.toml:

[target.x86_64-pc-windows-gnu]
linker = "x86_64-w64-mingw32-clang"

Two linker-side adjustments, both environment-only (nothing in the repo):

  1. rustc's windows-gnu std links -lgcc_eh -lgcc — llvm-mingw ships none. Empty stub archives on the search path satisfy the driver: llvm-ar qc stubs/libgcc.a …; libgcc_eh.a; libgcc_s.a.
  2. The real _Unwind_* come from llvm-mingw's libunwind.a (DWARF-personality symbols the windows-gnu prebuilt std expects): RUSTFLAGS="-C link-arg=-L<llvm-mingw>/x86_64-w64-mingw32/lib -C link-arg=-lunwind -C link-arg=-L<stubs>".
$ cargo build --workspace --target x86_64-pc-windows-gnu
$ ls -la target/x86_64-pc-windows-gnu/debug/
-rwxrwxr-x 105428480 xcl.exe
-rwxrwxr-x  20545024 xcl_testtitle.exe
-rwxrwxr-x   5175296 testgame_mw.dll

So the toolchain is not the blocker for a Linux dev/test loop — the runtime blockers are what they always were: D3D12 host (vkd3d-proton under Wine, cf. #175) and a GPU. My Wine smoke of the produced xcl.exe hasn't passed yet (Wine 9 aborts at startup before any output, rc=53 — investigating separately); reporting that honestly rather than implying a full run. The value here is upstream-facing: contributors on Linux can build and run the pure-Rust unit tests natively (cargo test --workspace --target x86_64-unknown-linux-gnu for the non-Windows-crate half), and CI could cross-check the windows-gnu build cheaply.

<!-- greyfinch-sync:ivall/xcl:comment:7120909131 --> Imported from [ivall/xcl](https://github.com/ivall/xcl/issues/520#issuecomment-7120909131). Originally posted by [pickles976](https://github.com/pickles976) on 2026-11-24T03:14:49Z. --- Concrete data point: **the whole workspace builds on Linux, unmodified**, as `x86_64-pc-windows-gnu`, with llvm-mingw as the linker — no source changes, ~15 min on a laptop. What I used (Ubuntu 22.04, rustup stable): ```sh # llvm-mingw toolchain (clang-as-linker, no distro mingw, no sudo): # https://github.com/mstorsjo/llvm-mingw/releases (20261117-ucrt snapshot) rustup target add x86_64-pc-windows-gnu ``` `.cargo/config.toml`: ```toml [target.x86_64-pc-windows-gnu] linker = "x86_64-w64-mingw32-clang" ``` Two linker-side adjustments, both environment-only (nothing in the repo): 1. rustc's windows-gnu std links `-lgcc_eh -lgcc` — llvm-mingw ships none. Empty stub archives on the search path satisfy the driver: `llvm-ar qc stubs/libgcc.a …; libgcc_eh.a; libgcc_s.a`. 2. The real `_Unwind_*` come from llvm-mingw's `libunwind.a` (DWARF-personality symbols the windows-gnu prebuilt std expects): `RUSTFLAGS="-C link-arg=-L<llvm-mingw>/x86_64-w64-mingw32/lib -C link-arg=-lunwind -C link-arg=-L<stubs>"`. ```console $ cargo build --workspace --target x86_64-pc-windows-gnu $ ls -la target/x86_64-pc-windows-gnu/debug/ -rwxrwxr-x 105428480 xcl.exe -rwxrwxr-x 20545024 xcl_testtitle.exe -rwxrwxr-x 5175296 testgame_mw.dll ``` So the *toolchain* is not the blocker for a Linux dev/test loop — the runtime blockers are what they always were: D3D12 host (vkd3d-proton under Wine, cf. #175) and a GPU. My Wine smoke of the produced `xcl.exe` hasn't passed yet (Wine 9 aborts at startup before any output, rc=53 — investigating separately); reporting that honestly rather than implying a full run. The value here is upstream-facing: contributors on Linux can build and run the pure-Rust unit tests natively (`cargo test --workspace --target x86_64-unknown-linux-gnu` for the non-Windows-crate half), and CI could cross-check the windows-gnu build cheaply.
pickles976 commented 2026-11-24 07:05:49 +00:00 (Migrated from github.com)
Author
Contributor

Imported from ivall/xcl. Originally posted by pickles976 on 2026-11-24T03:18:47Z.


Productive-use update on the same recipe: fixed the one real bug in my own linker flags (-lunwind was picking libunwind.dll.a → silent startup failure; putting libunwind.a first in the search path links it statically) and the cross-built xcl.exe now runs under Wine and does real work — xcl --version, xcl --help, and a full xcl inspect --json pass on the 120 MB retail exe (results posted in #627). Build → analyze loop for analyzer work no longer requires a Windows box at all.

<!-- greyfinch-sync:ivall/xcl:comment:7120971145 --> Imported from [ivall/xcl](https://github.com/ivall/xcl/issues/520#issuecomment-7120971145). Originally posted by [pickles976](https://github.com/pickles976) on 2026-11-24T03:18:47Z. --- Productive-use update on the same recipe: fixed the one real bug in my own linker flags (`-lunwind` was picking `libunwind.dll.a` → silent startup failure; putting `libunwind.a` first in the search path links it statically) and the cross-built `xcl.exe` now **runs under Wine and does real work** — `xcl --version`, `xcl --help`, and a full `xcl inspect --json` pass on the 120 MB retail exe (results posted in #627). Build → analyze loop for analyzer work no longer requires a Windows box at all.
Fyb3roptik commented 2026-11-25 21:05:19 +00:00 (Migrated from github.com)
Author
Contributor

Imported from ivall/xcl. Originally posted by Fyb3roptik on 2026-11-25T20:37:35Z.


Just got this running at 1440p 30FPS no lagging on Ubuntu 26.04. I plan to push up my changes and docs

<!-- greyfinch-sync:ivall/xcl:comment:7173947452 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/issues/520#issuecomment-7173947452). Originally posted by [Fyb3roptik](https://github.com/Fyb3roptik) on 2026-11-25T20:37:35Z. --- Just got this running at 1440p 30FPS no lagging on Ubuntu 26.04. I plan to push up my changes and docs
Sign in to join this conversation.
No labels
No milestone
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Reference
xcl-dev/xcl#515
No description provided.