liminix-fork/default.nix
Daniel Barlow b2f7a429f7 build a kernel, using malta_kvm_defconfig
(there's a lot in this config that I don't think is needed)
2022-09-20 18:54:27 +01:00

29 lines
769 B
Nix

{ device ? (import devices/gl-ar750.nix)
}:
let
overlay = import ./overlay.nix;
nixpkgs = import <nixpkgs> ( device.system // {overlays = [overlay]; });
baseConfig = {
systemPackages = [];
services = {};
kernel = device.kernel;
};
config = baseConfig // (import <liminix-config>) {
config = baseConfig;
tools = nixpkgs.pkgs.callPackage ./tools {};
inherit (nixpkgs) pkgs;
};
finalConfig = config // {
packages = (with nixpkgs.pkgs; [ s6-rc ]) ++
config.systemPackages ++
(builtins.attrValues config.services)
;
};
squashfs = (import ./make-image.nix) nixpkgs finalConfig;
kernel = (import ./make-kernel.nix) nixpkgs finalConfig;
in {
outputs = {
inherit squashfs kernel;
};
}