doc/CMakeLists.txt
author Alpar Juttner <alpar@cs.elte.hu>
Tue, 22 Mar 2011 19:51:48 +0100
changeset 6 b995b17cd52b
child 8 dda9b6665fde
permissions -rw-r--r--
Add .hgeol
alpar@0
     1
SET(PACKAGE_NAME ${PROJECT_NAME})
alpar@0
     2
SET(PACKAGE_VERSION ${PROJECT_VERSION})
alpar@0
     3
SET(abs_top_srcdir ${PROJECT_SOURCE_DIR})
alpar@0
     4
SET(abs_top_builddir ${PROJECT_BINARY_DIR})
alpar@0
     5
alpar@0
     6
CONFIGURE_FILE(
alpar@0
     7
  ${PROJECT_SOURCE_DIR}/doc/Doxyfile.in
alpar@0
     8
  ${PROJECT_BINARY_DIR}/doc/Doxyfile
alpar@0
     9
  @ONLY)
alpar@0
    10
alpar@0
    11
IF(DOXYGEN_EXECUTABLE)
alpar@0
    12
  FILE(MAKE_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/html/)
alpar@0
    13
  IF(UNIX)
alpar@0
    14
    ADD_CUSTOM_TARGET(html
alpar@0
    15
      COMMAND rm -rf html
alpar@0
    16
      COMMAND ${DOXYGEN_EXECUTABLE} Doxyfile
alpar@0
    17
      WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR})
alpar@0
    18
  ELSEIF(WIN32)
alpar@0
    19
    ADD_CUSTOM_TARGET(html
alpar@0
    20
      COMMAND if exist html rmdir /s /q html
alpar@0
    21
      COMMAND ${DOXYGEN_EXECUTABLE} Doxyfile
alpar@0
    22
      WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR})
alpar@0
    23
  ENDIF(UNIX)
alpar@0
    24
  INSTALL(
alpar@0
    25
    DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/html/
alpar@0
    26
    DESTINATION share/doc
alpar@0
    27
    COMPONENT html_documentation)
alpar@0
    28
ENDIF(DOXYGEN_EXECUTABLE)