File tree Expand file tree Collapse file tree 2 files changed +61
-0
lines changed Expand file tree Collapse file tree 2 files changed +61
-0
lines changed Original file line number Diff line number Diff line change 1+ {
2+ rustPlatform ,
3+ glib ,
4+ pkg-config ,
5+ } :
6+ rustPlatform . buildRustPackage {
7+ name = "ripasso" ;
8+ src = ./. ;
9+ buildInputs = [ glib ] ;
10+ nativeBuildInputs = [ pkg-config ] ;
11+ cargoHash = "sha256-UMhQgijZuZW2O/0Jk5Zn8P368KnDWZRXj5e1nDG40Gw=" ;
12+ }
Original file line number Diff line number Diff line change 1+ {
2+ description = "Rust flake" ;
3+
4+ inputs = {
5+ nixpkgs . url = "github:nixos/nixpkgs/nixos-unstable" ;
6+ } ;
7+
8+ outputs = { self , nixpkgs , ... } @inputs :
9+ let
10+ system = "x86_64-linux" ;
11+ pkgs = import nixpkgs { inherit system ; } ;
12+
13+ clangLibPath = "${ pkgs . libclang . lib } /lib" ;
14+ opensslDev = pkgs . openssl . dev ;
15+ opensslOut = pkgs . openssl . out ;
16+ in
17+ {
18+ devShells . ${ system } . default = pkgs . mkShell {
19+ packages = with pkgs ; [
20+ rustc
21+ cargo
22+ clang
23+ libclang
24+ openssl
25+ pkg-config
26+ libgpg-error
27+ nettle
28+ gpgme
29+ ripasso-cursive
30+ ] ;
31+
32+ shellHook = ''
33+ # Clang
34+ export LIBCLANG_PATH=${ clangLibPath }
35+ export LD_LIBRARY_PATH=${ clangLibPath } :${ opensslOut } /lib:$LD_LIBRARY_PATH
36+
37+ # OpenSSL
38+ export OPENSSL_NO_VENDOR=1
39+ export OPENSSL_LIB_DIR=${ opensslOut } /lib
40+ export OPENSSL_INCLUDE_DIR=${ opensslDev } /include
41+
42+ echo " LIBCLANG_PATH = $LIBCLANG_PATH"
43+ echo " LD_LIBRARY_PATH = $LD_LIBRARY_PATH"
44+ echo " OPENSSL_LIB_DIR = $OPENSSL_LIB_DIR"
45+ echo " OPENSSL_INCLUDE_DIR = $OPENSSL_INCLUDE_DIR"
46+ '' ;
47+ } ;
48+ } ;
49+ }
You can’t perform that action at this time.
0 commit comments