Eclipse: make targets work from any directory
Set the working directory for make targets which are associated to virtual folders, otherwise Eclipse simply runs make from the current working directory (where Eclipse has been started), and where probably not the correct makefile is located. Alex
This commit is contained in:
parent
07e88ae449
commit
057633151a
|
@ -998,7 +998,11 @@ void cmExtraEclipseCDT4Generator::CreateCProjectFile() const
|
|||
std::string virtDir = "[Targets]/";
|
||||
virtDir += prefix;
|
||||
virtDir += ti->first;
|
||||
this->AppendTarget(fout, "Build", make, makeArgs, virtDir, "",
|
||||
std::string buildArgs = "-C ";
|
||||
buildArgs += makefile->GetHomeOutputDirectory();
|
||||
buildArgs += " ";
|
||||
buildArgs += makeArgs;
|
||||
this->AppendTarget(fout, "Build", make, buildArgs, virtDir, "",
|
||||
ti->first.c_str());
|
||||
|
||||
std::string cleanArgs = "-E chdir \"";
|
||||
|
|
Loading…
Reference in New Issue