From 8262a4203b4a76b76d451f1720ed91224ed17840 Mon Sep 17 00:00:00 2001 From: Noel Eck Date: Tue, 28 Mar 2017 11:35:11 -0700 Subject: [PATCH] doxygen: Use relative paths in generated docs Updated cmake to use strip the full path to the base UPM directory from generated documentation. This removes the build server full- path from UPM documentation. Old html: upm: /iotdk/jenkins/workspace/upm-doc-stable/src/moisture/moisture.h File Reference New html: upm: src/moisture/moisture.h File Reference Signed-off-by: Noel Eck --- CMakeLists.txt | 3 +++ doxy/Doxyfile.in | 2 +- 2 files changed, 4 insertions(+), 1 deletion(-) 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