libarchive 3.1.2 (reduced)

Extract upstream libarchive using the following shell code.

url=git://github.com/libarchive/libarchive.git &&
v=3.1.2 &&
r=19f23e19 &&
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"
CMake Nightly Date Stamp
CMake Nightly Date Stamp
libarchive: Convert CRLF -> LF newlines
Merge topic 'update-libarchive' into next

fbed829 libarchive: Convert CRLF -> LF newlines
Merge branch 'libarchive-upstream' into update-libarchive

Conflicts:
	Utilities/cmlibarchive/CMakeLists.txt
	Utilities/cmlibarchive/libarchive/archive.h
	Utilities/cmlibarchive/libarchive/archive_entry.h
	Utilities/cmlibarchive/libarchive/archive_read_disk_posix.c
	Utilities/cmlibarchive/libarchive/archive_read_support_format_iso9660.c
	Utilities/cmlibarchive/libarchive/archive_windows.h
	Utilities/cmlibarchive/libarchive/archive_write_set_format_iso9660.c
libarchive: Update README-CMake.txt for new snapshot
libarchive: Include cm_zlib.h to get zlib used by CMake

Follow up change from commit ffa6faa4 (libarchive: Include cm_zlib.h to
get zlib used by CMake, 2011-12-20) for new includes of zlib.h in
updated libarchive.
libarchive: Silence API deprecation warnings

CMake uses old libarchive APIs for now.
libarchive: Avoid struct init with variable

Compilers such as Borland and MIPSpro do not like struct initialization
with variables.  Initialize using assignment instead.
libarchive: Remove build options not used by CMake

Drop options POSIX_REGEX_LIB and ENABLE_SAFESEH that we do not want for
the CMake build of libarchive.
libarchive: Backport to CMake 2.8.2

Avoid requiring CMake 2.8.6 for CMakePushCheckState or CMake 2.8.8 for
CMakeExpandImportedTargets.  Drop the custom versions of CMake modules
CheckCSource(Compiles|Runs) because we do not use the SAFESEH option
anyway.
libarchive: Update README for new upstream snapshot commit hash
Merge topic 'update-libarchive' into next

4056e88 libarchive: Update README for new upstream snapshot commit hash
Merge topic 'update-libarchive' into next

26fe7e3 libarchive: Backport to CMake 2.8.2
b81a4e1 libarchive: Remove build options not used by CMake
3218f52 libarchive: Avoid struct init with variable
bae3a73 libarchive: Silence API deprecation warnings
6773840 libarchive: Include cm_zlib.h to get zlib used by CMake
8dc0a9f libarchive: Update README-CMake.txt for new snapshot
102071f Merge branch 'libarchive-upstream' into update-libarchive
35df7c8 libarchive 3.1.2 (reduced)
Unify the way the flags of a static library are read

Introduce cmLocalGenerator::GetStaticLibraryFlags() to have a central
function for getting the linker flags for a given target.
Add support for CMAKE_STATIC_LINKER_FLAGS

Add the content of this variable to the target specific linker flags
as we do with the other CMAKE_*_LINKER_FLAGS variables already.
Add CMAKE_STATIC_LINKER_FLAGS to CMakeCommonLanguageInclude

Add support for CMAKE_STATIC_LINKER_FLAGS_* to
CMakeCommonLanguageInclude.cmake to set the defaults similar
to the other CMAKE_*_LINKER_FLAGS_*.
Add documentation for the missing CMAKE_*_LINKER_FLAGS_* variables

Add CMAKE_MODULE_LINKER_FLAGS_*, CMAKE_SHARED_LINKER_FLAGS_* and
CMAKE_STATIC_LINKER_FLAGS_* to cmDocumentVariables.cxx with a
similar documentation as CMAKE_EXE_LINKER_FLAGS_*.
Add additonal tests for the linker flags

Extend Tests/LinkFlags to test libraries of the type MODULE and
the content of the CMAKE_*_LINKER_FLAGS_* variables.