diff --git a/CMakeLists.txt b/CMakeLists.txt index 2d6f6423..3e5eb89a 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -297,6 +297,9 @@ endif() if (BUILDDOC) # Add a target to generate API documentation with Doxygen find_package (Doxygen REQUIRED) + # Set the full path to documenation (used by Doxygen STRIP_FROM_PATH) to + # generate html documentation with relative paths + set (DOXYGEN_STRIP_FROM_PATH ${PROJECT_SOURCE_DIR}) configure_file (${CMAKE_CURRENT_SOURCE_DIR}/doxy/Doxyfile.in ${CMAKE_CURRENT_BINARY_DIR}/Doxyfile @ONLY) if (BUILDSWIGJAVA) configure_file (${CMAKE_CURRENT_SOURCE_DIR}/doxy/Doxyfile.java.in ${CMAKE_CURRENT_BINARY_DIR}/Doxyfile-java @ONLY) diff --git a/doxy/Doxyfile.in b/doxy/Doxyfile.in index aba2bcf8..a7ef8a55 100644 --- a/doxy/Doxyfile.in +++ b/doxy/Doxyfile.in @@ -156,7 +156,7 @@ FULL_PATH_NAMES = YES # will be relative from the directory where doxygen is started. # This tag requires that the tag FULL_PATH_NAMES is set to YES. -STRIP_FROM_PATH = +STRIP_FROM_PATH = @PROJECT_SOURCE_DIR@ # The STRIP_FROM_INC_PATH tag can be used to strip a user-defined part of the # path mentioned in the documentation of a class, which tells the reader which