Files
pybind11/tools
Henry Schreiner 692b031ac5 fix(cmake): keep CMP0190 auto-default in add_subdirectory builds
The previous commit's `NOT DEFINED PYBIND11_USE_CROSSCOMPILING` guard
broke the intended auto-default for top-level / add_subdirectory builds:
CMakeLists.txt runs `option(PYBIND11_USE_CROSSCOMPILING ... OFF)` before
including pybind11Common.cmake, so the variable is already defined (OFF)
and the CMP0190 default never applied.

Capture, before the option() call, whether the project set the value
itself, and let pybind11Common.cmake apply its default unless the value
was set explicitly. This keeps both the emulator override fix and the
CMP0190 auto-default for subdirectory consumers.

Assisted-by: ClaudeCode:claude-opus-4.8
2026-06-24 00:55:38 -04:00
..
2025-08-22 15:57:09 -04:00