@@ -42,29 +42,30 @@ construction, so without them,
4242elements.)</para>
4343
4444<para>Even greater customisation is possible using the function
45−<varname>overrideDerivation</varname>. While the
45+<varname>overrideAttrs</varname>. While the
4646<varname>override</varname> mechanism above overrides the arguments of
47−a package function, <varname>overrideDerivation</varname> allows
48−changing the <emphasis>result</emphasis> of the function. This
49−permits changing any aspect of the package, such as the source code.
47+a package function, <varname>overrideAttrs</varname> allows
48+changing the <emphasis>attributes</emphasis> passed to <literal>mkDerivation</literal>.
49+This permits changing any aspect of the package, such as the source code.
5050For instance, if you want to override the source code of Emacs, you
5151can say:
5252
5353<programlisting>
54−environment.systemPackages =
55− [ (pkgs.lib.overrideDerivation pkgs.emacs (attrs: {
56− name = "emacs-25.0-pre";
57− src = /path/to/my/emacs/tree;
58− }))
59− ];
54+environment.systemPackages = [
55+ (pkgs.emacs.overrideAttrs (oldAttrs: {
56+ name = "emacs-25.0-pre";
57+ src = /path/to/my/emacs/tree;
58+ }))
59+];
6060</programlisting>
6161
62−Here, <varname>overrideDerivation</varname> takes the Nix derivation
62+Here, <varname>overrideAttrs</varname> takes the Nix derivation
6363specified by <varname>pkgs.emacs</varname> and produces a new
6464derivation in which the original’s <literal>name</literal> and
6565<literal>src</literal> attribute have been replaced by the given
66−values. The original attributes are accessible via
67−<varname>attrs</varname>.</para>
66+values by re-calling <literal>stdenv.mkDerivation</literal>.
67+The original attributes are accessible via the function argument,
68+which is conventionally named <varname>oldAttrs</varname>.</para>
6869
6970<para>The overrides shown above are not global. They do not affect
7071the original package; other packages in Nixpkgs continue to depend on