mirror of
https://github.com/ilyakooo0/nixpkgs.git
synced 2024-11-18 02:05:51 +03:00
nixos/tests: remove minimal-kernel module
It's not used, doesn't build, and seems like the only reason to have `manualConfig` take `stdenv` as an argument.
This commit is contained in:
parent
cf568d20d5
commit
f677cbabe9
@ -3,9 +3,10 @@ let
|
|||||||
inherit (lib) mkIf mkOption types;
|
inherit (lib) mkIf mkOption types;
|
||||||
in
|
in
|
||||||
{
|
{
|
||||||
# This needs options.warnings, which we don't have (yet?).
|
# This needs options.warnings and options.assertions, which we don't have (yet?).
|
||||||
# imports = [
|
# imports = [
|
||||||
# (lib.mkRenamedOptionModule [ "machine" ] [ "nodes" "machine" ])
|
# (lib.mkRenamedOptionModule [ "machine" ] [ "nodes" "machine" ])
|
||||||
|
# (lib.mkRemovedOptionModule [ "minimal" ] "The minimal kernel module was removed as it was broken and not used any more in nixpkgs.")
|
||||||
# ];
|
# ];
|
||||||
|
|
||||||
options = {
|
options = {
|
||||||
|
@ -23,7 +23,7 @@ let
|
|||||||
nixpkgs.config.allowAliases = false;
|
nixpkgs.config.allowAliases = false;
|
||||||
})
|
})
|
||||||
testModuleArgs.config.extraBaseModules
|
testModuleArgs.config.extraBaseModules
|
||||||
] ++ optional config.minimal ../../modules/testing/minimal-kernel.nix;
|
];
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
@ -78,14 +78,6 @@ in
|
|||||||
'';
|
'';
|
||||||
};
|
};
|
||||||
|
|
||||||
minimal = mkOption {
|
|
||||||
type = types.bool;
|
|
||||||
default = false;
|
|
||||||
description = mdDoc ''
|
|
||||||
Enable to configure all [{option}`nodes`](#test-opt-nodes) to run with a minimal kernel.
|
|
||||||
'';
|
|
||||||
};
|
|
||||||
|
|
||||||
nodesCompat = mkOption {
|
nodesCompat = mkOption {
|
||||||
internal = true;
|
internal = true;
|
||||||
description = mdDoc ''
|
description = mdDoc ''
|
||||||
|
@ -1,28 +0,0 @@
|
|||||||
{ config, pkgs, lib, ... }:
|
|
||||||
|
|
||||||
let
|
|
||||||
configfile = builtins.storePath (builtins.toFile "config" (lib.concatStringsSep "\n"
|
|
||||||
(map (builtins.getAttr "configLine") config.system.requiredKernelConfig))
|
|
||||||
);
|
|
||||||
|
|
||||||
origKernel = pkgs.buildLinux {
|
|
||||||
inherit (pkgs.linux) src version stdenv;
|
|
||||||
inherit configfile;
|
|
||||||
allowImportFromDerivation = true;
|
|
||||||
kernelPatches = [ pkgs.kernelPatches.cifs_timeout_2_6_38 ];
|
|
||||||
};
|
|
||||||
|
|
||||||
kernel = origKernel // (derivation (origKernel.drvAttrs // {
|
|
||||||
configurePhase = ''
|
|
||||||
runHook preConfigure
|
|
||||||
mkdir ../build
|
|
||||||
make $makeFlags "''${makeFlagsArray[@]}" mrproper
|
|
||||||
make $makeFlags "''${makeFlagsArray[@]}" KCONFIG_ALLCONFIG=${configfile} allnoconfig
|
|
||||||
runHook postConfigure
|
|
||||||
'';
|
|
||||||
}));
|
|
||||||
|
|
||||||
kernelPackages = pkgs.linuxPackagesFor kernel;
|
|
||||||
in {
|
|
||||||
boot.kernelPackages = kernelPackages;
|
|
||||||
}
|
|
Loading…
Reference in New Issue
Block a user