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

Add CMake include_guard() for cmake toolchain #8728

Merged
merged 2 commits into from Mar 29, 2021
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
6 changes: 2 additions & 4 deletions conan/tools/cmake/base.py
Expand Up @@ -71,10 +71,8 @@ class CMakeToolchainBase(object):

# Avoid including toolchain file several times (bad if appending to variables like
# CMAKE_CXX_FLAGS. See https://github.com/android/ndk/issues/323
if(CONAN_TOOLCHAIN_INCLUDED)
return()
endif()
set(CONAN_TOOLCHAIN_INCLUDED TRUE)
include_guard()


{% block before_try_compile %}
{# build_type (Release, Debug, etc) is only defined for single-config generators #}
Expand Down