summaryrefslogtreecommitdiffstats
path: root/Doc/using
diff options
context:
space:
mode:
authorJulien Palard <julien@palard.fr>2023-03-15 15:10:03 (GMT)
committerGitHub <noreply@github.com>2023-03-15 15:10:03 (GMT)
commit61b9ff35cbda0cc59816951a17de073968fc25c6 (patch)
tree50772e4807d00fd09a471769a747c47589a2fae4 /Doc/using
parentafa6092ee4260bacf7bc11905466e4c3f8556cbb (diff)
downloadcpython-61b9ff35cbda0cc59816951a17de073968fc25c6.zip
cpython-61b9ff35cbda0cc59816951a17de073968fc25c6.tar.gz
cpython-61b9ff35cbda0cc59816951a17de073968fc25c6.tar.bz2
gh-101100: Documenting --prefix and --exec-prefix. (GH-102695)
Co-authored-by: Erlend E. Aasland <erlend.aasland@protonmail.com>
Diffstat (limited to 'Doc/using')
-rw-r--r--Doc/using/configure.rst16
-rw-r--r--Doc/using/unix.rst2
2 files changed, 17 insertions, 1 deletions
diff --git a/Doc/using/configure.rst b/Doc/using/configure.rst
index 8936bd3..ce858ab 100644
--- a/Doc/using/configure.rst
+++ b/Doc/using/configure.rst
@@ -216,6 +216,22 @@ WebAssembly Options
Install Options
---------------
+.. cmdoption:: --prefix=PREFIX
+
+ Install architecture-independent files in PREFIX. On Unix, it
+ defaults to :file:`/usr/local`.
+
+ This value can be retrived at runtime using :data:`sys.prefix`.
+
+ As an example, one can use ``--prefix="$HOME/.local/"`` to install
+ a Python in its home directory.
+
+.. cmdoption:: --exec-prefix=EPREFIX
+
+ Install architecture-dependent files in EPREFIX, defaults to :option:`--prefix`.
+
+ This value can be retrived at runtime using :data:`sys.exec_prefix`.
+
.. cmdoption:: --disable-test-modules
Don't build nor install test modules, like the :mod:`test` package or the
diff --git a/Doc/using/unix.rst b/Doc/using/unix.rst
index 24c02c9..067ff4cc 100644
--- a/Doc/using/unix.rst
+++ b/Doc/using/unix.rst
@@ -93,7 +93,7 @@ Python-related paths and files
==============================
These are subject to difference depending on local installation conventions;
-:envvar:`prefix` (``${prefix}``) and :envvar:`exec_prefix` (``${exec_prefix}``)
+:option:`prefix <--prefix>` and :option:`exec_prefix <--exec-prefix>`
are installation-dependent and should be interpreted as for GNU software; they
may be the same.