<div dir="ltr"><div><br></div><div>Not really answering the question butĀ </div>did you try to use an existing CMake module for handling sanitizers config?<div><br></div><div>I find this one <a href="https://github.com/arsenm/sanitizers-cmake">https://github.com/arsenm/sanitizers-cmake</a> very effective, with</div><div>modern CMake target oriented features.</div><div><div><br></div><div><br></div><div><br></div></div></div><div class="gmail_extra"><br><div class="gmail_quote">2017-12-07 9:24 GMT+01:00 Damien R <span dir="ltr"><<a href="mailto:damienrg+list@gmail.com" target="_blank">damienrg+list@gmail.com</a>></span>:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">Hi,<div><br></div><div>I am trying to use CHECK_CXX_COMPILER_FLAG with cmake 3.9 to check if the compiler supports asan.</div><div>The CMakeLists.txt is:</div><div><div>cmake_minimum_required(VERSION 3.9)</div><div>include(CheckCXXCompilerFlag)</div><div>check_cxx_compiler_flag("-<wbr>fsanitize=address" COMPILER_SUPPORT_FLAG)</div></div><div><br></div><div>I always got:</div><div>-- Performing Test COMPILER_SUPPORT_FLAG - Failed<br></div><div><br></div><div>Even if the documentation say that CHECK_CXX_COMPILER_FLAG sets CMAKE_REQUIRED_DEFINITIONS by the name of the macro I thought that it would work.</div><div>Can you tell me why CHECK_CXX_COMPILER_FLAG use CMAKE_REQUIRED_DEFINITIONSĀ <wbr>instead of CMAKE_REQUIRED_FLAGS</div><div>and what is the official way for checking this flag?</div><div><br></div><div>Regards,</div><div><br></div><div>Damien R.</div><div><br></div></div>
<br>--<br>
<br>
Powered by <a href="http://www.kitware.com" rel="noreferrer" target="_blank">www.kitware.com</a><br>
<br>
Please keep messages on-topic and check the CMake FAQ at: <a href="http://www.cmake.org/Wiki/CMake_FAQ" rel="noreferrer" target="_blank">http://www.cmake.org/Wiki/<wbr>CMake_FAQ</a><br>
<br>
Kitware offers various services to support the CMake community. For more information on each offering, please visit:<br>
<br>
CMake Support: <a href="http://cmake.org/cmake/help/support.html" rel="noreferrer" target="_blank">http://cmake.org/cmake/help/<wbr>support.html</a><br>
CMake Consulting: <a href="http://cmake.org/cmake/help/consulting.html" rel="noreferrer" target="_blank">http://cmake.org/cmake/help/<wbr>consulting.html</a><br>
CMake Training Courses: <a href="http://cmake.org/cmake/help/training.html" rel="noreferrer" target="_blank">http://cmake.org/cmake/help/<wbr>training.html</a><br>
<br>
Visit other Kitware open-source projects at <a href="http://www.kitware.com/opensource/opensource.html" rel="noreferrer" target="_blank">http://www.kitware.com/<wbr>opensource/opensource.html</a><br>
<br>
Follow this link to subscribe/unsubscribe:<br>
<a href="http://public.kitware.com/mailman/listinfo/cmake" rel="noreferrer" target="_blank">http://public.kitware.com/<wbr>mailman/listinfo/cmake</a><br></blockquote></div><br><br clear="all"><div><br></div>-- <br><div class="gmail_signature" data-smartmail="gmail_signature"><div dir="ltr"><div><div dir="ltr"><div>Eric<br></div></div></div></div></div>
</div>