Skip to content

Fix passing multiple XML doc sources to generate_doc_source - #1918

Merged
dsnopek merged 2 commits into
godotengine:masterfrom
foxandfeature:multiple-XML-doc-sources
Mar 3, 2026
Merged

dsnopek merged 2 commits into
godotengine:masterfrom
foxandfeature:multiple-XML-doc-sources

Conversation

@foxandfeature

Copy link
Copy Markdown
Contributor

CMake functions only received the first XML file due to argument expansion.
Quoting the SOURCES argument ensures multiple XML doc sources are passed correctly.

@foxandfeature
foxandfeature requested a review from a team as a code owner January 31, 2026 18:08
@Ivorforce
Ivorforce requested a review from enetheru January 31, 2026 18:09
@Ivorforce Ivorforce added bug This has been identified as a bug cmake labels Jan 31, 2026

@enetheru enetheru left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

My apologies for taking so long to review this simple change, you are quite right.
There is another location that also needs changing and that's in the test cmake file where is uses this function also:
test/CMakeLists.txt

# conditionally add doc data to compile output
if(GODOTCPP_TARGET MATCHES "editor|template_debug")
    file(GLOB_RECURSE DOC_XML LIST_DIRECTORIES NO CONFIGURE_DEPENDS "${CMAKE_CURRENT_SOURCE_DIR}/doc_classes/*.xml")
    target_doc_sources( ${TARGET_NAME} ${DOC_XML} ) # FIXME is missing quotes too.
endif()

I would really appreciate amending this PR to include this fix.

@dsnopek dsnopek left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

Makes sense and Enetheru approves, so this sound good to me :-) I'll merge after the tests finish running

@dsnopek
dsnopek merged commit 55a86ba into godotengine:master Mar 3, 2026
19 of 20 checks passed
dsnopek added a commit that referenced this pull request Aug 25, 2026
Backport #1918: Fix multi-file dependency in generate_doc_source for 4.5 branch.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug This has been identified as a bug cmake

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants