Eddie
Eddie

Reputation: 145

Merging doxygen modules

I have a large amount of code that I'm running doxygen against. To improve performance I'm trying to break it into modules and merge the result into one set of docs. I thought tag files would do the trick, but either I have it configured wrong or I'm misunderstanding how it works.

The directories are laid out:

root +
     |-src+
     |    |-a
     |
     |-doc+
          |-a.dox
          |-main.dox
          |-main.md
          |-output+
                  |-a+
                  |  |-html
                  |-main+
                        |-html

In addition to 'a' there are other peer directories but am starting with one.

a.dox generates output and a tag file into root/doc/output

OUTPUT_DIRECTORY=output/a
GENERATE_TAGFILE = output/a/a.tag
INPUT=../src/a

main.dox just inputs the markdown file that has a mainpage tag and refers to the other projects tag file.

OUTPUT_DIRECTORY=output/main
INPUT = main.md
TAGFILES=output/a/a.tag=output/a/html
  1. Should this merge or link all the docs under main where I can browse 'a' globals, modules, pages, etc? Or does this only generate links to 'a' if I explicitly cross-reference a documented entity in 'a' from inside of 'main'?
  2. If this should work, any thoughts on where my syntax is incorrect? I've tried various ways to define TAGFILES, is the output directory relative to the main.dox file? To the a.tag file? Or to the a/html directory?
  3. If I'm off base an TAGFILES don't work this way, is there another way to merge sets of doxygen directories into one?

Thanks.

Upvotes: 5

Views: 7822

Answers (1)

doxygen
doxygen

Reputation: 14869

I suggest you read this topic on how I recommend to use tag files and the conditions that should apply: https://stackoverflow.com/a/8247993/784672

To answer your first question: doxygen will in general not merge the various index files together (then no performance would be gained). Although for a part you can still get external members in the index by setting ALLEXTERNALS to YES.

Doxygen will (auto)link symbols from other sources imported via a tag file. So in general you should divide your code into more or less self-contained modules/components/libraries, and if one such module depends on another, then import its tag file so that doxygen can link to the other documentation set. If you run doxygen twice (once for the tag file and once for the documentation) you can also resolve cyclic dependencies if you have them.

In my case I made a custom index page with links to all modules, and made a custom entry in the menu of each generated page that linked back to this index (see http://www.doxygen.nl/manual/customize.html#layout) how to add a user defined entry to the navigation menu/tree.

Upvotes: 9

Related Questions