Part 12 : Program to get installtion path
Installation paths are important. PhoenixCMake generates also a program which contains all the usefull installation prefix :
- --prefix : global installation prefix
- --bin : binary path
- --lib : library path
- --include : include path
- --share : share path
- --modulepath : cmake module path (CMAKE_MODULE_PATH)
- --cmake : cmake arguments to compile with the same prefix as the current program (prefix and module path)
Example with PhoenixCMake :
phoenixcmake-config --help Phoenix Config provides a script to get installation path of current project. Thus, it can be used with other build system. Usage : phoenixcmake-config --prefix phoenixcmake-config --bin phoenixcmake-config --lib phoenixcmake-config --include phoenixcmake-config --share phoenixcmake-config --modulepath phoenixcmake-config --cmake Options : --prefix : installation prefix of the current project --bin : binary directory --lib : library directory --include : include directory --share : share directory --modulepath : CMAKE_MODULE_PATH directory --cmake : CMake arguments to compile with the same prefix as the current program
Now we can compile an other project such as PhoenixString simply :
cmake .. $(phoenixcmake-config --cmake) make install -j $(nproc)
Will install the project PhoenixString at the same place as PhoenixCMake. You to not have to search it to have the good installation path.