Improve check for in-source build.