HDFS-8745. Use Doxygen to generate documents for libhdfspp. Contributed by Haohui Mai.
Project: http://git-wip-us.apache.org/repos/asf/hadoop/repo Commit: http://git-wip-us.apache.org/repos/asf/hadoop/commit/ac60c6ab Tree: http://git-wip-us.apache.org/repos/asf/hadoop/tree/ac60c6ab Diff: http://git-wip-us.apache.org/repos/asf/hadoop/diff/ac60c6ab Branch: refs/heads/HDFS-8707 Commit: ac60c6ab4afb900c0c808b996669552961ee6fb8 Parents: 5b9ff2e Author: Haohui Mai <[email protected]> Authored: Thu Jul 9 13:47:20 2015 -0700 Committer: Haohui Mai <[email protected]> Committed: Fri Jul 10 17:09:01 2015 -0700 ---------------------------------------------------------------------- BUILDING.txt | 1 + .../src/main/native/libhdfspp/CMakeLists.txt | 8 ++++++++ .../src/main/native/libhdfspp/doc/Doxyfile.in | 16 ++++++++++++++++ .../src/main/native/libhdfspp/doc/mainpage.dox | 8 ++++++++ 4 files changed, 33 insertions(+) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/hadoop/blob/ac60c6ab/BUILDING.txt ---------------------------------------------------------------------- diff --git a/BUILDING.txt b/BUILDING.txt index 2aeade4..dc7efd5 100644 --- a/BUILDING.txt +++ b/BUILDING.txt @@ -12,6 +12,7 @@ Requirements: * Zlib devel (if compiling native code) * openssl devel ( if compiling native hadoop-pipes and to get the best HDFS encryption performance ) * Jansson C XML parsing library ( if compiling libwebhdfs ) +* Doxygen ( if compiling libhdfspp and generating the documents ) * Linux FUSE (Filesystem in Userspace) version 2.6 or above ( if compiling fuse_dfs ) * Internet connection for first build (to fetch all Maven and Hadoop dependencies) http://git-wip-us.apache.org/repos/asf/hadoop/blob/ac60c6ab/hadoop-hdfs-project/hadoop-hdfs-client/src/main/native/libhdfspp/CMakeLists.txt ---------------------------------------------------------------------- diff --git a/hadoop-hdfs-project/hadoop-hdfs-client/src/main/native/libhdfspp/CMakeLists.txt b/hadoop-hdfs-project/hadoop-hdfs-client/src/main/native/libhdfspp/CMakeLists.txt index f4bc8b8..cae786c 100644 --- a/hadoop-hdfs-project/hadoop-hdfs-client/src/main/native/libhdfspp/CMakeLists.txt +++ b/hadoop-hdfs-project/hadoop-hdfs-client/src/main/native/libhdfspp/CMakeLists.txt @@ -18,6 +18,7 @@ project (libhdfspp) +find_package(Doxygen) find_package(Protobuf REQUIRED) find_package(Threads) @@ -33,6 +34,13 @@ if(APPLE) set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -stdlib=libc++ -Wno-deprecated-declarations") endif() +if(DOXYGEN_FOUND) +configure_file(${CMAKE_CURRENT_SOURCE_DIR}/doc/Doxyfile.in ${CMAKE_CURRENT_BINARY_DIR}/doc/Doxyfile @ONLY) +add_custom_target(doc ${DOXYGEN_EXECUTABLE} ${CMAKE_CURRENT_BINARY_DIR}/doc/Doxyfile + WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} + COMMENT "Generating API documentation with Doxygen" VERBATIM) +endif(DOXYGEN_FOUND) + include_directories( include lib http://git-wip-us.apache.org/repos/asf/hadoop/blob/ac60c6ab/hadoop-hdfs-project/hadoop-hdfs-client/src/main/native/libhdfspp/doc/Doxyfile.in ---------------------------------------------------------------------- diff --git a/hadoop-hdfs-project/hadoop-hdfs-client/src/main/native/libhdfspp/doc/Doxyfile.in b/hadoop-hdfs-project/hadoop-hdfs-client/src/main/native/libhdfspp/doc/Doxyfile.in new file mode 100644 index 0000000..773990f --- /dev/null +++ b/hadoop-hdfs-project/hadoop-hdfs-client/src/main/native/libhdfspp/doc/Doxyfile.in @@ -0,0 +1,16 @@ +DOXYFILE_ENCODING = UTF-8 +PROJECT_NAME = "libhdfspp" +OUTPUT_DIRECTORY = doc +TAB_SIZE = 2 +MARKDOWN_SUPPORT = YES +BUILTIN_STL_SUPPORT = YES + + +INPUT = @PROJECT_SOURCE_DIR@/doc/mainpage.dox \ + @PROJECT_SOURCE_DIR@/include/libhdfspp \ + +INPUT_ENCODING = UTF-8 +RECURSIVE = NO + +GENERATE_HTML = YES +GENERATE_LATEX = NO http://git-wip-us.apache.org/repos/asf/hadoop/blob/ac60c6ab/hadoop-hdfs-project/hadoop-hdfs-client/src/main/native/libhdfspp/doc/mainpage.dox ---------------------------------------------------------------------- diff --git a/hadoop-hdfs-project/hadoop-hdfs-client/src/main/native/libhdfspp/doc/mainpage.dox b/hadoop-hdfs-project/hadoop-hdfs-client/src/main/native/libhdfspp/doc/mainpage.dox new file mode 100644 index 0000000..ef4ba26 --- /dev/null +++ b/hadoop-hdfs-project/hadoop-hdfs-client/src/main/native/libhdfspp/doc/mainpage.dox @@ -0,0 +1,8 @@ +/** +\mainpage libhdfs++ + +libhdfs++ is a modern implementation of HDFS client in C++11. It is +optimized for the Massive Parallel Processing (MPP) applications that +access thousands of files concurrently in HDFS. + +*/
