Use Doxygen in Ubuntu 12.04 to generate API documentation

Source: Internet
Author: User
Tags doxygen gz file

Some time ago, the company implemented project requirements to comply with the doxygen documentation specification, and installed Doxygen 1.8.4 in Windows XP. When using the documentation, we can check whether the header file complies with the doxygen specification and some simple errors, you can also generate corresponding API documents based on C or C ++ source code, especially html format.

For example, you can use the doxygen tool to generate the corresponding API documentation for the source code of the downloaded open-source software.

Doxygen also has the linux open source version, as follows: http://sourceforge.net/projects/doxygen/

Doxygen Web site: http://www.stack.nl /~ Dimitri/doxygen/index.html

Http://www.doxygen.org/

Introduction to doxygen:

Doxygen is an open-source cross-platform documentation system similar to JavaDoc. It fully supports C, C ++, Java, Objective-C, and IDL languages, some support PHP and C #. The annotation syntax is compatible with Qt-Doc, KDoc, and JavaDoc. Doxgen can generate HTML-format online browsers or offline LATEX and RTF reference manuals from a set of archive source files.

1. Run the apt-get install command in Ubuntu12.04 to install the doxygen command line tool and the corresponding GUI tool. The command is as follows:

Sudo apt-get install doxygen

Sudo apt-get install doxygen-gui

After installation, there are three command tools for doxygen in the/usr/bin directory:

Doxygen (command line tool)

Doxytag

Doxywizard (GUI wizard tool)

2. Use doxygen in Ubuntu12.04 to generate the API documentation for the downloaded source code.

1. Download the source code D-Bus-1.6.10 from the blfs website.

2. Press Ctrl + Alt + T to open the terminal and enter doxywizard. The following doxygen GUI is displayed, which is similar to doxygen used in Windows XP.

2. decompress the downloaded dbus-1.6.10.tar.gz file.

Run the following command to decompress the directory where dbus-1.6.10.tar.gz is downloaded:

Tar-xzvf dbus-1.6.10.tar.gz

Right-click dbus-1.6.10.tar.gz and select Extract here.

3. Configure the routing project options, such as the doxygen script configuration file storage path, doxygen API file storage path, project name, version number, and other information.

Create the tmp directory under the working directory, for example,/home/ccf/Downloads, store the doxygen script configuration file, and create the export-html-docs directory to store the output producer API documentation, in addition, the decompressed dbus-1.6.10 source code is also moved to this directory, in step 1 pop-up doxygen gui interface for the following Configuration:

From the configuration above, we can see that:

The path for storing the doxygen API configuration script is/home/ccf/Downloads/tmp.

Project name: Workshop

Version: 1.6.10

Source code Directory:/home/ccf/Downloads/dbus-1.6.10

Doxygen API documentation output path:/home/ccf/Downloads/Alibaba-html-docs

In addition, note that the Scan recursively option must be selected. Otherwise, the corresponding doxygen API document cannot be generated.

  • 1
  • 2
  • Next Page

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.