Inital Commit
This commit is contained in:
commit
a309e824be
29 changed files with 2856 additions and 0 deletions
55
flake.nix
Normal file
55
flake.nix
Normal file
|
|
@ -0,0 +1,55 @@
|
|||
{
|
||||
description = "Rust Development Flake";
|
||||
|
||||
inputs = {
|
||||
nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable";
|
||||
flake-utils.url = "github:numtide/flake-utils";
|
||||
};
|
||||
|
||||
outputs = { self, nixpkgs, flake-utils, ... }:
|
||||
flake-utils.lib.eachDefaultSystem (system:
|
||||
let
|
||||
pkgs = import nixpkgs {
|
||||
inherit system;
|
||||
config = {
|
||||
allowUnfree = true;
|
||||
};
|
||||
};
|
||||
in
|
||||
{
|
||||
devShells.default = pkgs.mkShell {
|
||||
nativeBuildInputs = with pkgs; [
|
||||
pkg-config
|
||||
gcc
|
||||
gnumake
|
||||
python3
|
||||
sqlite
|
||||
];
|
||||
|
||||
buildInputs = with pkgs; [
|
||||
rustc
|
||||
cargo
|
||||
rust-analyzer
|
||||
rustfmt
|
||||
clippy
|
||||
|
||||
pkgs.cudaPackages.cuda_nvcc
|
||||
pkgs.cudaPackages.cudatoolkit
|
||||
|
||||
# --- LIBRARIES ---
|
||||
openssl
|
||||
libiconv
|
||||
glib
|
||||
libva
|
||||
];
|
||||
|
||||
shellHook = ''
|
||||
export CUDA_PATH=${pkgs.cudaPackages.cudatoolkit}
|
||||
export LD_LIBRARY_PATH=${pkgs.cudaPackages.cuda_nvcc}/lib:${pkgs.cudaPackages.cudatoolkit}/lib:/run/opengl-driver/lib:$LD_LIBRARY_PATH
|
||||
|
||||
|
||||
echo "Entered nix shell"
|
||||
'';
|
||||
};
|
||||
});
|
||||
}
|
||||
Loading…
Reference in a new issue