Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make SYSTEM argument optional in target_include_directories #4553

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

KOMMYHAP
Copy link

@KOMMYHAP KOMMYHAP commented Jun 2, 2024

Hello!
I'd like to use cmake FetchContent to download googletest sources and clang-cl to compile it. But in this case gtest include directory was not added to gtest target. Seems like SYSTEM argument in target_include_directories does not pollute target properties correctly.
I wrap SYSTEM argument in cmake option gtest_enable_system_include to save backward compatibility.

Fix bug when include directories hidden from clang-cl & cmake-fetch-content
@lilianmoraru
Copy link

Sounds like a CMake bug.
Did you try using the latest stable CMake?

@KOMMYHAP
Copy link
Author

Hm, you may be right. I'll try it later and come back

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