[CMake] starting cpack and select the generator for CPACK

ycollette.nospam at free.fr ycollette.nospam at free.fr
Wed Jul 31 05:06:54 EDT 2013


hello,

I would like to start cpack using the cmake command.
For example, to start the test using cmake, I found the following command:

cd ${CMAKE_BINARY_DIR}
cmake --build . --target test

I think
cd ${CMAKE_BINARY_DIR}
cmake --build . --target package

should work, but I don't know how to specify the generator (ZIP or DEB for example).
The same question applied to ctest: how can I pass some options like '-R Python' using the cmake command.

My constraint is that I must use ant to launch cmake (and the cmake plugin seems to only know the cmake command. Neither ctest nor cpack).

Best regards,

YC


More information about the CMake mailing list