According to the previous answer, I can tell CMake to use use phantom-dir
to place cache files in it by using
cmake -H. -Bphantom-dir
However, I need three further customization:
The
Makefile
should be created inside in the current directory notphantom-dir
.The executable output of
Makefile
should be in the current directory too.I need that
-H. -Bphantom-dir
be embedded inCMakeLists.txt
hence a typical user will call cmake in the normal way bycmake .
Are these customizations implementable?