Add a native desktop launcher #1548

Open
github-bot wants to merge 2 commits from github-bot/gh-1548 into main AGit
Owner

@⁠ytsodacan on GitHub · 2026-11-25 04:08 UTC · original
ytsodacan:desktop-builder → main · +6321 −0 · 15 files · 2 commits · open

What and why

A native desktop launcher in builder/ (Rust, egui): it builds the port with make_game.py --no-tui, manages mods and starts the result. It replaces #1536.

It covers the same ground as #851, the native launcher by aslan2142. Happy to close it, or move parts over, if you'd rather have one launcher.

Play Not built yet
Play Not built yet
Mods Settings
Mods Settings
Build Building
Build Building
After the game closes Game log
Closed Game log

Every path, mod and time in the screenshots is made up.

  • Play: starts the port as docs/boot.md describes (gta6rt.exe --run, or gta6rt.sh --run through Wine) with the overlay and mods folders, and says the port isn't playable yet. Stop ends the whole process tree. Output goes to a log file, so the game carries on when the launcher closes.
  • Mods: lists, adds and switches mods through tools/leonida_mods.py.
  • Build: finds your copy with make_game.py --find; output folder, jobs, steps, live progress and log. Only the steps running the port needs start ticked (about 30 GB).
  • Settings: keyboard as a controller, splash screen, graphics diagnostics, Wine command.
  • Application icon: build.rs embeds assets/logo.ico (16 to 256 px) in the Windows exe, cross-builds included; cargo bundle metadata covers a macOS .app.

The layout follows the Hookshot builder; the code is new. Bundles the Inter font (SIL OFL 1.1, license included). .gitignore gets an exception for assets/logo.ico.

Tested

On macOS: release build, cargo test (10 tests: log parsing, starting and stopping a stand-in port, Cancel, settings, and the repository's own mod manager), and the screens above. The docs tests and check_no_game_data.py pass.

For the cross-build icon, build.rs was run with the MSVC target variables and llvm-rc: the resource file holds the icon group and its images. tiguan26 ran 7aa50cb67 on Linux and cross-linked it for Windows (see the comment below).

Not tested: starting the real port, a full build with game files, running on Windows.

GPUs tested: n/a

Checklist

  • Based on current main and merges cleanly.
  • One topic; follow-up work goes in a new pull request.
  • No game data, keys or decryption.
**@⁠ytsodacan** on GitHub · 2026-11-25 04:08 UTC · [original](https://github.com/ubiquitarianism/leonida/pull/1548) `ytsodacan:desktop-builder` → `main` · +6321 −0 · 15 files · 2 commits · open ### What and why A native desktop launcher in `builder/` (Rust, egui): it builds the port with `make_game.py --no-tui`, manages mods and starts the result. It replaces #1536. It covers the same ground as #851, the native launcher by aslan2142. Happy to close it, or move parts over, if you'd rather have one launcher. | Play | Not built yet | |---|---| | ![Play](https://raw.githubusercontent.com/ytsodacan/leonida/d1e64596e6afd6b076c46ae52224998e4a556076/launcher-1-play.png) | ![Not built yet](https://raw.githubusercontent.com/ytsodacan/leonida/d1e64596e6afd6b076c46ae52224998e4a556076/launcher-0-not-built.png) | | Mods | Settings | |---|---| | ![Mods](https://raw.githubusercontent.com/ytsodacan/leonida/d1e64596e6afd6b076c46ae52224998e4a556076/launcher-3-mods.png) | ![Settings](https://raw.githubusercontent.com/ytsodacan/leonida/d1e64596e6afd6b076c46ae52224998e4a556076/launcher-6-settings.png) | | Build | Building | |---|---| | ![Build](https://raw.githubusercontent.com/ytsodacan/leonida/386f826019fe99d527db41c8451939d90935b42b/launcher-4-build-v2.png) | ![Building](https://raw.githubusercontent.com/ytsodacan/leonida/d1e64596e6afd6b076c46ae52224998e4a556076/launcher-5-building.png) | | After the game closes | Game log | |---|---| | ![Closed](https://raw.githubusercontent.com/ytsodacan/leonida/d1e64596e6afd6b076c46ae52224998e4a556076/launcher-2-closed.png) | ![Game log](https://raw.githubusercontent.com/ytsodacan/leonida/d1e64596e6afd6b076c46ae52224998e4a556076/launcher-7-log.png) | Every path, mod and time in the screenshots is made up. - **Play:** starts the port as docs/boot.md describes (`gta6rt.exe --run`, or `gta6rt.sh --run` through Wine) with the overlay and mods folders, and says the port isn't playable yet. Stop ends the whole process tree. Output goes to a log file, so the game carries on when the launcher closes. - **Mods:** lists, adds and switches mods through `tools/leonida_mods.py`. - **Build:** finds your copy with `make_game.py --find`; output folder, jobs, steps, live progress and log. Only the steps running the port needs start ticked (about 30 GB). - **Settings:** keyboard as a controller, splash screen, graphics diagnostics, Wine command. - **Application icon:** `build.rs` embeds `assets/logo.ico` (16 to 256 px) in the Windows exe, cross-builds included; `cargo bundle` metadata covers a macOS .app. The layout follows the [Hookshot](https://github.com/ItsNotRexed/Hookshot) builder; the code is new. Bundles the Inter font (SIL OFL 1.1, license included). `.gitignore` gets an exception for `assets/logo.ico`. ### Tested On macOS: release build, `cargo test` (10 tests: log parsing, starting and stopping a stand-in port, Cancel, settings, and the repository's own mod manager), and the screens above. The docs tests and `check_no_game_data.py` pass. For the cross-build icon, `build.rs` was run with the MSVC target variables and llvm-rc: the resource file holds the icon group and its images. tiguan26 ran 7aa50cb67 on Linux and cross-linked it for Windows (see the comment below). Not tested: starting the real port, a full build with game files, running on Windows. GPUs tested: n/a ### Checklist - [x] Based on current `main` and merges cleanly. - [x] One topic; follow-up work goes in a new pull request. - [x] No game data, keys or decryption.
github-bot locked as GitHub sync and limited conversation to collaborators 2026-11-26 09:56:15 +00:00
Author
Owner

@⁠tiguan26 on GitHub · 2026-11-25 04:43 UTC · original

Tested 7aa50cb merged into current main, on the two platforms the description lists as untested. No game files.

Linux (Ubuntu 24.04, Rust stable): cargo test --release passes 9 of 9 (stage parsing, Cancel and Stop ending the process tree, port states, settings reload, the mod manager's output), and the shots feature renders every screen under Xvfb on llvmpipe.

Windows, cross-built from Linux (--target x86_64-pc-windows-msvc, lld-link and an xwin SDK): it links, but the .exe has no icon. llvm-readobj --coff-resources lists no resources at all. build.rs gates winresource on #[cfg(windows)], and a build script is compiled for the host, so that block only runs when the build itself runs on Windows. A Windows build made on Linux or macOS (CI, or the cross-build docs/linux.md describes) ships without the icon. The usual fix, which winresource's docs suggest for cross builds, is to check std::env::var("CARGO_CFG_TARGET_OS") == Ok("windows") at run time and make winresource available whenever the target is Windows. (Running it under Wine I didn't try.)

Default steps: every step starts ticked (stages: [true; 5]), so "Build the game" asks for the full ~400 GB, about 370 GB of it the asset export, which only the asset tools use. Running the port needs check, shaders and runtime, about 30 GB per the README. For people who chose the app over the console, starting with Export assets off (or showing each step's disk size) would avoid the surprise. Unticking already passes --stages correctly.

Small one: Cargo.toml says license = "GPL-3.0-only", while the repository is GPLv3 or any later version (README, LICENSE).

AI-assisted (Claude).

**@⁠tiguan26** on GitHub · 2026-11-25 04:43 UTC · [original](https://github.com/ubiquitarianism/leonida/pull/1548#issuecomment-7153101734) Tested 7aa50cb merged into current main, on the two platforms the description lists as untested. No game files. **Linux** (Ubuntu 24.04, Rust stable): `cargo test --release` passes 9 of 9 (stage parsing, Cancel and Stop ending the process tree, port states, settings reload, the mod manager's output), and the `shots` feature renders every screen under Xvfb on llvmpipe. **Windows**, cross-built from Linux (`--target x86_64-pc-windows-msvc`, lld-link and an xwin SDK): it links, but **the .exe has no icon**. `llvm-readobj --coff-resources` lists no resources at all. `build.rs` gates `winresource` on `#[cfg(windows)]`, and a build script is compiled for the host, so that block only runs when the build itself runs on Windows. A Windows build made on Linux or macOS (CI, or the cross-build `docs/linux.md` describes) ships without the icon. The usual fix, which winresource's docs suggest for cross builds, is to check `std::env::var("CARGO_CFG_TARGET_OS") == Ok("windows")` at run time and make `winresource` available whenever the target is Windows. (Running it under Wine I didn't try.) **Default steps:** every step starts ticked (`stages: [true; 5]`), so "Build the game" asks for the full ~400 GB, about 370 GB of it the asset export, which only the asset tools use. Running the port needs check, shaders and runtime, about 30 GB per the README. For people who chose the app over the console, starting with Export assets off (or showing each step's disk size) would avoid the surprise. Unticking already passes `--stages` correctly. Small one: `Cargo.toml` says `license = "GPL-3.0-only"`, while the repository is GPLv3 or any later version (README, LICENSE). AI-assisted (Claude).
Author
Owner

@⁠ytsodacan on GitHub · 2026-11-25 04:48 UTC · original

Thanks for testing on both platforms, all three were right. Fixed in 61fbeb062:

  • Icon: build.rs now checks CARGO_CFG_TARGET_OS and winresource is an unconditional build dependency. I ran the build script for x86_64-pc-windows-msvc on macOS with llvm-rc and the resource file has the icon group. I haven't linked a full exe, so a recheck with your xwin setup would be welcome.
  • Default steps: only shaders and runtime start ticked (the check always runs), and Export assets shows its 370 GB. Test pipelines starts off too. Since that passes --stages explicitly, the runtime step starts unticked where cross_build_missing() reports something.
  • License: now GPL-3.0-or-later.
**@⁠ytsodacan** on GitHub · 2026-11-25 04:48 UTC · [original](https://github.com/ubiquitarianism/leonida/pull/1548#issuecomment-7153178336) Thanks for testing on both platforms, all three were right. Fixed in 61fbeb062: - **Icon:** `build.rs` now checks `CARGO_CFG_TARGET_OS` and `winresource` is an unconditional build dependency. I ran the build script for `x86_64-pc-windows-msvc` on macOS with llvm-rc and the resource file has the icon group. I haven't linked a full exe, so a recheck with your xwin setup would be welcome. - **Default steps:** only shaders and runtime start ticked (the check always runs), and Export assets shows its 370 GB. Test pipelines starts off too. Since that passes `--stages` explicitly, the runtime step starts unticked where `cross_build_missing()` reports something. - **License:** now `GPL-3.0-or-later`.
Author
Owner

@⁠tiguan26 on GitHub · 2026-11-25 05:28 UTC · original · approved these changes

Rechecked 61fbeb0 merged into current main, and approving.

  • Icon: cross-built for x86_64-pc-windows-msvc on Linux (lld-link, xwin SDK 10.0.26100, llvm-rc on PATH): llvm-readobj --coff-resources leonida-launcher.exe now lists GROUP_ICON, seven ICON images and VERSIONINFO (it listed nothing before).
  • Default steps: check, shaders and runtime start ticked; Export assets (labelled 370 GB) and Test pipelines start off, and the footer reads "Needs about 30 GB". Rendered with the shots feature under Xvfb.
  • License: GPL-3.0-or-later.
  • cargo test --release on Linux: 10 of 10.

Thanks for the quick turnaround.

AI-assisted (Claude).

**@⁠tiguan26** on GitHub · 2026-11-25 05:28 UTC · [original](https://github.com/ubiquitarianism/leonida/pull/1548#pullrequestreview-6052302846) · **approved these changes** Rechecked 61fbeb0 merged into current main, and approving. - **Icon:** cross-built for `x86_64-pc-windows-msvc` on Linux (lld-link, xwin SDK 10.0.26100, llvm-rc on PATH): `llvm-readobj --coff-resources leonida-launcher.exe` now lists GROUP_ICON, seven ICON images and VERSIONINFO (it listed nothing before). - **Default steps:** check, shaders and runtime start ticked; Export assets (labelled 370 GB) and Test pipelines start off, and the footer reads "Needs about 30 GB". Rendered with the `shots` feature under Xvfb. - **License:** GPL-3.0-or-later. - `cargo test --release` on Linux: 10 of 10. Thanks for the quick turnaround. AI-assisted (Claude).
This pull request can be merged automatically.
This branch is out-of-date with the base branch
You are not authorized to merge this pull request.
View command line instructions

Checkout

From your project repository, check out a new branch and test the changes.
git fetch -u origin '+refs/pull/1548/head:github-bot/gh-1548'
git switch 'github-bot/gh-1548'

Merge

Merge the changes and update on Forgejo.
git switch 'main'
git merge --no-ff 'github-bot/gh-1548'
git switch 'github-bot/gh-1548'
git rebase 'main'
git switch 'main'
git merge --ff-only 'github-bot/gh-1548'
git switch 'github-bot/gh-1548'
git rebase 'main'
git switch 'main'
git merge --no-ff 'github-bot/gh-1548'
git switch 'main'
git merge --squash 'github-bot/gh-1548'
git switch 'main'
git merge --ff-only 'github-bot/gh-1548'
git switch 'main'
git merge 'github-bot/gh-1548'
git push origin 'main'
This discussion has been locked. Commenting is limited to contributors.
No description provided.