diff options
author | John Ericson <Ericson2314@Yahoo.com> | 2016-04-26 10:53:31 -0700 |
---|---|---|
committer | John Ericson <Ericson2314@Yahoo.com> | 2016-07-14 14:33:23 -0700 |
commit | 4af2bf66631d187d952b70fba4963e33002d1dcb (patch) | |
tree | f1750f69a1519370f0ef7761fc66f9dbfd682982 /pkgs/top-level/default.nix | |
parent | 18a91ddfb66f2f3f706b93a874152a428874d346 (diff) | |
download | nixpkgs-4af2bf66631d187d952b70fba4963e33002d1dcb.tar nixpkgs-4af2bf66631d187d952b70fba4963e33002d1dcb.tar.gz nixpkgs-4af2bf66631d187d952b70fba4963e33002d1dcb.tar.bz2 nixpkgs-4af2bf66631d187d952b70fba4963e33002d1dcb.tar.lz nixpkgs-4af2bf66631d187d952b70fba4963e33002d1dcb.tar.xz nixpkgs-4af2bf66631d187d952b70fba4963e33002d1dcb.tar.zst nixpkgs-4af2bf66631d187d952b70fba4963e33002d1dcb.zip |
Separate fix-point from config importing hacks and other impurities
Diffstat (limited to 'pkgs/top-level/default.nix')
-rw-r--r-- | pkgs/top-level/default.nix | 19 |
1 files changed, 3 insertions, 16 deletions
diff --git a/pkgs/top-level/default.nix b/pkgs/top-level/default.nix index 8913dc1ef59..87813571d9a 100644 --- a/pkgs/top-level/default.nix +++ b/pkgs/top-level/default.nix @@ -6,7 +6,7 @@ { # The system (e.g., `i686-linux') for which to build the packages. - system ? builtins.currentSystem + system , # The standard environment to use. Only used for bootstrapping. If # null, the default standard environment is used. @@ -19,21 +19,8 @@ && system != "x86_64-solaris" && system != "x86_64-kfreebsd-gnu") -, # Allow a configuration attribute set to be passed in as an - # argument. Otherwise, it's read from $NIXPKGS_CONFIG or - # ~/.nixpkgs/config.nix. - # - # [For NixOS (nixos-rebuild), use nixpkgs.config option to set.] - config ? let - inherit (builtins) getEnv pathExists; - - configFile = getEnv "NIXPKGS_CONFIG"; - homeDir = getEnv "HOME"; - configFile2 = homeDir + "/.nixpkgs/config.nix"; - in - if configFile != "" && pathExists configFile then import configFile - else if homeDir != "" && pathExists configFile2 then import configFile2 - else {} +, # Allow a configuration attribute set to be passed in as an argument. + config ? {} , crossSystem ? null , platform ? null |