diff options
Diffstat (limited to 'flake.nix')
| -rw-r--r-- | flake.nix | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/flake.nix b/flake.nix index 4e03888..702c355 100644 --- a/flake.nix +++ b/flake.nix @@ -25,9 +25,7 @@ libxcursor libxi libxkbcommon - # mesa - # wayland - # vulkan-loader + vulkan-loader ]; in { packages = forAllSystems (system: let pkgs = nixpkgsFor.${system}; in { @@ -38,8 +36,12 @@ nativeBuildInputs = with pkgs; [ autoPatchelfHook ]; }).overrideAttrs { + # This needs to apply only to the top-level derivation, not to the + # dependencies. preFixup = '' - patchelf --add-needed libxkbcommon-x11.so $out/bin/surreality + patchelf --add-needed libxkbcommon-x11.so \ + --add-needed libvulkan.so.1 \ + $out/bin/surreality ''; }; }); @@ -54,7 +56,7 @@ # This makes cargo run work; mind that you don't let it mask a # problem with the nix build. - LD_LIBRARY_PATH = "${pkgs.libxkbcommon}/lib"; + LD_LIBRARY_PATH = "${pkgs.libxkbcommon}/lib:${pkgs.vulkan-loader}/lib"; }; }); }; |