forked from botanix-labs/Macbeth
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathshell.nix
More file actions
32 lines (29 loc) · 936 Bytes
/
shell.nix
File metadata and controls
32 lines (29 loc) · 936 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
{ pkgs ? import <nixpkgs> {} }:
let
# this code allows setting an version fix overlay for Rust
# rustOverlay = import (builtins.fetchTarball "https://github.com/oxalica/rust-overlay/archive/master.tar.gz");
# pkgs = import <nixpkgs> { overlays = [ rustOverlay ]; };
# #rustVersion = "latest";
# rustVersion = "1.77.2";
# rust = pkgs.rust-bin.stable.${rustVersion}.default.override {
# extensions = [ "rust-analyzer" "rust-src" ];
# };
protobuf = pkgs.protobuf3_23;
in
pkgs.mkShell {
# buildInputs = [ rust protobuf ] ++ (with pkgs; [
buildInputs = [ protobuf ] ++ (with pkgs; [
pkg-config
openssl
glibc
clang
libclang
rustup
]);
# PROJECT_ROOT = builtins.toString ./.;
RUST_BACKTRACE = 1;
RUST_SRC_PATH = "${pkgs.rust.packages.stable.rustPlatform.rustLibSrc}";
LIBCLANG_PATH = "${pkgs.libclang.lib}/lib";
PROTOC = "${protobuf}/bin/protoc";
RUSTUP_TOOLCHAIN = "1.77.2";
}