project(): add optional VERSION argument

This patch adds support for an optional VERSION
argument to project().
With this patch, project() now also sets
PROJECT_VERSION_(MAJOR|MINOR|PATCH|TWEAK) and
<Name>_VERSION_(MAJOR|MINOR|PATCH|TWEAK) variables.
This makes it possible for other functions or macros
to rely on these variables containing the version number
of the current project.

Alex
ExternalProject: Reattempt download when verification fails.

When downloading an URL with ExternalProject, reattempt the download three
times if the file hash verification fails.

The re-attempt is limited to non-local URL's.  The same download CMake script
is re-used after removing any file that resulted from the previous download
attempt.  Up to three re-attempts are performed.
file DOWNLOAD: Add test for bad hash.
file DOWNLOAD: Test non-zero return status.
file DOWNLOAD: Display the curl result status when a hash mismatch occurs.
cmMakefile: Make FindSourceGroup const.

Return a pointer instead of a reference.  This allows making the accessor
const with the least impact.
cmMakefile: Make ConfigureString const.
Merge topic 'constify' into next

bde0dab1 cmMakefile: Make ConfigureString const.
bf1e1bf1 cmMakefile: Make FindSourceGroup const.
CMake Nightly Date Stamp
Merge topic 'robust-ep-download-verify' into next

a432b93b file DOWNLOAD: Display the curl result status when a hash mismatch occurs.
1cb9ef81 file DOWNLOAD: Test non-zero return status.
f73f0fb3 file DOWNLOAD: Add test for bad hash.
b5e2265f ExternalProject: Reattempt download when verification fails.
CMake Nightly Date Stamp
Qt4: Create IMPORTED executable targets for all Qt executables.

Qt 5 already has similar IMPORTED targets.  The versioned namespace will
allow de-conflicting the variable names between Qt 4 and Qt 5.
Qt4: Use IMPORTED executable names with custom commands.

Finding Qt 5 can overwrite the QT_MOC_EXECUTABLE variable with the
moc from Qt 5. Use the IMPORTED target with the explicit version in
the name to avoid that.
QtAutogen: Use Qt 4 IMPORTED targets to find executable locations.

Avoid using the moc from Qt 5 with Qt 4 based targets. Moc generates
a version check to ensure that such generated code does not compile.

The Qt4And5Automoc unit test should have been testing this, but it
was not because the test was broken. In that unit test, moc was run
on trivial files which have no significant content, and in particular
no Q_OBJECT macro.  Therefore moc was generating empty files which
do not even contain the version check.  Fix this by generating files
for input to moc at cmake time.
QtAutogen: Remove read of SKIP_AUTOUIC target property.

Skipping AUTOUIC for a target is achieved by setting the AUTOUIC
target property go OFF.
QtAutogen: Remove unused variables.
QtAutogen: Fix autouic target options in the presence of a config.

Read the correct variable.  Add scopes to prevent escape of variables.
Merge topic 'fix-Qt-autogen' into next

19b96de7 QtAutogen: Fix autouic target options in the presence of a config.
7ec00ebe QtAutogen: Remove unused variables.
08c09a26 QtAutogen: Remove read of SKIP_AUTOUIC target property.
d7bdf0f3 QtAutogen: Use Qt 4 IMPORTED targets to find executable locations.
7ea41a02 Qt4: Use IMPORTED executable names with custom commands.
058ddd3a Qt4: Create IMPORTED executable targets for all Qt executables.
558a7791 CMake Nightly Date Stamp
QtAutogen: Make some methods appropriately file-static.
Merge topic 'fix-Qt-autogen' into next

c0f60537 QtAutogen: Make some methods appropriately file-static.