curl 7.16.1 (reduced)

Extract upstream curl using the following shell code.

url=git://github.com/bagder/curl.git &&
v=7.16.1 &&
r=ef442d58 &&
paths="
  COPYING
  include/curl/*.h
  lib/*.c
  lib/*.h
" &&
mkdir curl-$v-g$r-reduced &&
git clone $url curl-git &&
date=$(cd curl-git && git log -n 1 --format='%cd' $r) &&
(cd curl-git && git checkout $r &&
 git archive --format=tar $r -- $paths) |
(cd curl-$v-g$r-reduced && tar xv &&
 rm lib/config-*.h) &&
echo "g$r date: $date"
curl 7.38.0 (reduced)

Extract upstream curl using the following shell code.

url=git://github.com/bagder/curl.git &&
v=7.38.0 &&
r=202aa9f7 &&
paths="
  CMake/*
  CMakeLists.txt
  COPYING
  include/curl/*.h
  include/curl/curlbuild.h.cmake
  lib/*.c
  lib/*.h
  lib/CMakeLists.txt
  lib/Makefile.inc
  lib/curl_config.h.cmake
  lib/libcurl.rc
  lib/vtls/*.c
  lib/vtls/*.h
" &&
mkdir curl-$v-g$r-reduced &&
git clone $url curl-git &&
date=$(cd curl-git && git log -n 1 --format='%cd' $r) &&
(cd curl-git && git checkout $r &&
 git archive --format=tar $r -- $paths) |
(cd curl-$v-g$r-reduced && tar xv &&
 rm lib/config-*.h) &&
echo "g$r date: $date"
curl: Disable all whitespace checks in third-party code

Add a .gitattributes file to tell Git to skip whitespace checks
in the curl source code.
curl: Move sources back into upstream layout

Update our build files as needed to compensate.
curl: Drop unused testing code

Remove our "Testing/" directory renames of the upstream examples.
Merge branch 'curl-upstream' into update-curl

Use the '-s ours' merge strategy to keep our side unchanged.
This merge brings in the upstream snapshot as of the version
of curl on which our source is based.  This will allow new
snapshots to be merged with our changes.
curl: Drop our CMake infrastructure to make room for the upstream

Remove our curl CMake build files since upstream now provides some.
After merging the upstream versions we may then port them to build
inside CMake and take code from our old build files as needed.
Merge branch 'curl-upstream' into update-curl

Resolve all conflicts in favor of the upstream side.
We can re-apply specific changes later.
curl: Remove unused SIZEOF_LONG_DOUBLE

Re-apply change from commit v2.8.2~537 (cmcurl: Remove unused
SIZEOF_LONG_DOUBLE, 2009-12-17) on updated upstream curl.
curl: Fix warnings on 64-bit Mac OS X build

Re-apply change from commit v2.6.0~921 (Fix warnings on 64-bit Mac OS X
build, 2007-11-05) on updated upstream curl.
curl: Fix spelling errors reported by Lintian

Re-apply change from commit v2.8.3~265^2~1 (Fix spelling errors
reported by Lintian, 2010-07-02) on updated upstream curl.
curl: Drop '-DEV' from version since this is a curl release

We imported curl from an upstream release, so report the corresponding
release version to servers.  This is consistent with the version we
presented when our builtin curl was 7.16.1.
curl: Port to Haiku again

Re-apply change from commit v2.8.0~1683 (add initial support for HAIKU
OS, 2008-09-15) on updated upstream curl.  However, leave out the part
that was reverted by commit v3.0.0-rc1~541^2~1 (Haiku: Remove outdated
preprocessor checks, 2013-10-05).
curl: Remove outdated Haiku preprocessor checks

Re-apply change from commit v3.0.0-rc1~541^2~1 (Haiku: Remove outdated
preprocessor checks, 2013-10-05) on updated upstream curl.
curl: Simplify if() conditions on check result variables

Remove use of an old hack that takes advantage of the auto-dereference
behavior of the if() command to detect if a variable is defined.  The
hack has the form:

 if("${VAR} MATCHES "^${VAR}$")

where "${VAR}" is a macro argument reference.  Use if(DEFINED) instead.
This also avoids warnings for CMake Policy CMP0054.
KWSys 2014-10-31 (88c8cc7f)

Extract upstream KWSys using the following shell commands.

$ git archive --prefix=upstream-kwsys/ 88c8cc7f | tar x
$ git shortlog --no-merges --abbrev=8 --format='%h %s' 29ffaf43..88c8cc7f
Ben Boeckel (11):
      9bf03363 Avoid if() quoted auto-dereference
      771e0f22 DynamicLoader: use strings for arguments
      86e20d68 Directory: remove extra define
      6cc24510 SystemTools: use strings in environment functions
      bab5b1f2 SystemTools: add string overload for ReplaceString
      f3fb01cf SystemTools: use strings for path-related APIs
      0dfbe56d SystemTools: use strings for making C identifiers
      4690fc8d SystemTools: use strings in registry function
      1b762a41 SystemTools: search for characters
      4a060347 SystemInformation: use %ls for WCHAR* format specifiers
      d31f7b12 SystemTools: remove unused variable

Brad King (1):
      88c8cc7f Fix configure_file call to use COPYONLY, not COPY_ONLY

Clinton Stimpson (1):
      5bf91dda SystemTools:  Use extended length path for copying files.

Change-Id: I16e8e55dea1c171c04f9c7d04ae3c575531097c3
Merge branch 'upstream-kwsys' into update-kwsys
Watcom: Drop symfile linker option

Cleanup of Windows-wcl386.cmake in commit v3.1.0-rc1~693^2 (Watcom:
Cleanup Windows-wcl386 configuration, 2014-04-01) also introduced use of
the 'symfile' link option but did not mention it in the commit message.

There is no way to set the symbol file name of a target, so it is better
to revert that change.  It is easy to run 'wstrip *' if the symbols need
to be stripped, but it is very difficult to get the right names for the
.sym files to install with debug/rel_with_deb_info configurations.
Code Blocks/Eclipse: Use non-default stdlib includes when specified.

When -stdlib=x is specified in CMAKE_CXX_FLAGS this passes it along so
that the correct include dirs are detected.
Code Blocks/Eclipse: Add -std= flag matching.

When -std=x is specified in CMAKE_CXX_FLAGS this passes it along.