Doc: Added nested index structure
This patch adjusts the structure of documentation, making it
easier to organise and navigate.
* Modifies index.rst.in decoupled from cmake index.rst.
* Creates respective indexes in the documentation sub-directories
and links them to the master index
* External component documentation is preserved
* CMAKE build system is updated to automate the document listing
in the design_documents index instead of the master index.
Change-Id: I697b68e19dc57ecf7f36bc6dd8248fe345bdad61
Signed-off-by: Galanakis, Minos <minos.galanakis@arm.com>
diff --git a/cmake/SphinxDesignDocStatus.cmake b/cmake/SphinxDesignDocStatus.cmake
index e76c448..88438d3 100644
--- a/cmake/SphinxDesignDocStatus.cmake
+++ b/cmake/SphinxDesignDocStatus.cmake
@@ -20,7 +20,7 @@
Include(CMakeParseArguments)
#This function will search for .rst files in a given directory, read them and
-#check if the :Status: field is defined in them. Then will add each file to a
+#check if the ":Status:" field is defined in them. Then will add each file to a
#list with a name matching the status value.
#See the definition of _STATE_VALUES below for a list of valid state values.
#Files with missing or invalid state value will be placed on the "unknown" list.
@@ -174,15 +174,16 @@
#Loop over files on the list of this status
foreach(_FILE IN LISTS _DD_${_STATUS})
- #Get the path of the file relative to the document root
- file(RELATIVE_PATH _REL_FILE ${_MY_PARAMS_DOC_ROOT} ${_FILE})
+
+ # Strip path from the filesince index is placed in same location
+ get_filename_component(_FILE ${_FILE} NAME)
#Detailed and Draft files go to the same section
if (_STATUS STREQUAL "DETAILED")
set(_STATUS "DRAFT")
endif()
#Append the file to the output string
- string(APPEND ${_STATUS}_DD_LIST "\n ${_REL_FILE}")
+ string(APPEND ${_STATUS}_DD_LIST "\n ${_FILE}")
endforeach()
endforeach()