From 19aafdb35526cbb2cf6b16cd8e264cb06cc15650 Mon Sep 17 00:00:00 2001 From: Brad King Date: Tue, 29 Apr 2008 14:17:35 -0400 Subject: [PATCH] ENH: Add context information when a source file cannot be found. --- Source/cmSourceFile.cxx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Source/cmSourceFile.cxx b/Source/cmSourceFile.cxx index da2e79aaef..7b322353f1 100644 --- a/Source/cmSourceFile.cxx +++ b/Source/cmSourceFile.cxx @@ -179,7 +179,7 @@ bool cmSourceFile::FindFullPath() cmOStringStream e; e << "Cannot find source file \"" << this->Location.GetName() << "\""; - e << "\n\nTried extensions"; + e << ". Tried extensions"; for(std::vector::const_iterator ext = srcExts.begin(); ext != srcExts.end(); ++ext) { @@ -190,7 +190,7 @@ bool cmSourceFile::FindFullPath() { e << " ." << *ext; } - cmSystemTools::Error(e.str().c_str()); + this->Location.GetMakefile()->IssueMessage(cmake::FATAL_ERROR, e.str()); this->FindFullPathFailed = true; return false; }