This variable can be useful in cross-compiling contexts where the
sysroot is read-only or where the sysroot should otherwise remain
pristine.
If the new CMAKE_STAGING_PREFIX variable is set, it is used instead
of CMAKE_INSTALL_PREFIX when generating the installation rules in
cmake_install.cmake.
This way, the CMAKE_INSTALL_PREFIX variable
always refers to the installation prefix on the target device, regardless
of whether host==target.
If any -rpath paths passed to the linker contain the CMAKE_STAGING_PREFIX,
the matching path fragments are replaced with the CMAKE_INSTALL_PREFIX.
Matching paths in the -rpath-link are not transformed.
The cross-prefix usr-move workaround is assumed not to require extension
regarding CMAKE_STAGING_PREFIX. The staging area is a single prefix, so
there is no scope for cross-prefix symlinks. The CMAKE_INSTALL_PREFIX
is still used to determine the workaround path, and that variable
remains the relevant one even if CMAKE_STAGING_PREFIX is used. If the
generated export files are deployed to the target, the workaround
will still be in place, and still be employed if required.
In certain scenarios, it is preferable to keep a 'dirty' install prefix
than to clear it, and to expect that content will not be found there.
Add a CMAKE_FIND_NO_INSTALL_PREFIX variable that can be set to disable
searching the install prefix.
Commit dac78148 (...makes the mingw cross compiler work out of the
box..., 2007-08-02) added to CMAKE_SYSTEM_PROGRAM_PATH and
CMAKE_SYSTEM_LIBRARY_PATH paths like "/bin" and "/lib" with no Windows
drive letter so that cross-compiling to Windows from Linux would search
these paths under CMAKE_FIND_ROOT_PATH. Later commit 2a782880 (...use
CMAKE_SYSTEM_PREFIX_PATH when possible, 2008-01-16) generalized this
approach by instead adding "/" to CMAKE_SYSTEM_PREFIX_PATH.
Both commits assumed that the paths would never match anything on
Windows hosts without a drive letter. However, Windows evaluates these
paths relative to the current working drive letter so find_* commands
may report paths like "/lib/..." when paths like "c:/lib/..." exist on
what happens to be current drive. Such drive-less paths are not
reliable when the working drive changes, so we should not use them.
Fix WindowsPaths.cmake to add '/' to CMAKE_SYSTEM_PREFIX_PATH only when
cross-compiling to Windows from a non-Windows host. This will avoid
searching and finding local paths without a drive letter on Windows.
Block multiple inclusion because "Modules/CMakeCInformation.cmake"
includes "Platform/${CMAKE_SYSTEM_NAME}" even though the generic
module "CMakeSystemSpecificInformation.cmake" already included it.
The extra inclusion is a work-around to address issue #4772 without
intrusive platform file changes. Once those changes are made the
work-around and these include blockers can be removed. See issue #9656.
On 64-bit Windows there may be two Program Files folders, one for 32-bit
binaries and one for 64-bit binaries. When we compute
CMAKE_SYSTEM_PREFIX_PATH we should put both folders in the path.
-add /usr/openwin/include and /usr/openwin/lib to the default search paths
-add /${CMAKE_INSTALL_PREFIX}/(lib|bin|include) to the default cmake search
paths -> this should help users who install stuff in their home
Alex