[CMake] Abstracting part of path name in CMakeCache

Jay Cotton lbmgmusic at gmail.com
Wed Oct 7 18:42:53 EDT 2015


Hi:

I have a need to abstract part of the build path name in CMakeCache:  Here
is an excerpt

# This is the CMakeCache file.
# For build in directory:
/export/home/xxxxx/x-s12-clone/open-src/xserver/xvnc/unpacked-src

This string is seen 5 times in the cache file.  I need it to look like:

# For build in directory: [DISCOVERD_AT_RUNTIME]/unpacked-src

This is needed because I have to modify the Cache file, and I want to keep
the
modified version, and not try to patch it at build time.  But, it there is
a way to
fill in the front of the build directory name, that will solve a major
problem.  We
use build farms and there is no way to predict what the path name will be
prior
to the build.

I did check the -[D/etc] commands, they don't seem to provide an answer.

Thanks for your help

jc
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://public.kitware.com/pipermail/cmake/attachments/20151007/cc65b158/attachment.html>


More information about the CMake mailing list