fix(discord): only add opengl paths to nvidia pc
All checks were successful
Discord / discord commits (push) Has been skipped
All checks were successful
Discord / discord commits (push) Has been skipped
This commit is contained in:
parent
8a3dad89b4
commit
51e6afac23
1 changed files with 8 additions and 4 deletions
|
@ -1,9 +1,12 @@
|
||||||
{
|
{
|
||||||
config,
|
config,
|
||||||
|
lib,
|
||||||
pkgs,
|
pkgs,
|
||||||
...
|
...
|
||||||
}: let
|
}: let
|
||||||
inherit (config.vars) mainUser;
|
inherit (config.vars) mainUser;
|
||||||
|
|
||||||
|
isNvidia = config.hardware.nvidia.modesetting.enable;
|
||||||
in {
|
in {
|
||||||
imports = [../dolphin.nix];
|
imports = [../dolphin.nix];
|
||||||
|
|
||||||
|
@ -58,10 +61,11 @@ in {
|
||||||
];
|
];
|
||||||
buildInputs = [makeWrapper];
|
buildInputs = [makeWrapper];
|
||||||
postBuild = ''
|
postBuild = ''
|
||||||
wrapProgram $out/bin/Discord --prefix LD_LIBRARY_PATH : "${lib.makeLibraryPath [
|
wrapProgram $out/bin/Discord ${lib.optionalString isNvidia
|
||||||
addOpenGLRunpath.driverLink
|
''--prefix LD_LIBRARY_PATH : "${lib.makeLibraryPath [
|
||||||
libglvnd
|
addOpenGLRunpath.driverLink
|
||||||
]}" \
|
libglvnd
|
||||||
|
]}"''} \
|
||||||
--add-flags "--enable-features=UseOzonePlatform --ozone-platform=wayland"
|
--add-flags "--enable-features=UseOzonePlatform --ozone-platform=wayland"
|
||||||
'';
|
'';
|
||||||
})
|
})
|
||||||
|
|
Loading…
Reference in a new issue