CMake: Fix for "The source directory does not contain CMakeLists.txt".

CMakeBuildInfo::sourceDirectory wasn't always populated, which sometimes
led to 'CMake Error: The source directory "<path>" does not appear to
contain CMakeLists.txt.' error when re-running CMake for shadow builds.

Change-Id: I4caece897155ee9e056d2da8185da43b94cbd99d
Reviewed-by: hjk <hjk121@nokiamail.com>