CMake/Help/envvar/DESTDIR.rst
Joachim Wuttke (l) 26a70449cc Help: Describe environment variables as such.
In each environment variable doc page, insert an opening
paragraph (ENV_VAR.txt) to say that this is an environment
variable, and provide a link to the cmake-language section
on environment variables.
2018-11-13 09:29:36 +01:00

22 lines
707 B
ReStructuredText

DESTDIR
-------
.. include:: ENV_VAR.txt
On UNIX one can use the ``DESTDIR`` mechanism in order to relocate the
whole installation. ``DESTDIR`` means DESTination DIRectory. It is
commonly used by makefile users in order to install software at
non-default location. It is usually invoked like this:
::
make DESTDIR=/home/john install
which will install the concerned software using the installation
prefix, e.g. ``/usr/local`` prepended with the ``DESTDIR`` value which
finally gives ``/home/john/usr/local``.
WARNING: ``DESTDIR`` may not be used on Windows because installation
prefix usually contains a drive letter like in ``C:/Program Files``
which cannot be prepended with some other prefix.