[OE-core] [PATCH 2/2] Add api-doc class

Burton, Ross ross.burton at intel.com
Fri May 16 09:39:17 UTC 2014


As this class is specific to doxygen, please call it doxygen.bbclass.

Also I think this should be opt-in not forcibly enabled as not
everyone would want API documentation to be generated.

Pretty sure you'll want to run doxygen after do_compile in case the
documentation is generated from files built at compile time.  But
don't most packages that use doxygen invoke it themselves?  You're
also not actually installing the documentation anywhere.

Ross

On 16 May 2014 08:45,  <b40527 at freescale.com> wrote:
> From: Zongchun Yu <Zongchun.Yu at freescale.com>
>
> this class use doxygen to generate api docs from source code
>
> Signed-off-by: Zongchun Yu <Zongchun.Yu at freescale.com>
> ---
>  meta/classes/api-doc.bbclass |   16 ++++++++++++++++
>  1 files changed, 16 insertions(+), 0 deletions(-)
>  create mode 100644 meta/classes/api-doc.bbclass
>
> diff --git a/meta/classes/api-doc.bbclass b/meta/classes/api-doc.bbclass
> new file mode 100644
> index 0000000..0879c3e
> --- /dev/null
> +++ b/meta/classes/api-doc.bbclass
> @@ -0,0 +1,16 @@
> +# Helper class to pull in the right dependencies and generate
> +# api documentation from sources code
> +
> +DEPENDS += "doxygen-native"
> +
> +# Doxygen configuration file
> +DOXYGEN_CFG ?= "Doxyfile"
> +
> +do_generate_doc () {
> +    if [ -e ${S}/${DOXYGEN_CFG} ]; then
> +        doxygen ${S}/${DOXYGEN_CFG}
> +    else
> +        bbfatal "no doxygen configuration file found"
> +    fi
> +}
> +addtask generate_doc before do_install after do_patch
> --
> 1.7.0.4
>
> --
> _______________________________________________
> Openembedded-core mailing list
> Openembedded-core at lists.openembedded.org
> http://lists.openembedded.org/mailman/listinfo/openembedded-core



More information about the Openembedded-core mailing list