Skip to content

Functions are not found in groups with doxygen 1.9.8 #1052

@danlkv

Description

@danlkv

Summary

.. doxygenfunction:: myFunction fails when Doxygen lists the function under a file compound in index.xml but the function’s refid points to a group__... compound.

Versions:

  • Doxygen 1.9.8
  • Sphinx 8.2.3
  • Breathe 4.36.0
  • Ubuntu 24.04

This uses Doxygen’s “grouping markers” (@{ / @}) as described in the Doxygen manual.

Reproducer

include/mylib.h:

/** \defgroup myapi My API */
/** @{ */
/** \brief A function in a group. */
int myFunction(int* handle);
/** @} */

Doxyfile:

PROJECT_NAME           = "breathe-doxygen-refid-group-repro"
INPUT                  = include/mylib.h
GENERATE_HTML          = NO
GENERATE_LATEX         = NO
GENERATE_XML           = YES
XML_OUTPUT             = xml

sphinx/conf.py:

extensions = ["breathe"]
breathe_projects = {"repro": "../xml"}
breathe_default_project = "repro"

sphinx/index.rst:

.. doxygenfunction:: myFunction

Commands

python3 -m pip install --user -U virtualenv
python3 -m virtualenv .venv
. .venv/bin/activate
python -m pip install -U pip
python -m pip install "sphinx==8.2.3" "breathe==4.36.0"

rm -rf xml
doxygen --version
doxygen Doxyfile

sphinx-build -b html -E -a -W --keep-going sphinx _build/html

What Doxygen produces (key snippet)

xml/index.xml:

<compound refid="mylib_8h" kind="file"><name>mylib.h</name>
  <member refid="group__myapi_1gab05f9132a5a9cbdc9a13d810c384464d" kind="function"><name>myFunction</name></member>
</compound>

Failure

sphinx/index.rst:1: WARNING: doxygenfunction: Cannot find function "myFunction" in doxygen xml output for project "repro" from directory: ../xml [docutils]

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions