install generated man page

This commit is contained in:
Thomas Fussell 2017-09-08 17:07:25 -04:00
parent b065cea22f
commit 53d7dbb67e

View File

@ -224,6 +224,11 @@ if(NOT BIN_DEST_DIR)
set(BIN_DEST_DIR ${CMAKE_INSTALL_PREFIX}/bin) set(BIN_DEST_DIR ${CMAKE_INSTALL_PREFIX}/bin)
endif() endif()
if(NOT MAN_DEST_DIR)
# Default location to install runtime files
set(MAN_DEST_DIR ${CMAKE_INSTALL_PREFIX}/share/man)
endif()
# Install library # Install library
install(TARGETS xlnt install(TARGETS xlnt
LIBRARY DESTINATION ${LIB_DEST_DIR} LIBRARY DESTINATION ${LIB_DEST_DIR}
@ -235,6 +240,10 @@ install(DIRECTORY ${XLNT_INCLUDE_DIR}/xlnt
DESTINATION include DESTINATION include
PATTERN ".DS_Store" EXCLUDE) PATTERN ".DS_Store" EXCLUDE)
# Install LICENSE.md
install(FILES ${XLNT_ROOT_DIR}/docs/xlnt.3
DESTINATION ${MAN_DEST_DIR}/man3)
# Configure uninstall # Configure uninstall
configure_file("${XLNT_ROOT_DIR}/cmake/cmake_uninstall.cmake.in" configure_file("${XLNT_ROOT_DIR}/cmake/cmake_uninstall.cmake.in"
"${CMAKE_CURRENT_BINARY_DIR}/cmake_uninstall.cmake" "${CMAKE_CURRENT_BINARY_DIR}/cmake_uninstall.cmake"