diff options
-rw-r--r-- | Utilities/CMakeLists.txt | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/Utilities/CMakeLists.txt b/Utilities/CMakeLists.txt index 06160da..e3706d8 100644 --- a/Utilities/CMakeLists.txt +++ b/Utilities/CMakeLists.txt @@ -43,6 +43,24 @@ INSTALL_FILES(${CMAKE_DOC_DIR} FILES ) SET(DOC_FILES ${DOC_FILES} ${CMake_BINARY_DIR}/Docs/ctest.txt) +# Generate documentation for "cpack" executable. +GET_TARGET_PROPERTY(CMD cpack LOCATION) +ADD_CUSTOM_COMMAND( + OUTPUT ${CMake_BINARY_DIR}/Docs/cpack.txt + COMMAND ${CMD} + ARGS --help-full ${CMake_BINARY_DIR}/Docs/cpack.txt + --help-html ${CMake_BINARY_DIR}/Docs/cpack.html + --help-man ${CMake_BINARY_DIR}/Docs/cpack.1 + DEPENDS cpack + MAIN_DEPENDENCY ${CMake_SOURCE_DIR}/Utilities/Doxygen/authors.txt + ) +INSTALL_FILES(${CMAKE_MAN_DIR}/man1 FILES ${CMake_BINARY_DIR}/Docs/cpack.1) +INSTALL_FILES(${CMAKE_DOC_DIR} FILES + ${CMake_BINARY_DIR}/Docs/cpack.txt + ${CMake_BINARY_DIR}/Docs/cpack.html + ) +SET(DOC_FILES ${DOC_FILES} ${CMake_BINARY_DIR}/Docs/cpack.txt) + # Generate documentation for "ccmake" executable. IF(BUILD_CursesDialog) GET_TARGET_PROPERTY(CMD ccmake LOCATION) |