diff options
| author | xbzk <xbzk@eden-emu.dev> | 2026-06-15 03:02:33 +0200 |
|---|---|---|
| committer | crueter <crueter@eden-emu.dev> | 2026-06-15 03:02:33 +0200 |
| commit | 78a1cd0533fd4b6d5be77f9f6f2a87ca6b509d03 (patch) | |
| tree | 7348a5cf91e5bc98e7ab138feb877418d0dcba4f /src/qt_common/config | |
| parent | 026974211ead69fd9304a7eadb00874e6f167028 (diff) | |
[hle] support passing arguments to homebrew applications (#4013)
Homebrew (.NRO) program args support
Adds a 'program_args' setting and delivers it to NRO homebrews via libnx's homebrew ABI. NROs previously had no way to receive CLI flags (e.g. NZ:P's -noglsl).
Setting: program_args, Category::System, startup-only.
Surfaced in Qt + Android Debug sections.
NRO loader: builds a 4-entry 'ConfigEntry' table + argv at the data segment tail; prepends 'homebrew ' so user args land at argv[1]; scans for 'svc #7' to use as LR. Drops the stale NSO-style argdata append.
KProcess: stores loader-provided guest addresses; 'Run' switches to the homebrew entry (x0=config_ptr, x1=-1, lr=svc7) and patches the real MainThreadHandle into the ConfigEntry slot. Legacy NSO path unchanged.
Tested on NZP — args reach 'argv' correctly.
Reviewed-on: https://git.eden-emu.dev/eden-emu/eden/pulls/4013
Reviewed-by: Lizzie <lizzie@eden-emu.dev>
Reviewed-by: MaranBr <maranbr@eden-emu.dev>
Diffstat (limited to 'src/qt_common/config')
| -rw-r--r-- | src/qt_common/config/shared_translation.cpp | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/qt_common/config/shared_translation.cpp b/src/qt_common/config/shared_translation.cpp index 5c63732a3e..6778f37f7b 100644 --- a/src/qt_common/config/shared_translation.cpp +++ b/src/qt_common/config/shared_translation.cpp @@ -301,6 +301,8 @@ std::unique_ptr<TranslationMap> InitializeTranslations(QObject* parent) { tr("Controls the seed of the random number generator.\nMainly used for speedrunning.")); INSERT(Settings, rng_seed_enabled, QString(), QString()); INSERT(Settings, device_name, tr("Device Name"), tr("The name of the console.")); + INSERT(Settings, program_args, tr("Homebrew Args"), + tr("Command-line arguments passed to homebrew at launch (e.g. -noglsl).")); INSERT(Settings, custom_rtc, tr("Custom RTC Date:"), tr("This option allows to change the clock of the console.\n" "Can be used to manipulate time in games.")); |
