Skip to content
Snippets Groups Projects
Commit 4bb19ed2 authored by Edward Z. Yang's avatar Edward Z. Yang
Browse files

Document environment variables that can be used to change Paths values.


Signed-off-by: default avatarEdward Z. Yang <ezyang@cs.stanford.edu>
parent 5551eb3d
No related branches found
No related tags found
No related merge requests found
......@@ -242,6 +242,9 @@ generate pkg_descr lbi clbi =
-- | Generates the name of the environment variable controlling the path
-- component of interest.
--
-- Note: The format of these strings is part of Cabal's public API;
-- changing this function constitutes a *backwards-compatibility* break.
pkgPathEnvVar :: PackageDescription
-> String -- ^ path component; one of \"bindir\", \"libdir\",
-- \"datadir\", \"libexecdir\", or \"sysconfdir\"
......
......@@ -2071,6 +2071,15 @@ getLibexecDir :: IO FilePath
getSysconfDir :: IO FilePath
~~~~~~~~~~~~~~~
The actual location of all these directories can be individually
overridden at runtime using environment variables of the form
`pkg_name_var`, where `pkg_name` is the name of the package with
all hyphens converted into underscores, and `var` is either
`bindir`, `libdir`, `datadir`, `libexedir` or `sysconfdir`.
For example, the configured data directory for `pretty-show`
is controlled with the `pretty_show_datadir` environment variable.
### Accessing the package version ###
The aforementioned auto generated `Paths_`_pkgname_ module also
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment