Skip to content

Commit

Permalink
Automated Doxygen Generation EOSIO#196
Browse files Browse the repository at this point in the history
Doxygen documentation now automatically generated if Doxygen is present.
Default destination is the build directory docs/html folder. Destination
may be customized with -DDOXY_DOC_DEST_DIR=/destination/path or editing
the entry in ccmake/cmake-gui.
  • Loading branch information
jgiszczak committed Sep 25, 2017
1 parent 4350a4d commit dae9678
Show file tree
Hide file tree
Showing 634 changed files with 37 additions and 57,738 deletions.
38 changes: 33 additions & 5 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,10 @@ INCLUDE( SetupTargetMacros )
set( BLOCKCHAIN_NAME "Eos" )
set( CMAKE_CXX_STANDARD 14 )

set(VERSION_MAJOR 1)
set(VERSION_MINOR 1)
set(VERSION_PATCH 0)

set( CLI_CLIENT_EXECUTABLE_NAME eos_client )
set( GUI_CLIENT_EXECUTABLE_NAME eos )
set( CUSTOM_URL_SCHEME "gcs" )
Expand Down Expand Up @@ -179,11 +183,6 @@ add_subdirectory( tools )

if (ENABLE_INSTALLER)

set(VERSION_MAJOR 0)
set(VERSION_MINOR 1)
set(VERSION_PATCH 0)


include(InstallRequiredSystemLibraries)

set(CPACK_OUTPUT_FILE_PREFIX ${CMAKE_BINARY_DIR}/packages)
Expand Down Expand Up @@ -227,3 +226,32 @@ endif(LINUX)
endif(ENABLE_INSTALLER)

configure_file(${CMAKE_CURRENT_SOURCE_DIR}/genesis.json ${CMAKE_CURRENT_BINARY_DIR}/genesis.json COPYONLY)

include(FindDoxygen)

if(NOT DOXYGEN_FOUND)
message(STATUS "Doxygen not found. Contract documentation will not be generated.")
else()
message(STATUS "Doxygen found. Contract documentation will be generated.")
set(DOXY_EOS_VERSION "${VERSION_MAJOR}.${VERSION_MINOR}.${VERSION_PATCH}" CACHE INTERNAL "Version string used in PROJECT_NUMBER.")
# CMake strips trailing path separators off of variables it knows are paths,
# so the trailing '/' Doxygen expects is embedded in the doxyfile.
set(DOXY_DOC_DEST_DIR "${CMAKE_BINARY_DIR}/docs/html" CACHE PATH "Path to the doxygen output")
set(DOXY_DOC_INPUT_ROOT_DIR "contracts" CACHE PATH "Path to the doxygen input")
if(DOXYGEN_DOT_FOUND)
set(DOXY_HAVE_DOT "YES" CACHE STRING "Doxygen to use dot for diagrams.")
else(DOXYGEN_DOT_FOUND)
set(DOXY_HAVE_DOT "NO" CACHE STRING "Doxygen to use dot for diagrams.")
endif(DOXYGEN_DOT_FOUND)
configure_file("eos.doxygen.in" "${CMAKE_BINARY_DIR}/eos.doxygen")
# !! Core developers who don't want to see the doxygen output on every build
# !! should remove the 'ALL' option from both commands below.
# Doxygen has issues making destination directories more than one level deep, so do it for it.
add_custom_target(make_doc_dir ALL COMMAND ${CMAKE_COMMAND} -E make_directory "${DOXY_DOC_DEST_DIR}")
add_custom_target(contract_documentation ALL
COMMAND "${DOXYGEN_EXECUTABLE}" "${CMAKE_BINARY_DIR}/eos.doxygen"
DEPENDS make_doc_dir
WORKING_DIRECTORY "${CMAKE_SOURCE_DIR}"
COMMENT "Building doxygen documentation into ${DOXY_DOC_DEST_DIR}..."
VERBATIM)
endif()
Binary file removed docs/EOS internal block architecture 1.jpg
Binary file not shown.
4 changes: 0 additions & 4 deletions docs/EOS internal block architecture 1.svg

This file was deleted.

75 changes: 0 additions & 75 deletions docs/_r_e_a_d_m_e_8md.html

This file was deleted.

Loading

0 comments on commit dae9678

Please sign in to comment.