When the command is invoked without an explicit build directory path we
compute it from the source directory path. When either the source or
build tree is the root of a Windows drive letter it will have a trailing
slash. Handle slashes consistently when substituting the current output
directory for the current source directory.
While at it, use cmSystemTools::IsSubDirectory instead of FindLastString
to verify that the source directory is a subdirectory.
Inspired-by: Graham Menhennitt <graham@menhennitt.com.au>
This converts the CMake license to a pure 3-clause OSI-approved BSD
License. We drop the previous license clause requiring modified
versions to be plainly marked. We also update the CMake copyright to
cover the full development time range.