diff options
-rw-r--r-- | eclass/trinity-meta-2.eclass | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/eclass/trinity-meta-2.eclass b/eclass/trinity-meta-2.eclass index 4977f511..5f9109b8 100644 --- a/eclass/trinity-meta-2.eclass +++ b/eclass/trinity-meta-2.eclass @@ -14,6 +14,16 @@ inherit trinity-base-2 LICENSE="|| ( GPL-2 GPL-3 )" HOMEPAGE="http://www.trinitydesktop.org/" +# +# The TRINITY_HANDBOOK variable is described in trinity-base-2.eclass +# This ECLASS does not use the yes value of this variable. +# Required dependency to view the documentation. +# +if [[ "${TRINITY_HANDBOOK}" == "optional" ]] ; then + IUSE+=" +handbook" + RDEPEND+=" handbook? ( ~trinity-base/khelpcenter-${PV} )" +fi + # @FUNCTION: trinity-meta-2_set_trinity_submodule # @DESCRIPTION: # Sets the TRINITY_SUBMODULE variable to @@ -155,6 +165,9 @@ trinity-meta-2_create_extractlists() { *) ;; # nothing special for other modules esac + #Adding documentation + [[ "${TRINITY_HANDBOOK}" == "optional" ]] && TSM_EXTRACT_LIST+=" doc" + TSM_EXTRACT_LIST+=" ${TSM_EXTRACT} ${TSM_EXTRACT_ALSO} cmake/ CMakeLists.txt" TSM_EXTRACT_LIST+=" config.h.cmake ConfigureChecks.cmake" [[ ${TRINITY_BUILD_ADMIN} == "yes" ]] && TSM_EXTRACT_LIST+=" admin configure.in.in Makefile.am.in \ @@ -207,6 +220,10 @@ trinity-meta-2_src_configure() { tsmargs+=" -DBUILD_${mod}=ON" done + if [[ "${TRINITY_HANDBOOK}" == "optional" ]] ; then + mycmakeargs+=( "-DBUILD_DOC=$(usex handbook ON OFF)" ) + fi + mycmakeargs=( "${mycmakeargs[@]}" ${tsmargs} |