factor package expression into a function
We'll need to call it repeatedly to make packages for cross.
This commit is contained in:
parent
3ac9be5a78
commit
67d280dd2e
1 changed files with 7 additions and 5 deletions
12
flake.nix
12
flake.nix
|
@ -50,9 +50,8 @@
|
|||
ROCKSDB_INCLUDE_DIR = "${pkgs.rocksdb}/include";
|
||||
ROCKSDB_LIB_DIR = "${pkgs.rocksdb}/lib";
|
||||
};
|
||||
in
|
||||
{
|
||||
packages.default = builder pkgsHost {
|
||||
|
||||
package = pkgs: builder pkgs {
|
||||
src = nix-filter {
|
||||
root = ./.;
|
||||
include = [
|
||||
|
@ -65,11 +64,14 @@
|
|||
# This is redundant with CI
|
||||
doCheck = false;
|
||||
|
||||
env = env pkgsHost;
|
||||
nativeBuildInputs = nativeBuildInputs pkgsHost;
|
||||
env = env pkgs;
|
||||
nativeBuildInputs = nativeBuildInputs pkgs;
|
||||
|
||||
meta.mainProgram = cargoToml.package.name;
|
||||
};
|
||||
in
|
||||
{
|
||||
packages.default = package pkgsHost;
|
||||
|
||||
packages.oci-image =
|
||||
let
|
||||
|
|
Loading…
Add table
Reference in a new issue