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