mirror of
https://github.com/ultimatepp/ultimatepp.git
synced 2026-05-21 06:45:39 -06:00
ide: Fixed response files vs pkg-config
git-svn-id: svn://ultimatepp.org/upp/trunk@14371 f0d560ea-af0d-0410-9eb7-867de7ffcac7
This commit is contained in:
parent
8977ee8d30
commit
68fe80d2bb
3 changed files with 12 additions and 11 deletions
|
|
@ -480,7 +480,7 @@ bool GccBuilder::Link(const Vector<String>& linkfile, const String& linkoptions,
|
||||||
for(int i = 0; i < linkfile.GetCount(); i++)
|
for(int i = 0; i < linkfile.GetCount(); i++)
|
||||||
if(GetFileTime(linkfile[i]) > targettime) {
|
if(GetFileTime(linkfile[i]) > targettime) {
|
||||||
Vector<String> lib;
|
Vector<String> lib;
|
||||||
String lnk;
|
String lnk = CompilerName();
|
||||||
if(IsVerbose())
|
if(IsVerbose())
|
||||||
lnk << " -v";
|
lnk << " -v";
|
||||||
if(HasFlag("GCC32"))
|
if(HasFlag("GCC32"))
|
||||||
|
|
@ -582,16 +582,6 @@ bool GccBuilder::Link(const Vector<String>& linkfile, const String& linkoptions,
|
||||||
PutConsole("Linking...");
|
PutConsole("Linking...");
|
||||||
bool error = false;
|
bool error = false;
|
||||||
CustomStep(".pre-link", Null, error);
|
CustomStep(".pre-link", Null, error);
|
||||||
if(lnk.GetCount() < 8000)
|
|
||||||
lnk = CompilerName() + " " + lnk;
|
|
||||||
else {
|
|
||||||
String rn = CatAnyPath(outdir, "link");
|
|
||||||
PutVerbose("Generating response file: " << rn);
|
|
||||||
PutVerbose(lnk);
|
|
||||||
lnk.Replace("\\", "/");
|
|
||||||
SaveFile(rn, lnk);
|
|
||||||
lnk = CompilerName() + " @" + rn;
|
|
||||||
}
|
|
||||||
if(!error && Execute(lnk) == 0) {
|
if(!error && Execute(lnk) == 0) {
|
||||||
CustomStep(".post-link", Null, error);
|
CustomStep(".post-link", Null, error);
|
||||||
PutConsole(String().Cat() << GetHostPath(target) << " (" << GetFileInfo(target).length
|
PutConsole(String().Cat() << GetHostPath(target) << " (" << GetFileInfo(target).length
|
||||||
|
|
|
||||||
|
|
@ -51,6 +51,15 @@ String Builder::CmdX(const char *s)
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
(cmdf ? cmd : r).Cat(*s);
|
(cmdf ? cmd : r).Cat(*s);
|
||||||
|
int q = r.Find(' ');
|
||||||
|
if(r.GetCount() > 8000 && q >= 0) {
|
||||||
|
String rn = CatAnyPath(outdir, AsString(tmpfilei.GetAdd(outdir, 0)++) + ".cmd");
|
||||||
|
PutVerbose("Generating response file: " << rn);
|
||||||
|
PutVerbose(r);
|
||||||
|
r.Replace("\\", "/"); // clang win32 needs this
|
||||||
|
SaveFile(rn, r.Mid(q + 1));
|
||||||
|
r = r.Mid(0, q) + " @" + rn;
|
||||||
|
}
|
||||||
return r;
|
return r;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -444,6 +444,8 @@ struct Builder {
|
||||||
|
|
||||||
Index<String> pkg_config; // names of packages for pkg-config
|
Index<String> pkg_config; // names of packages for pkg-config
|
||||||
|
|
||||||
|
VectorMap<String, int> tmpfilei; // for naming automatic response files
|
||||||
|
|
||||||
String CmdX(const char *s);
|
String CmdX(const char *s);
|
||||||
|
|
||||||
virtual bool BuildPackage(const String& package, Vector<String>& linkfile, Vector<String>& immfile,
|
virtual bool BuildPackage(const String& package, Vector<String>& linkfile, Vector<String>& immfile,
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue