cmake prefix equivalent to configure

How to mention prefix path for "cmake" same as ./configure --prefix=/home/dir1

cmake -DCMAKE_INSTALL_PREFIX:PATH=/home/dir1 . && make all install

This command will set the prefix path (install destionation) for build source, same as configure command.


Tags: Cmake, Prefix, Configure