mirror of
https://github.com/PrismLauncher/PrismLauncher.git
synced 2026-07-08 13:08:29 +02:00
fix(nix): target final wrapper in instance shortcuts
Previously the unwrapped binary of Prism would be used in the `Exec` line of desktop files, leading to Weird behavior - like the instance hanging with no window created Signed-off-by: Seth Flynn <getchoo@tuta.io>
This commit is contained in:
parent
d2fa7cf7f7
commit
e3f97f39eb
2 changed files with 9 additions and 1 deletions
|
|
@ -68,6 +68,11 @@ stdenv.mkDerivation {
|
|||
ln -s ${libnbtplusplus} source/libraries/libnbtplusplus
|
||||
'';
|
||||
|
||||
postPatch = ''
|
||||
substituteInPlace launcher/minecraft/ShortcutUtils.cpp \
|
||||
--replace-fail 'QApplication::applicationFilePath()' 'QProcessEnvironment::systemEnvironment().value("NIX_LAUNCHER_WRAPPER", "${placeholder "out"}/bin/prismlauncher")'
|
||||
'';
|
||||
|
||||
nativeBuildInputs = [
|
||||
cmake
|
||||
ninja
|
||||
|
|
|
|||
|
|
@ -115,7 +115,10 @@ symlinkJoin {
|
|||
++ additionalPrograms;
|
||||
|
||||
in
|
||||
[ "--prefix PRISMLAUNCHER_JAVA_PATHS : ${lib.makeSearchPath "bin/java" jdks}" ]
|
||||
[
|
||||
"--set NIX_LAUNCHER_WRAPPER ${placeholder "out"}/bin/prismlauncher"
|
||||
"--prefix PRISMLAUNCHER_JAVA_PATHS : ${lib.makeSearchPath "bin/java" jdks}"
|
||||
]
|
||||
++ lib.optionals stdenv.hostPlatform.isLinux [
|
||||
"--set LD_LIBRARY_PATH ${addDriverRunpath.driverLink}/lib:${lib.makeLibraryPath runtimeLibs}"
|
||||
"--prefix PATH : ${lib.makeBinPath runtimePrograms}"
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue