1. Kay-Uwe (Kiwi) Lorenz
  2. sphinxcontrib-cmakedomain

Overview

HTTPS SSH

GNU Make Domain

This Sphinx extension provides a `CMake`_ domain.

Installation

pip install sphinxcontrib-cmakedomain

Enable Extension

Add sphinxcontrib.cmakedomain in extensions of conf.py:

extensions = [ 'sphinxcontrib.cmakedomain' ]

Usage

Get ready for make:

.. highlight:: cmake

.. default-domain:: make

Describe a macro:

.. macro:: foo(SOME <var> ANOTHER <var2>)

   :param SOME <var>:
       here description

   :param ANOTHER <var2>:
       here more descripiton

   describe here whatever :macro:`foo` does

Describe a variable:

.. var:: MY_VAR

   Describe here whatever :var:`MY_VAR` does.

License

New BSD License.