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
project(): unset VERSION variables if no VERSION is given

By unsetting the VERSION variables, it is ensured that in subdirs
with project()-calls without version not accidentially the VERSION
from parent directories is inherited. But only unset these variables
if they have been set by a previous project() call. This is done by
testing the cmake variable CMAKE_PROJECT_VERSION_SET_BY_PROJECT_COMMAND.

Alex
project(): improve documentation

Now also mention PROJECT_NAME, PROJECT_SOURCE_DIR and PROJECT_BINARY_DIR
in the documentation for project().

Alex
project(): document the new VERSION argument

Alex
write_basic_package_version_file(): make use of the new ${PROJECT_VERSION}

In the write_basic_package_version_file(), the VERSION argument
is now optional. If none is given, it falls back to ${PROJECT_VERSION}.

Alex
project(): add test for VERSION parameter

Alex
Merge topic 'AddVersionToProjectCommand' into next

047d35d3 project(): add test for VERSION parameter
6ef75f43 write_basic_package_version_file(): make use of the new ${PROJECT_VERSION}
7bb7474c project(): document the new VERSION argument
0569b189 project(): improve documentation
d5999726 project(): unset VERSION variables if no VERSION is given
44013262 project(): add optional VERSION argument