Mercurial > projects > ldc
diff gen/toobj.cpp @ 815:35de5ba7d36d
Added error when gcc cannot be found.
author | Tomas Lindquist Olsen <tomas.l.olsen@gmail.com> |
---|---|
date | Mon, 01 Dec 2008 15:21:33 +0100 |
parents | 05f2651caa6c |
children | b972fec8a5f5 |
line wrap: on
line diff
--- a/gen/toobj.cpp Mon Dec 01 15:18:22 2008 +0100 +++ b/gen/toobj.cpp Mon Dec 01 15:21:33 2008 +0100 @@ -409,6 +409,11 @@ using namespace llvm; sys::Path gcc = llvm::sys::Program::FindProgramByName("gcc"); + if (gcc.empty()) + { + error("failed to locate gcc"); + fatal(); + } // Remove these environment variables from the environment of the // programs that we will execute. It appears that GCC sets these