Skip to content

Instantly share code, notes, and snippets.

@sioodmy
Created March 11, 2022 18:11
Show Gist options
  • Save sioodmy/caa8c307104088c078ce931f4b884eeb to your computer and use it in GitHub Desktop.
Save sioodmy/caa8c307104088c078ce931f4b884eeb to your computer and use it in GitHub Desktop.
Rust crow nix-shell example
{ pkgs ? import <nixpkgs> {} }:
with pkgs; mkShell {
nativeBuildInputs = [
pkgconfig
clang lld # To use lld linker
];
buildInputs = [
udev alsaLib vulkan-loader libGL egl-wayland
x11 xorg.libXcursor xorg.libXrandr xorg.libXi # To use x11 feature
libxkbcommon wayland # To use wayland feature
];
shellHook = ''export LD_LIBRARY_PATH="$LD_LIBRARY_PATH:${pkgs.lib.makeLibraryPath [
udev alsaLib vulkan-loader libGL
libxkbcommon wayland # To use wayland feature
]}"'';
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment