Skip to content

Revert CMAKE_NO_SYSTEM_FROM_IMPORTED to CMake default#133

Open
marcosbento wants to merge 1 commit intodevelopfrom
feature/allow_system_from_imported
Open

Revert CMAKE_NO_SYSTEM_FROM_IMPORTED to CMake default#133
marcosbento wants to merge 1 commit intodevelopfrom
feature/allow_system_from_imported

Conversation

@marcosbento
Copy link
Collaborator

Description

CMAKE_NO_SYSTEM_FROM_IMPORTED controls the use of system (--isystem) vs non-system (-I) include directories for imported targets, such as those found via find_package.
See https://cmake.org/cmake/help/latest/variable/CMAKE_NO_SYSTEM_FROM_IMPORTED.html

This change ensures the use of the default value of CMAKE_NO_SYSTEM_FROM_IMPORTED (i.e. OFF),
meaning that system include directories are used for imported targets.

Contributor Declaration

By opening this pull request, I affirm the following:

  • All authors agree to the Contributor License Agreement.
  • The code follows the project's coding standards.
  • I have performed self-review and added comments where needed.
  • I have added or updated tests to verify that my changes are effective and functional.
  • I have run all existing tests and confirmed they pass.

CMAKE_NO_SYSTEM_FROM_IMPORTED controls the use of system (--isystem) vs
non-system (-I) include directories for imported targets, such as those
found via `find_package`.
See https://cmake.org/cmake/help/latest/variable/CMAKE_NO_SYSTEM_FROM_IMPORTED.html

The default value of CMAKE_NO_SYSTEM_FROM_IMPORTED is OFF, meaning that
system include directories are used for imported targets.
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR reverts an ecbuild-level override of CMAKE_NO_SYSTEM_FROM_IMPORTED so that ecbuild uses CMake’s default behavior (OFF), causing include directories from imported targets (e.g., via find_package) to be treated as system include paths.

Changes:

  • Removed the explicit set(CMAKE_NO_SYSTEM_FROM_IMPORTED ON) from ecbuild’s option initialization.
  • Restored CMake default handling for imported target include directories (system vs non-system).

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@marcosbento marcosbento marked this pull request as ready for review March 3, 2026 15:48
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.

2 participants