making nix build the api
This commit is contained in:
parent
0ccbe35ca3
commit
39d5d0536e
37
flake.lock
37
flake.lock
|
@ -49,11 +49,46 @@
|
|||
"type": "github"
|
||||
}
|
||||
},
|
||||
"nixpkgs_2": {
|
||||
"locked": {
|
||||
"lastModified": 1718428119,
|
||||
"narHash": "sha256-WdWDpNaq6u1IPtxtYHHWpl5BmabtpmLnMAx0RdJ/vo8=",
|
||||
"owner": "NixOS",
|
||||
"repo": "nixpkgs",
|
||||
"rev": "e6cea36f83499eb4e9cd184c8a8e823296b50ad5",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "NixOS",
|
||||
"ref": "nixpkgs-unstable",
|
||||
"repo": "nixpkgs",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"root": {
|
||||
"inputs": {
|
||||
"cl-nix-lite": "cl-nix-lite",
|
||||
"flake-utils": "flake-utils",
|
||||
"nixpkgs": "nixpkgs"
|
||||
"nixpkgs": "nixpkgs",
|
||||
"rust-overlay": "rust-overlay"
|
||||
}
|
||||
},
|
||||
"rust-overlay": {
|
||||
"inputs": {
|
||||
"nixpkgs": "nixpkgs_2"
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1720145907,
|
||||
"narHash": "sha256-mNO3vfM43+w4Bp+zMC8Dkf4ktLpYYRpk9tAOp4iumio=",
|
||||
"owner": "oxalica",
|
||||
"repo": "rust-overlay",
|
||||
"rev": "5ad2d5884b9b16319c9c5ca4e80a5b8606b083ae",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "oxalica",
|
||||
"repo": "rust-overlay",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"systems": {
|
||||
|
|
70
flake.nix
70
flake.nix
|
@ -5,18 +5,82 @@
|
|||
nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable";
|
||||
flake-utils.url = "github:numtide/flake-utils";
|
||||
cl-nix-lite.url = "github:hraban/cl-nix-lite";
|
||||
rust-overlay.url = "github:oxalica/rust-overlay";
|
||||
};
|
||||
|
||||
outputs = { self, nixpkgs, flake-utils, cl-nix-lite }:
|
||||
outputs = inputs: with inputs;
|
||||
flake-utils.lib.eachDefaultSystem
|
||||
(system:
|
||||
let
|
||||
pkgs = nixpkgs.legacyPackages.${system}.extend cl-nix-lite.overlays.default;
|
||||
pkgs = nixpkgs.legacyPackages.${system};
|
||||
src = ./.;
|
||||
|
||||
sbcl' = pkgs.sbcl.withPackages (ps: with ps; [
|
||||
hunchentoot
|
||||
dexador
|
||||
jzon
|
||||
serapeum
|
||||
deploy
|
||||
spinneret
|
||||
lass
|
||||
cl-smtp
|
||||
log4cl
|
||||
cl_plus_ssl
|
||||
fiveam
|
||||
slite
|
||||
pkgs.openssl
|
||||
pkgs.openssl.out
|
||||
pkgs.openssl.dev
|
||||
]);
|
||||
nbi = with pkgs; [
|
||||
gcc
|
||||
stdenv
|
||||
gnumake
|
||||
gdb
|
||||
pkg-config
|
||||
makeWrapper
|
||||
openssl
|
||||
openssl.out
|
||||
openssl.dev
|
||||
];
|
||||
|
||||
bi = with pkgs; [
|
||||
hugo
|
||||
go
|
||||
nodejs
|
||||
sbcl'
|
||||
clippy
|
||||
rustc
|
||||
cargo
|
||||
rustfmt
|
||||
rust-analyzer
|
||||
just
|
||||
openssl
|
||||
openssl.out
|
||||
openssl.dev
|
||||
];
|
||||
|
||||
nativeLibs = with pkgs; [
|
||||
openssl
|
||||
openssl.out
|
||||
openssl.dev
|
||||
];
|
||||
|
||||
in
|
||||
{
|
||||
devShell = import ./shell.nix { inherit pkgs; };
|
||||
packages.default = pkgs.callPackage ./default.nix { };
|
||||
packages.default = pkgs.rustPlatform.buildRustPackage {
|
||||
pname = "api";
|
||||
version = "0.0.1";
|
||||
src = src;
|
||||
cargoBuildFlags = "";
|
||||
|
||||
cargoLock = {
|
||||
lockFile = ./Cargo.lock;
|
||||
};
|
||||
nativeBuildInputs = nbi;
|
||||
buildInputs = bi;
|
||||
};
|
||||
}
|
||||
);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue