Skip to content

fix(cmake): make EXTRA_ARGS a multi-value argument - #65

Open
henryiii wants to merge 1 commit into
masterfrom
fix-cmake-extra-args
Open

fix(cmake): make EXTRA_ARGS a multi-value argument#65
henryiii wants to merge 1 commit into
masterfrom
fix-cmake-extra-args

Conversation

@henryiii

@henryiii henryiii commented Aug 6, 2026

Copy link
Copy Markdown
Collaborator

🤖 AI text below 🤖

Addresses finding 8 and the version duplication from #59.

EXTRA_ARGS in the pybind11_mkdoc CMake function was a one-value keyword, so only the first token reached the command and the rest was silently dropped. It is now a multi-value argument, and each element is passed as its own argv entry.

cmake/CMakeLists.txt no longer hardcodes the version. It reads __version__ from pybind11_mkdoc/__init__.py and keeps the numeric components only, because project(VERSION) does not accept a dev suffix.

The CMake test now passes two extra defines and the sample header has a second guarded method, so both arguments must take effect for the test to pass. The installed copy of the functions file under pybind11_mkdoc/share/ was regenerated.

EXTRA_ARGS was a one-value keyword, so only the first token was kept and
the rest was silently dropped. Also read the package version from
pybind11_mkdoc/__init__.py instead of hardcoding it in cmake/CMakeLists.txt.

Assisted-by: ClaudeCode:claude-fable-5
@henryiii
henryiii marked this pull request as draft August 6, 2026 18:18
@henryiii
henryiii marked this pull request as ready for review August 6, 2026 20:12
@henryiii henryiii closed this Aug 7, 2026
@henryiii henryiii reopened this Aug 7, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant