diff --git a/Source/cmFindPackageCommand.cxx b/Source/cmFindPackageCommand.cxx index 22bb62897..b0a760734 100644 --- a/Source/cmFindPackageCommand.cxx +++ b/Source/cmFindPackageCommand.cxx @@ -538,6 +538,7 @@ bool cmFindPackageCommand e << "given CONFIGS option followed by invalid file name \"" << args[i] << "\". The names given must be file names without " << "a path and with a \".cmake\" extension."; + this->SetError(e.str().c_str()); return false; } this->Configs.push_back(args[i]);