Remove extraLinkPaths, thanks to Pierron for explanation

Now pathsToLink=["/include"] in configuration.nix will add /include instead of overwriting.

svn path=/nixos/trunk/; revision=21111
This commit is contained in:
Yury G. Kudryashov 2010-04-16 05:09:10 +00:00
parent c423f16f69
commit 8e8554242f
2 changed files with 7 additions and 14 deletions

View File

@ -7,6 +7,7 @@ with pkgs.lib;
let
cfg = config.environment;
requiredPackages =
[ config.system.sbin.modprobe # must take precedence over module_init_tools
config.system.sbin.mount # must take precedence over util-linux
@ -79,19 +80,10 @@ let
pathsToLink = mkOption {
# Note: We need `/lib' to be among `pathsToLink' for NSS modules
# to work.
default = ["/bin" "/sbin" "/lib" "/share/man" "/share/info" "/man" "/info"];
example = ["/"];
description = "
Lists directories to be symlinked in `/var/run/current-system/sw'.
Use extraLinkPaths if you want just to add some additional paths.
";
};
extraLinkPaths = mkOption {
default = [];
example = ["/"];
description = "
Extra directories to be symlinked in /var/run/current-system/sw.
Lists directories to be symlinked in `/var/run/current-system/sw'.
";
};
};
@ -99,7 +91,7 @@ let
system = {
path = mkOption {
default = config.environment.systemPackages;
default = cfg.systemPackages;
description = ''
The packages you want in the boot environment.
'';
@ -107,7 +99,7 @@ let
name = "system-path";
paths = list;
pathsToLink = with config.environment; pathsToLink ++ extraLinkPaths;
inherit (cfg) pathsToLink;
ignoreCollisions = true;
};
@ -124,4 +116,5 @@ in
require = [options];
environment.systemPackages = requiredPackages;
environment.pathsToLink = ["/bin" "/sbin" "/lib" "/share/man" "/share/info" "/man" "/info"];
}

View File

@ -1,7 +1,7 @@
{pkgs, config, ...}:
let
inherit (pkgs.lib) mkOption mkIf types;
inherit (pkgs.lib) mkDefaultValue mkOption mkIf types;
kdePackages = config.environment.kdePackages;
options = {
@ -30,6 +30,6 @@ mkIf (kdePackages != [] && config.services.xserver.enable) {
environment = {
x11Packages = kdePackages;
systemPackages = kdePackages;
extraLinkPaths = [ "/share" "/plugins" ];
pathsToLink = [ "/share" "/plugins" ];
};
}