diff options
author | Eelco Dolstra <eelco.dolstra@logicblox.com> | 2003-11-03 10:22:00 +0000 |
---|---|---|
committer | Eelco Dolstra <eelco.dolstra@logicblox.com> | 2003-11-03 10:22:00 +0000 |
commit | 77d20ed7997f754ea5e7665d42442b2ac7d89700 (patch) | |
tree | f4091b4cddcb9eb5ca64ae8075120cf7348de714 /pkgs-ng/system | |
parent | 2041469c69ce0717b1cb0bba06a408564070ae0e (diff) |
* Updated to reflect the changes to the grammar.
svn path=/nixpkgs/trunk/; revision=464
Diffstat (limited to 'pkgs-ng/system')
-rw-r--r-- | pkgs-ng/system/all-packages-generic.fix | 146 | ||||
-rw-r--r-- | pkgs-ng/system/all-packages.fix | 52 | ||||
-rw-r--r-- | pkgs-ng/system/i686-suse-linux.fix | 2 | ||||
-rw-r--r-- | pkgs-ng/system/user-environment.fix | 29 |
4 files changed, 122 insertions, 107 deletions
diff --git a/pkgs-ng/system/all-packages-generic.fix b/pkgs-ng/system/all-packages-generic.fix index b8fea1bf96d50..d31bdb5d4940f 100644 --- a/pkgs-ng/system/all-packages-generic.fix +++ b/pkgs-ng/system/all-packages-generic.fix @@ -2,108 +2,110 @@ # identifier and a standard build environment, returns the set of all # packages provided by the Nix Package Collection. -{system, stdenv}: rec - { fetchurl = (import ../build-support/fetchurl) - { stdenv = stdenv - } +{system, stdenv}: rec { + + # build-support/fetchurl + fetchurl = (import ../build-support/fetchurl) { + stdenv = stdenv; + }; # sys-utils/coreutils - , coreutils = (import ../sys-utils/coreutils) - { fetchurl = fetchurl - , stdenv = stdenv - } + coreutils = (import ../sys-utils/coreutils) { + fetchurl = fetchurl; + stdenv = stdenv; + }; # sys-utils/findutils - , findutils = (import ../sys-utils/findutils) - { fetchurl = fetchurl - , stdenv = stdenv - } + findutils = (import ../sys-utils/findutils) { + fetchurl = fetchurl; + stdenv = stdenv; + }; # sys-utils/diffutils - , diffutils = (import ../sys-utils/diffutils) - { fetchurl = fetchurl - , stdenv = stdenv - } + diffutils = (import ../sys-utils/diffutils) { + fetchurl = fetchurl; + stdenv = stdenv; + }; # sys-utils/gnused - , gnused = (import ../sys-utils/gnused) - { fetchurl = fetchurl - , stdenv = stdenv - } + gnused = (import ../sys-utils/gnused) { + fetchurl = fetchurl; + stdenv = stdenv; + }; # sys-utils/gnugrep - , gnugrep = (import ../sys-utils/gnugrep) - { fetchurl = fetchurl - , stdenv = stdenv - , pcre = pcre - } + gnugrep = (import ../sys-utils/gnugrep) { + fetchurl = fetchurl; + stdenv = stdenv; + pcre = pcre; + }; # sys-utils/gawk - , gawk = (import ../sys-utils/gawk) - { fetchurl = fetchurl - , stdenv = stdenv - } + gawk = (import ../sys-utils/gawk) { + fetchurl = fetchurl; + stdenv = stdenv; + }; # archivers/gnutar - , gnutar = (import ../archivers/gnutar) - { fetchurl = fetchurl - , stdenv = stdenv - } + gnutar = (import ../archivers/gnutar) { + fetchurl = fetchurl; + stdenv = stdenv; + }; # compression/gzip - , gzip = (import ../compression/gzip) - { fetchurl = fetchurl - , stdenv = stdenv - } + gzip = (import ../compression/gzip) { + fetchurl = fetchurl; + stdenv = stdenv; + }; # shells/bash - , bash = (import ../shells/bash) - { fetchurl = fetchurl - , stdenv = stdenv - } + bash = (import ../shells/bash) { + fetchurl = fetchurl; + stdenv = stdenv; + }; # devel/tools/binutils - , binutils = (import ../devel/tools/binutils) - { fetchurl = fetchurl - , stdenv = stdenv - } + binutils = (import ../devel/tools/binutils) { + fetchurl = fetchurl; + stdenv = stdenv; + }; # devel/tools/gnumake - , gnumake = (import ../devel/tools/gnumake) - { fetchurl = fetchurl - , stdenv = stdenv - } + gnumake = (import ../devel/tools/gnumake) { + fetchurl = fetchurl; + stdenv = stdenv; + }; # devel/compilers/gcc - , gcc = (import ../devel/compilers/gcc) - { fetchurl = fetchurl - , stdenv = stdenv - , binutils = binutils - } + gcc = (import ../devel/compilers/gcc) { + fetchurl = fetchurl; + stdenv = stdenv; + binutils = binutils; + }; # devel/libs/pcre - , pcre = (import ../devel/libs/pcre) - { fetchurl = fetchurl - , stdenv = stdenv - } + pcre = (import ../devel/libs/pcre) { + fetchurl = fetchurl; + stdenv = stdenv; + }; # devel/libs/glibc - , glibc = (import ../devel/libs/glibc) - { fetchurl = fetchurl - , stdenv = stdenv - , kernelHeaders = kernelHeaders - } + glibc = (import ../devel/libs/glibc) { + fetchurl = fetchurl; + stdenv = stdenv; + kernelHeaders = kernelHeaders; + }; # devel/libs/aterm - , aterm = (import ../devel/libs/aterm) - { fetchurl = fetchurl - , stdenv = stdenv - } + aterm = (import ../devel/libs/aterm) { + fetchurl = fetchurl; + stdenv = stdenv; + }; # os-specific/linux/kernel-headers - , kernelHeaders = (import ../os-specific/linux/kernel-headers) - { fetchurl = fetchurl - , stdenv = stdenv - } + kernelHeaders = (import ../os-specific/linux/kernel-headers) { + fetchurl = fetchurl; + stdenv = stdenv; + }; - } +} diff --git a/pkgs-ng/system/all-packages.fix b/pkgs-ng/system/all-packages.fix index 4410ce7f7b96e..d0228c3da1e99 100644 --- a/pkgs-ng/system/all-packages.fix +++ b/pkgs-ng/system/all-packages.fix @@ -8,43 +8,43 @@ # Posix utilities, the GNU C compiler, and so on. On other systems, # we use the native C library. -{system}: let - { allPackages = import ./all-packages-generic.fix +{system}: let { + allPackages = import ./all-packages-generic.fix; # The native (i.e., impure) build environment. This one uses the # tools installed on the system outside of the Nix environment, # i.e., the stuff in /bin, /usr/bin, etc. This environment should # be used with care, since many Nix packages will not build properly # with it (e.g., because they require GNU Make). - , stdenvNative = (import ../stdenv/native) {system = system} - , stdenvNativePkgs = allPackages {system = system, stdenv = stdenvNative} + stdenvNative = (import ../stdenv/native) {system = system}; + stdenvNativePkgs = allPackages {system = system; stdenv = stdenvNative}; # The Nix build environment. - , stdenvNix = (import ../stdenv/nix) - { bootStdenv = stdenvNative - , pkgs = stdenvNativePkgs - } - , stdenvNixPkgs = allPackages {system = system, stdenv = stdenvNix} + stdenvNix = (import ../stdenv/nix) { + bootStdenv = stdenvNative; + pkgs = stdenvNativePkgs; + }; + stdenvNixPkgs = allPackages {system = system; stdenv = stdenvNix}; # The Linux build environment consists of the Nix build environment # built against the GNU C Library. - , stdenvLinuxGlibc = stdenvNativePkgs.glibc - , stdenvLinuxBoot = (import ../stdenv/nix-linux/boot.fix) - { system = system - , glibc = stdenvLinuxGlibc - } - , stdenvLinuxBootPkgs = allPackages {system = system, stdenv = stdenvLinuxBoot} + stdenvLinuxGlibc = stdenvNativePkgs.glibc; + stdenvLinuxBoot = (import ../stdenv/nix-linux/boot.fix) { + system = system; + glibc = stdenvLinuxGlibc; + }; + stdenvLinuxBootPkgs = allPackages {system = system; stdenv = stdenvLinuxBoot}; - , stdenvLinux = (import ../stdenv/nix-linux) - { bootStdenv = stdenvLinuxBoot - , pkgs = stdenvLinuxBootPkgs - , glibc = stdenvLinuxGlibc - } - , stdenvLinuxPkgs = allPackages {system = system, stdenv = stdenvLinux} + stdenvLinux = (import ../stdenv/nix-linux) { + bootStdenv = stdenvLinuxBoot; + pkgs = stdenvLinuxBootPkgs; + glibc = stdenvLinuxGlibc; + }; + stdenvLinuxPkgs = allPackages {system = system; stdenv = stdenvLinux}; # Select the right instantiation. - , body = - if system == "i686-suse-linux" - then stdenvLinuxPkgs - else stdenvNixPkgs - } + body = + if system == "i686-suse-linux" + then stdenvLinuxPkgs + else stdenvNixPkgs; +} diff --git a/pkgs-ng/system/i686-suse-linux.fix b/pkgs-ng/system/i686-suse-linux.fix index dc5f426b5f5b0..bb5128277998e 100644 --- a/pkgs-ng/system/i686-suse-linux.fix +++ b/pkgs-ng/system/i686-suse-linux.fix @@ -1 +1 @@ -(import ./user-environment.fix) { system = "i686-suse-linux" } +(import ./user-environment.fix) {system = "i686-suse-linux"} diff --git a/pkgs-ng/system/user-environment.fix b/pkgs-ng/system/user-environment.fix index 5a46ed6f111a9..40e8008281c58 100644 --- a/pkgs-ng/system/user-environment.fix +++ b/pkgs-ng/system/user-environment.fix @@ -1,8 +1,21 @@ -{system}: derivation - { name = "user-environment" - , system = system - , builder = ./populate-linkdirs.pl - , pkgs = - [ ((import ./all-packages.fix) {system = system}).aterm - ] - } +# Given a system identifier, this function returns a derivation of a +# user environment, i.e., a set of symbolic links to `activated' +# packages. The resulting package is typically passed to the +# `nix-switch' command in order to actually activate it. + +{system}: let { + # All activated packages. + pkgs = (import ./all-packages.fix) {system = system}; + + # This + selectedPkgs = + [ pkgs.aterm + ]; + + body = derivation { + name = "user-environment"; + system = system; + builder = ./populate-linkdirs.pl; + dirs = selectedPkgs; + }; +} |