libarchive 3.1.2-218-g00f4bd83 (reduced)

Extract upstream libarchive using the following shell code.

url=git://github.com/libarchive/libarchive.git &&
v=3.1.2-218-g00f4bd83 &&
r=00f4bd83 &&
paths="
  CMakeLists.txt
  COPYING
  CTestConfig.cmake
  build/cmake
  build/pkgconfig
  build/utils
  build/version
  libarchive/*.*
" &&
mkdir libarchive-$v-g$r-reduced &&
git clone $url libarchive-git &&
date=$(cd libarchive-git && git log -n 1 --format='%cd' $r) &&
(cd libarchive-git && git archive --format=tar $r -- $paths) |
(cd libarchive-$v-g$r-reduced && tar xv) &&
fromdos libarchive-$v-g$r-reduced/build/cmake/Find*.cmake &&
echo "g$r date: $date"
libarchive: Disable more whitespace checks in third-party code
Merge branch 'libarchive-upstream' into update-libarchive

Resolve conflicts in favor of the upstream side where possible.
Resolve a logical conflict in archive_windows.h where the upstream
port to Watcom was done slightly differently from ours.
libarchive: Update README-CMake.txt for new snapshot
libarchive: Do not generate a pkg-config file

CMake does not install the headers or libraries so skip the .pc file
too.
libarchive: Drop options not present in reduced version

Drop ENABLE_TAR and ENABLE_CPIO related options because we do not build
these command-line tools.  Drop ENABLE_TEST and ENABLE_COVERAGE options
because we do not build the tests.
libarchive: Update archive_util.c to use CMake zlib and bzip2 headers
libarchive: Convert literal LL suffix to ARCHIVE_LITERAL_LL
libarchive: Do not require includers to have windows.h

In archive_entry.h refer to "BY_HANDLE_FILE_INFORMATION *" using
"struct _BY_HANDLE_FILE_INFORMATION *" to avoid requiring the
includer to already have <windows.h>.
Update libarchive configuration within CMake

Hard-code libarchive build options to the way CMake needs them.  Set
them as internal cache entries so users do not see them when building
CMake.
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.
Tests: Require CMake 3.0 for the SystemInformation test.

Correctly identify AppleClang.
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.
project: Add infrastructure for recording CXX compiler features

Add a feature test using the compiler macros and the preprocessor to
determine available features.

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.

This will be extended to other languages in the future.  Follow-up
commits will add features which will be recorded by the feature test.
cmTarget: Add COMPILE_FEATURES target property.

Use the contents of it to upgrade the CXX_STANDARD target property,
if appropriate.  This will have the effect of adding the -std=c++11
compile flag or other language specification on GNU when that is
needed for the feature.
Features: Add cxx_auto_type.

Record the availability of this feature for GNU 4.8 on (UNIX AND
NOT APPLE) only.  In the future, availability can be recorded for
earlier GNU, for other platforms and for other compilers. Initially
the affected configurations are as restricted as possible to allow
for easy testing while extending the features vector in only one
dimension.

The error message when using the set_property API directly is not
very good, but follow up commits will provide origin debugging of
the property and a target_compile_features command which will
provide a configure-time backtrace when possible.
cmTarget: Allow populating COMPILE_FEATURES using generator expressions.

Delay validation of the content as a feature if it contains a
generator expression. It will be checked again at generate-time
after evaluation.
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.

Use the same pattern of origin-debugging which is used for other
build properties.
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.