Fix builds outside of the source tree

Hello,

Please consider small fix to allow builds in a directory other than the source directory.