fixed cmake to compile if used as submodule