Advertisement
Guest User

Untitled

a guest
May 10th, 2023
68
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.19 KB | None | 0 0
  1. {
  2. inputs = {
  3. nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable";
  4. flake-utils.url = "github:numtide/flake-utils";
  5. nixgl.url = "github:guibou/nixGL";
  6. };
  7.  
  8. outputs = inputs @ {
  9. nixpkgs,
  10. flake-utils,
  11. ...
  12. }: flake-utils.lib.eachDefaultSystem (system: let
  13. pkgs = import nixpkgs {
  14. inherit system;
  15. overlays = [ inputs.nixgl.overlay ];
  16. };
  17. libPath = with pkgs; lib.makeLibraryPath [
  18. libGL
  19. libxkbcommon
  20. wayland
  21. xorg.libX11
  22. xorg.libXcursor
  23. xorg.libXi
  24. xorg.libXrandr
  25. ];
  26. in {
  27. formatter = pkgs.alejandra;
  28.  
  29. devShells.default = pkgs.mkShell.override {
  30. stdenv = pkgs.clang14Stdenv;
  31. } {
  32. packages = with pkgs; [
  33. wayland
  34. xorg.libX11
  35. xorg.libXrandr
  36. xorg.libXinerama
  37. xorg.libXcursor
  38. xorg.libXi
  39. libxkbcommon
  40. libGL
  41. libglvnd
  42.  
  43. nixgl.auto.nixGLDefault
  44.  
  45. pkgconfig
  46.  
  47. just
  48. ninja
  49. meson
  50. ];
  51.  
  52. # ...
  53. LD_LIBRARY_PATH = libPath + "/run/opengl-driver/lib:/run/opengl-driver-32/lib";
  54. };
  55. });
  56. }
  57.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement