CMakeLists.txt 547 B

123456789101112131415161718192021
  1. find_package(Doxygen)
  2. if(NOT DOXYGEN_FOUND)
  3. message(FATAL_ERROR
  4. "Doxygen is needed to build the documentation.")
  5. endif()
  6. set(doxyfile bee2.doxy)
  7. set(doxy_html_index_file html/index.html)
  8. add_custom_command(OUTPUT ${doxy_html_index_file}
  9. COMMAND ${DOXYGEN_EXECUTABLE} ${doxyfile}
  10. WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}
  11. DEPENDS ${doxyfile}
  12. COMMENT "Generating HTML documentation")
  13. add_custom_target(doc ALL DEPENDS ${doxy_html_index_file})
  14. install(DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/html/
  15. DESTINATION share/bee2/doc)