Don't load Clang-CXX from AppleClang-CXX.

The Clang-CXX module is going to get version-specific checks, and
the version system for AppleClang is not the same as Clang.
Add some COMPILE_OPTIONS for specifying C++ dialect.

These are compiler-specific, compiler version specific, extension specific
and standard version specific.
cmTarget: Add CXX_STANDARD and CXX_EXTENSION target properties.

These are used to determine whether to add -std=c++11, -std=gnu++11
etc flags on the compile line.
Record the compilers capable of the cxx_delegating_constructors feature.

Add a feature test using the compiler macros and the preprocessor to
determine available features. Add a unit test which outputs the
feature test file compiled. Record the list of features in
the SystemInformation unit test.

Add a CMAKE_CXX_COMPILE_FEATURES variable which contains all features
known to the loaded compiler, and a CMAKE_CXX_KNOWN_FEATURES variable
containing all features known to CMake. Add language standard specific
variables for internal use to determine the standard-specific compile
flags to use. Add internal variables matching CMAKE_PP_NAME_<feature>
for each feature. Those variables are used as preprocessor defines.
CMakeDetermineCompilerId: Look for internal file only on host

The find_file this module uses to locate the compiler id source file
must always look on the host and never in CMAKE_FIND_ROOT_PATH, even
when a toolchain file has

 set(CMAKE_FIND_ROOT_PATH_MODE_INCLUDE ONLY)

Add NO_CMAKE_FIND_ROOT_PATH to the find_file call to avoid rerooting.
Record compilers capable of the gnuxx_typeof feature.
Record compilers capable of msvcxx_sealed feature.

Clang-cl is capable of this feature, but that is not yet released,
nor have I tested it.
Add target_compile_features command.

This can be used to set the compiler features required by particular
targets. An error is issued at CMake time if the compiler does not
support the required feature. If a language dialect flag is required
by the features used, that will be added automatically.
cmTarget: Make COMPILE_FEATURES available as a target property.
cmTarget: Allow populating COMPILE_FEATURES using generator expressions.
cmTarget: Transitively evaluate compiler features.

Extend the interface of the target_compile_features command with
PUBLIC and INTERFACE keywords. Populate the INTERFACE_COMPILER_FEATURES
target property if they are set. Consume the INTERFACE_COMPILER_FEATURES
target property from linked dependent targets to determine the final
required compiler features and the compile flag, if needed.
cmTargetPropCommandBase: Change the interface to return bool.

This is needed for the target_compile_features command, which
may fail at configure time if an invalid feature is specified.
Base the target_compile_features command on cmTargetPropCommandBase.

This gives us 'free' handling of IMPORTED, ALIAS, INTERFACE,
non-compilable and missing targets.
Merge topic 'target_compile_features' into next

fe999df Base the target_compile_features command on cmTargetPropCommandBase.
55554c8 cmTargetPropCommandBase: Change the interface to return bool.
d678d8f cmTarget: Transitively evaluate compiler features.
2765047 cmTarget: Allow populating COMPILE_FEATURES using generator expressions.
cebc672 cmTarget: Make COMPILE_FEATURES available as a target property.
98c146f Add target_compile_features command.
b1c79a8 Record compilers capable of msvcxx_sealed feature.
9afa323 Record compilers capable of the gnuxx_typeof feature.
f97e89e Record the compilers capable of the cxx_delegating_constructors feature.
010bcd9 cmTarget: Add CXX_STANDARD and CXX_EXTENSION target properties.
86d133e Add some COMPILE_OPTIONS for specifying C++ dialect.
0a16246 Don't load Clang-CXX from AppleClang-CXX.
Add compiler target compile options.

For clang, this allows passing -target <triple> to the compiler, and
for qcc, -V<arch> using toolchain files containing something like

 set(triple arm-linux-gnueabihf)
 set(CMAKE_C_COMPILER "/usr/bin/clang")
 set(CMAKE_C_COMPILER_TARGET ${triple})
 set(CMAKE_CXX_COMPILER "/usr/bin/clang++")
 set(CMAKE_CXX_COMPILER_TARGET ${triple})

or

 set(arch gcc_ntoarmv7le)
 set(CMAKE_C_COMPILER /opt/qnx650/host/linux/x86/usr/bin/qcc)
 set(CMAKE_C_COMPILER_TARGET ${arch})
 set(CMAKE_CXX_COMPILER /opt/qnx650/host/linux/x86/usr/bin/QCC)
 set(CMAKE_CXX_COMPILER_TARGET ${arch})

Both clang and qcc are inherently cross compiler( driver)s.

When cross-compiling with clang, use the CMAKE_${lang}_COMPILER_TARGET
as the _CMAKE_TOOLCHAIN_PREFIX to find the appropriate binutils.

When cross-compiling with QNX qcc, use the CMAKE_${lang}_COMPILER_TARGET
to set the appropriate _CMAKE_TOOLCHAIN_PREFIX.
Allow toolchain files to specify an external toolchain.

Clang can compile code, but uses the gcc tools for other tasks such
as linking. The -gcc-toolchain option can be used for that, but
generalize so that other compilers can be treated the same.

If such a location is specified, use it as a hint for finding
the binutils executables.
Add CMAKE_SYSROOT variable to set --sysroot when cross compiling.

As CMAKE_ROOT_FIND_PATH can be a list, a new CMAKE_SYSROOT is
introduced, which is never a list.

The contents of this variable is passed to supporting compilers
as --sysroot. It is also accounted for when processing implicit
link directories reported by the compiler, and when generating
RPATH information.
Merge topic 'cross-compiling-toolchain-variables' into next

7cd65c9 Add CMAKE_SYSROOT variable to set --sysroot when cross compiling.
5096967 Allow toolchain files to specify an external toolchain.
76552d5 Add compiler target compile options.
f41ecd1 CMakeDetermineCompilerId: Look for internal file only on host
Merge topic 'cross-compiling-toolchain-variables'

7cd65c9 Add CMAKE_SYSROOT variable to set --sysroot when cross compiling.
5096967 Allow toolchain files to specify an external toolchain.
76552d5 Add compiler target compile options.
f41ecd1 CMakeDetermineCompilerId: Look for internal file only on host
Merge branch 'master' into next