fix(droid): make new overlay changes work
All checks were successful
Discord / discord commits (push) Has been skipped

This commit is contained in:
matt1432 2024-09-23 01:58:59 -04:00
parent ac2c81f1ef
commit 18216b8874

View file

@ -14,7 +14,7 @@ inputs: rec {
};
allowModularOverrides = {
cudaSupport,
cudaSupport ? false,
system,
}: ({config, ...}: let
pkgs = mkPkgs {
@ -43,26 +43,31 @@ inputs: rec {
++ extraModules;
};
mkNixOnDroid = mods:
mkNixOnDroid = mods: let
system = "aarch64-linux";
in
inputs.nix-on-droid.lib.nixOnDroidConfiguration rec {
extraSpecialArgs = inputs;
home-manager-path = inputs.home-manager.outPath;
inherit (extraSpecialArgs) pkgs;
pkgs = mkPkgs {
inherit system;
inherit (inputs) nixpkgs;
};
modules =
[
(allowModularOverrides {system = "aarch64-linux";})
(allowModularOverrides {inherit system;})
({
config,
lib,
...
}: let
inherit (lib) mkOption types;
inherit (lib) mkForce mkOption types;
in {
# Adapt NixOnDroid to NixOS options
options.environment.variables = {
FLAKE = mkOption {
options.environment = {
variables.FLAKE = mkOption {
type = with types; nullOr str;
};
systemPackages = mkOption {
@ -72,6 +77,8 @@ inputs: rec {
};
config.environment.packages = config.environment.systemPackages;
# This disables the assertion that fails because of nixpkgs.overlays
config._module.args.isFlake = mkForce false;
})
{home-manager = {inherit extraSpecialArgs;};}