[project @ 2005-11-08 14:20:28 by simonmar]
authorsimonmar <unknown>
Tue, 8 Nov 2005 14:20:28 +0000 (14:20 +0000)
committersimonmar <unknown>
Tue, 8 Nov 2005 14:20:28 +0000 (14:20 +0000)
more docs for GHC_PACKAGE_PATH

ghc/docs/users_guide/packages.xml

index b955f00..3bd65c6 100644 (file)
@@ -298,6 +298,7 @@ $ export GHC_PACKAGE_PATH=$HOME/.my-ghc-packages.conf:</screen>
       <para>To check whether your <literal>GHC_PACKAGE_PATH</literal> setting
        is doing the right thing, <literal>ghc-pkg list</literal> will list all
        the databases in use, in the reverse order they are searched.</para>
+      
     </sect3>
   </sect2>
 
@@ -403,6 +404,15 @@ $ export GHC_PACKAGE_PATH=$HOME/.my-ghc-packages.conf:</screen>
       options are given, the rightmost one is used as the database to act
       upon.</para>
 
+    <para>If the environment variable <literal>GHC_PACKAGE_PATH</literal> is
+      set, and its value does not end in a separator (<literal>:</literal> on
+      Unix, <literal>;</literal> on Windows), then the last database is
+      considered to be the global database, and will be modified by default by
+      <literal>ghc-pkg</literal>.  The intention here is that
+      <literal>GHC_PACKAGE_PATH</literal> can be used to create a virtual
+      package environment into which Cabal packages can be installed without
+      setting anything other than <literal>GHC_PACKAGE_PATH</literal>.</para>
+
     <para>The <literal>ghc-pkg</literal> program may be run in the ways listed
       below.  Where a package name is required, the package can be named in
       full including the version number