DoxygenAddDocumentation¶
Note
DoxygenAddDocumentation
is transitively included by
ExtendedDoxygen
.
Typically, there is little need to include the present module by hand.
Note
Since this module is heavily based on code distributed by Kitware, please
find the original code’s license text in the
sourcecode
.
Commands¶
- doxygen_add_documentation¶
doxygen_add_docs( targetName [filesOrDirs...] [ALL] [USE_STAMP_FILE] [WORKING_DIRECTORY dir] [COMMENT comment] [DEDICATED_SOURCES files...] )
Set up a target to drive generation of
doxygen
-based documentation.Note
doxygen_add_documentation()
is intended as drop-in-replacement for doxygen_add_docs (at least as far as possible). For general advice on how to usedoxygen_add_documentation()
, please consult doxygen_add_docs’ documentation.doxygen_add_documentation()
differs fromdoxygen_add_docs
in the following ways:The
Doxyfile
configuration file is created at generation time (in contrast to at configure time) to allow for substitution of generator expressions. This is needed to allow for generator expressions in source file paths as well as include directories.Sources specified as positional arguments do not get passed as SOURCES argument to the constructed custom target. Sources specified as positional arguments are considered to be part of some other target, hence they do not get passed on. To explicitly pass sources to the constructed custom target, consider using the additional keyword argument
DEDICATED_SOURCES
.An additional keyword argument
DEDICATED_SOURCES
is supported. See below for details.
DEDICATED_SOURCES files...
list of sources dedicated at the constructed custom target itself
Sources passed by means of
DEDICATED_SOURCES
(in contrast to being passed as positional arguments) get passed on to the constructed custom target as SOURCES. A common use-case is to specify someREADME.md
, which does not contribute to the general code base but gets passed todoxygen
via itsDOXYGEN_USE_MDFILE_AS_MAINPAGE
option. Passing such files viaDEDICATED_SOURCES
makes them show up in IDEs.Note
Do not use
DEDICATED_SOURCES
to pass source files (e.g.C/C++
files) which are part of another target. Such files should be passed as positional arguments infilesOrDirs...
.