aboutsummaryrefslogtreecommitdiffstats
path: root/lib/doc
diff options
context:
space:
mode:
authorLuca Muscariello <lumuscar+fdio@cisco.com>2019-01-17 13:47:57 +0100
committerLuca Muscariello <lumuscar+fdio@cisco.com>2019-01-17 16:32:51 +0100
commitbac3da61644515f05663789b122554dc77549286 (patch)
tree898210bc8e70371d77de7d446a26c5dd4fd1165a /lib/doc
parentd5165246787301d0f13b646fda5e8a8567aef5ac (diff)
This is the first commit of the hicn projectv19.01
Change-Id: I6f2544ad9b9f8891c88cc4bcce3cf19bd3cc863f Signed-off-by: Luca Muscariello <lumuscar+fdio@cisco.com>
Diffstat (limited to 'lib/doc')
-rwxr-xr-xlib/doc/CMakeLists.txt23
-rwxr-xr-xlib/doc/Doxyfile.in12
2 files changed, 35 insertions, 0 deletions
diff --git a/lib/doc/CMakeLists.txt b/lib/doc/CMakeLists.txt
new file mode 100755
index 000000000..cf022dc52
--- /dev/null
+++ b/lib/doc/CMakeLists.txt
@@ -0,0 +1,23 @@
+# add a target to generate API documentation with Doxygen
+find_package(Doxygen)
+option(BUILD_DOCUMENTATION "Create and install the HTML based API documentation (requires Doxygen)" ${DOXYGEN_FOUND})
+
+if(BUILD_DOCUMENTATION)
+ if(NOT DOXYGEN_FOUND)
+ message(FATAL_ERROR "Doxygen is needed to build the documentation.")
+ endif()
+
+ set(doxyfile_in ${CMAKE_CURRENT_SOURCE_DIR}/Doxyfile.in)
+ set(doxyfile ${CMAKE_CURRENT_BINARY_DIR}/Doxyfile)
+
+ configure_file(${doxyfile_in} ${doxyfile} @ONLY)
+
+ add_custom_target(doc
+ COMMAND ${DOXYGEN_EXECUTABLE} ${doxyfile}
+ WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}
+ COMMENT "Generating API documentation with Doxygen"
+ VERBATIM)
+
+# FIXME MS : wrong install path
+ install(DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/html DESTINATION share/doc)
+endif()
diff --git a/lib/doc/Doxyfile.in b/lib/doc/Doxyfile.in
new file mode 100755
index 000000000..839de9f8a
--- /dev/null
+++ b/lib/doc/Doxyfile.in
@@ -0,0 +1,12 @@
+PROJECT_NAME = "Hybrid ICN (hICN)"
+PROJECT_NUMBER = v@CMAKE_VERSION_MAJOR@.@CMAKE_VERSION_MINOR@.@CMAKE_VERSION_PATCH@
+STRIP_FROM_PATH = @PROJECT_SOURCE_DIR@ \
+ @PROJECT_BINARY_DIR@
+INPUT = @doxy_main_page@ \
+ @PROJECT_SOURCE_DIR@ \
+ @PROJECT_BINARY_DIR@
+FILE_PATTERNS = *.md \
+ *.h \
+ *.cc
+RECURSIVE = YES
+USE_MDFILE_AS_MAINPAGE = ../README.md