about summary refs log tree commit diff
path: root/doc
diff options
context:
space:
mode:
authorTuomas Tynkkynen <tuomas@tuxera.com>2016-09-01 13:27:27 +0300
committerTuomas Tynkkynen <tuomas@tuxera.com>2016-09-01 13:27:27 +0300
commit8c4aeb17808e6d33515bb9178eaca942c588b31d (patch)
tree202a33b2dd86ab28d168778b313f184a9ecc0bda /doc
parent003ab1d9fdaf2818a1e5a6e53825d31ac2e23621 (diff)
parent838c75398cc46cf2acbe144b1f3866d736abe430 (diff)
downloadnixlib-8c4aeb17808e6d33515bb9178eaca942c588b31d.tar
nixlib-8c4aeb17808e6d33515bb9178eaca942c588b31d.tar.gz
nixlib-8c4aeb17808e6d33515bb9178eaca942c588b31d.tar.bz2
nixlib-8c4aeb17808e6d33515bb9178eaca942c588b31d.tar.lz
nixlib-8c4aeb17808e6d33515bb9178eaca942c588b31d.tar.xz
nixlib-8c4aeb17808e6d33515bb9178eaca942c588b31d.tar.zst
nixlib-8c4aeb17808e6d33515bb9178eaca942c588b31d.zip
Merge staging into master
Brings in:
    - changed output order for multiple outputs:
      https://github.com/NixOS/nixpkgs/pull/14766
    - audit disabled by default
      https://github.com/NixOS/nixpkgs/pull/17916

 Conflicts:
	pkgs/development/libraries/openldap/default.nix
Diffstat (limited to 'doc')
-rw-r--r--doc/multiple-output.xml6
1 files changed, 3 insertions, 3 deletions
diff --git a/doc/multiple-output.xml b/doc/multiple-output.xml
index 1821861adf71..309254f76aac 100644
--- a/doc/multiple-output.xml
+++ b/doc/multiple-output.xml
@@ -29,15 +29,15 @@
 
 <section><title>Using a split package</title>
   <para>In the Nix language the individual outputs can be reached explicitly as attributes, e.g. <varname>coreutils.info</varname>, but the typical case is just using packages as build inputs.</para>
-  <para>When a multiple-output derivation gets into a build input of another derivation, the first output is added (<varname>.dev</varname> by convention) and also <varname>propagatedBuildOutputs</varname> of that package which by default contain <varname>$outputBin</varname> and <varname>$outputLib</varname>. (See <xref linkend="multiple-output-file-type-groups" />.)</para>
+  <para>When a multiple-output derivation gets into a build input of another derivation, the <varname>dev</varname> output is added if it exists, otherwise the first output is added. In addition to that, <varname>propagatedBuildOutputs</varname> of that package which by default contain <varname>$outputBin</varname> and <varname>$outputLib</varname> are also added. (See <xref linkend="multiple-output-file-type-groups" />.)</para>
 </section>
 
 
 <section><title>Writing a split derivation</title>
   <para>Here you find how to write a derivation that produces multiple outputs.</para>
   <para>In nixpkgs there is a framework supporting multiple-output derivations. It tries to cover most cases by default behavior.  You can find the source separated in &lt;<filename>nixpkgs/pkgs/build-support/setup-hooks/multiple-outputs.sh</filename>&gt;; it's relatively well-readable.  The whole machinery is triggered by defining the <varname>outputs</varname> attribute to contain the list of desired output names (strings).</para>
-  <programlisting>outputs = [ "dev" "out" "bin" "doc" ];</programlisting>
-  <para>Often such a single line is enough.  For each output an equally named environment variable is passed to the builder and contains the path in nix store for that output.  By convention, the first output should usually be <varname>dev</varname>; typically you also want to have the main <varname>out</varname> output, as it catches any files that didn't get elsewhere.</para>
+  <programlisting>outputs = [ "bin" "dev" "out" "doc" ];</programlisting>
+  <para>Often such a single line is enough.  For each output an equally named environment variable is passed to the builder and contains the path in nix store for that output.  By convention, the first output should contain the executable programs provided by the package as that output is used by Nix in string conversions, allowing references to binaries like <literal>${pkgs.perl}/bin/perl</literal> to always work. Typically you also want to have the main <varname>out</varname> output, as it catches any files that didn't get elsewhere.</para>
 
   <note><para>There is a special handling of the <varname>debug</varname> output, described at <xref linkend="stdenv-separateDebugInfo" />.</para></note>