<div dir="ltr"><div class="gmail_extra"><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">It can't hurt to propose a bump in minimum cmake version, including<br>
the justification, but if it isn't broke - why fix it?<br></blockquote><div><br></div><div>No need to bump cmake versions. POSITION_INDEPENDENT_CODE has been around since 2.8.12 and CXX_STANDARD has been around since 3.1. The current minimum version is 3.4 so I'm simply proposing that some of the feattures that came with the version increase a few mmonths ago start to get leveraged.<br><br></div><div> </div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
On this feature specifically, I question how robust it will be in<br>
figuring out if c++11 or other c++ standard is *really* supported.<br></blockquote><div><br></div><div>It's manual. In Modules/Compilers/ in the same place that a compiler's other flags are defined, i.e. what flag to pas for Include dirs, library dirs, verbose output, etc. There are also definitions for which flags to pass to a given compiler for turning on C++ 98, 11, or 14 support, or enabling language extensions. So obviously for this to work for a given compiler and version then it needs to be taught accordingly. Support should already be in place for most compilers that build LLVM, but whichever ones aren't I'm willing to add it.<br><br></div><div> </div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
Does it internally include some complex hello world or just check for<br>
flags available.. etc... How will TR be handled? What versions are<br>
currently supported?<br></blockquote><div><br></div><div>As for partial standard support, that's a bit of a trickier issue. There is currently support for "compile features" where you can explicitly say "i need feature foo" where a compiler may say it supports the language spec but it's not fully implemented. Currently CMake supports the CXX_STANDARD values of 98, 11, and 14. TRs are not supports because they are not accepted language specs so if if LLVM wanted to explicitly depend on needing certiaqn TR funcitonality available in a compiler that isn't part of the language spec, then that case would need to be addressed manually. It's a. explicit table, not auto-detected, so if a current compiler doesn't have a populated feature table then that will need to be done but there's no barriers to making that happen.<br><br></div><div>For language standard, see:<br><a href="https://cmake.org/cmake/help/v3.7/prop_tgt/CXX_STANDARD.html">https://cmake.org/cmake/help/v3.7/prop_tgt/CXX_STANDARD.html</a><br><a href="https://cmake.org/cmake/help/v3.7/prop_tgt/CXX_STANDARD_REQUIRED.html">https://cmake.org/cmake/help/v3.7/prop_tgt/CXX_STANDARD_REQUIRED.html</a><br><br>For compile features, see:<br><a href="https://cmake.org/cmake/help/v3.7/manual/cmake-compile-features.7.html">https://cmake.org/cmake/help/v3.7/manual/cmake-compile-features.7.html</a><br><a href="https://cmake.org/cmake/help/v3.7/prop_gbl/CMAKE_CXX_KNOWN_FEATURES.html">https://cmake.org/cmake/help/v3.7/prop_gbl/CMAKE_CXX_KNOWN_FEATURES.html</a><br><br></div><div>Similarly, the same is available for C89/90, 99, and 11.<br><br></div><div>As for POSITION_INDEPENDENT_CODE, that's been available for a very long time in CMake and has been relied on for years.<br><br></div><div>- Chuck<br></div></div></div></div>