13

I need to generate documentation for a C++ project of mine (and soon perhaps also for additional ones). So far I've looked into doxygen, and even though it seems popular, I've had some issues with it (the details of which I won't go into here; some have been resolved). Since I'm not particularly attached to it - despite its apparent popularity - I want to consider some alternatives.

Now, 7 years ago there was a question on StackOverflow on exactly that:

Doxygen Alternatives for C++

but the answers are by now dated, so I'm reasking the same question, here and now.

Requirements:

  • Libre
  • Gratis
  • Multiplatform, supporting at least Linux and Windows
  • Flexible to a similar level as doxygen or more
  • Actively maintained
  • Non-negligible user base
13
  • 2
    If you "won't go into the details here", then it's going to be difficult to help you
    – Mawg
    Commented Mar 30, 2017 at 10:25
  • @Mawg: It was mostly this, but that won't help you much I think...
    – einpoklum
    Commented Mar 30, 2017 at 12:44
  • But that got solved. So why not use DoxyGen? Just curious
    – Mawg
    Commented Mar 30, 2017 at 12:57
  • @Mawg: The fact that it behaved that way gave me a hunch I might want something else. Also, why should I use doxygen, other than I've heard of it? It's not like a I have positive experience with it.
    – einpoklum
    Commented Mar 30, 2017 at 13:06
  • 2
    what is with all the useless comments about telling him to use doxygen when he said he wanted alternatives? +1 for one more useless comment. Thanks for asking the question and wtf did they delete the other question for
    – Tim
    Commented Apr 15, 2018 at 1:56

3 Answers 3

7

Personally I would strongly recommend taking a look at Sphinx-Doc which was written for the Python documentation but is applicable to other systems as well.

  • Produces great looking documents with multiple themes in multiple formats
  • Can generate from multiple programming language, e.g. C++ with the C++ domain
  • Can be integrated with build systems including make, Jenkins, etc.

Addressing your points:

  • Libre Fully Open Source
  • Gratis Yes
  • Multiplatform, supporting at least Linux and Windows Yes Python based so runs just about anywhere Multi-platform Installation Instructions
  • Flexible to a similar level as doxygen or more Yes Personally I find it more flexible as it allows a mixture of auto-generated and pre-written, in ReStructuredText, documentation.
  • Actively maintained Yes At the time of writing rev 1.5.3 was released 2017-02-26 just over a month ago
  • Non-negligible user base Yes - Read The Docs supports it to start with & lots of examples here

Note that for Automatically generating nice looking documentation from C/C++ source code you can combine Sphinx for the document generation with doxyGen for information extraction to XML and breathe acting as a bridge between them.

3
  • 1
    Sphinx does not support autogenerated docs for C or C++. That is, you need to maintain your entire API and documentation in ReST files parallel to your code. Big risk for typos, things to get out of sync, etc.
    – detly
    Commented Dec 13, 2017 at 6:50
  • @detly Added information on the breathe extension that allows auto-generation via doxygen from the code. Commented Dec 13, 2017 at 10:20
  • 1
    Thanks for that, I'd seen breathe mentioned elsewhere but misunderstood what role it played here. After doing a bit more research it seems there's also some LLVM Clang based autogen plugins for Sphinx that are in development but might eventually fill that gap too.
    – detly
    Commented Dec 13, 2017 at 21:47
4

(I've salvaged several answers from the now-deleted StackOverflow question page:)

Doc++

You could try DOC++ but it may be even uglier.

cldoc

There is an open source alternative to doxygen out there called cldoc.

It can handle both C and C++ and is based on clang. The most interesting features it claims to offer:

  • Uses clang to robustly parse even the most complex C++ projects without additional effort from the user.
  • Uses markdown for documentation formatting.
  • Uses a simple format for documenting your code.
  • Supports cross-referencing in documentation.
  • Generates a single file, javascript based web application to render the documentation.
  • Lightning fast client-side searching using a pregenerated search index.

NaturalDocs

NaturalDocs has its warts, but the output is decent and the markup is effortless.

NetBeans

If you're interested in tracing big project, then I would suggest c++ version of Netbeans which can dynamically generate nice call graphs ( look for 'Show Call Graph' feature ).

Doxypress

DoxyPress is a modern replacement for Doxygen.

-1

It may not meet your requirements but standardese seems worth mentioning.

As of 2022, only Doxypress and standardese seem to be alternatives to Doxygen improved for C++. Doxpress is a fork of Doxygen at version 1.8.8 which aims to support other languages as well.

See GitHub pages for latest activities:
standardese
Doxypress

I haven't tried any of them, so any feedback is warmly welcome.

4
  • Please write a little more about it - how it differs from, or is similar to, doxygen.
    – einpoklum
    Commented Jul 19, 2022 at 17:16
  • Your answer could be improved with additional supporting information. Please edit to add further details, such as citations or documentation, so that others can confirm that your answer is correct. You can find more information on how to write good answers in the help center.
    – Community Bot
    Commented Jul 19, 2022 at 19:24
  • Welcome to Software Recommendations! If it does not meet the requirements, how is it an answer then? And why is it worth mentioning if it doesn't fit?
    – Izzy
    Commented Jul 19, 2022 at 21:30
  • It is worth mentioning because as of 2022, only Doxypress and standardese seem to be alternatives to Doxygen improved for C++, where the latter is not mentioned at all. Feel free to improve the post, or create a new answer based on your experience.
    – Burak
    Commented Jul 20, 2022 at 12:53

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.