Merge pull request #968 from Scrumplex/nix/sync-2023-04-02
This commit is contained in:
commit
ed085630db
@ -23,6 +23,8 @@
|
|||||||
cmark,
|
cmark,
|
||||||
msaClientID ? "",
|
msaClientID ? "",
|
||||||
jdks ? [jdk17 jdk8],
|
jdks ? [jdk17 jdk8],
|
||||||
|
gamemodeSupport ? true,
|
||||||
|
gamemode,
|
||||||
# flake
|
# flake
|
||||||
self,
|
self,
|
||||||
version,
|
version,
|
||||||
@ -45,12 +47,12 @@ stdenv.mkDerivation rec {
|
|||||||
tomlplusplus
|
tomlplusplus
|
||||||
cmark
|
cmark
|
||||||
]
|
]
|
||||||
++ lib.optional (lib.versionAtLeast qtbase.version "6") qtwayland;
|
++ lib.optional (lib.versionAtLeast qtbase.version "6") qtwayland
|
||||||
|
++ lib.optional gamemodeSupport gamemode.dev;
|
||||||
|
|
||||||
cmakeFlags =
|
cmakeFlags =
|
||||||
lib.optionals (msaClientID != "") ["-DLauncher_MSA_CLIENT_ID=${msaClientID}"]
|
lib.optionals (msaClientID != "") ["-DLauncher_MSA_CLIENT_ID=${msaClientID}"]
|
||||||
++ lib.optionals (lib.versionOlder qtbase.version "6") ["-DLauncher_QT_VERSION_MAJOR=5"];
|
++ lib.optionals (lib.versionOlder qtbase.version "6") ["-DLauncher_QT_VERSION_MAJOR=5"];
|
||||||
dontWrapQtApps = true;
|
|
||||||
|
|
||||||
postUnpack = ''
|
postUnpack = ''
|
||||||
rm -rf source/libraries/libnbtplusplus
|
rm -rf source/libraries/libnbtplusplus
|
||||||
@ -60,27 +62,27 @@ stdenv.mkDerivation rec {
|
|||||||
chown -R $USER: source/libraries/libnbtplusplus
|
chown -R $USER: source/libraries/libnbtplusplus
|
||||||
'';
|
'';
|
||||||
|
|
||||||
postInstall = let
|
qtWrapperArgs = let
|
||||||
libpath = with xorg;
|
libpath = with xorg;
|
||||||
lib.makeLibraryPath [
|
lib.makeLibraryPath ([
|
||||||
libX11
|
libX11
|
||||||
libXext
|
libXext
|
||||||
libXcursor
|
libXcursor
|
||||||
libXrandr
|
libXrandr
|
||||||
libXxf86vm
|
libXxf86vm
|
||||||
libpulseaudio
|
libpulseaudio
|
||||||
libGL
|
libGL
|
||||||
glfw
|
glfw
|
||||||
openal
|
openal
|
||||||
stdenv.cc.cc.lib
|
stdenv.cc.cc.lib
|
||||||
];
|
]
|
||||||
in ''
|
++ lib.optional gamemodeSupport gamemode.lib);
|
||||||
|
in [
|
||||||
|
"--set LD_LIBRARY_PATH /run/opengl-driver/lib:${libpath}"
|
||||||
|
"--prefix PRISMLAUNCHER_JAVA_PATHS : ${lib.makeSearchPath "bin/java" jdks}"
|
||||||
# xorg.xrandr needed for LWJGL [2.9.2, 3) https://github.com/LWJGL/lwjgl/issues/128
|
# xorg.xrandr needed for LWJGL [2.9.2, 3) https://github.com/LWJGL/lwjgl/issues/128
|
||||||
wrapQtApp $out/bin/prismlauncher \
|
"--prefix PATH : ${lib.makeBinPath [xorg.xrandr]}"
|
||||||
--set LD_LIBRARY_PATH /run/opengl-driver/lib:${libpath} \
|
];
|
||||||
--prefix PRISMLAUNCHER_JAVA_PATHS : ${lib.makeSearchPath "bin/java" jdks} \
|
|
||||||
--prefix PATH : ${lib.makeBinPath [xorg.xrandr]}
|
|
||||||
'';
|
|
||||||
|
|
||||||
meta = with lib; {
|
meta = with lib; {
|
||||||
homepage = "https://prismlauncher.org/";
|
homepage = "https://prismlauncher.org/";
|
||||||
|
Loading…
Reference in New Issue
Block a user