mirror of
https://github.com/eclipse-cdt/cdt
synced 2025-07-21 16:05:25 +02:00
Fix for [Bug 171976] Internal builder does not handle linked folders
This commit is contained in:
parent
d6dee0e045
commit
e4cac036c2
1 changed files with 11 additions and 7 deletions
|
@ -286,19 +286,23 @@ public class BuildDescriptionManager {
|
||||||
if(!location.isAbsolute())
|
if(!location.isAbsolute())
|
||||||
return location;
|
return location;
|
||||||
|
|
||||||
IPath path = null;
|
// IPath path = null;
|
||||||
IPath tmp = cwd;
|
IPath tmp = cwd;
|
||||||
|
StringBuffer buf = null;
|
||||||
while(tmp.segmentCount() != 0){
|
while(tmp.segmentCount() != 0){
|
||||||
if(tmp.isPrefixOf(location)){
|
if(tmp.isPrefixOf(location)){
|
||||||
IPath p = location.removeFirstSegments(tmp.segmentCount()).setDevice(null);
|
IPath p = location.removeFirstSegments(tmp.segmentCount()).setDevice(null);
|
||||||
if(path == null)
|
if(buf == null)
|
||||||
return p;
|
return p;
|
||||||
return path.append(p);
|
buf.append(p.makeRelative().toString());
|
||||||
|
return new Path(buf.toString());
|
||||||
|
}
|
||||||
|
if(buf == null){
|
||||||
|
buf = new StringBuffer();
|
||||||
|
buf.append("../"); //$NON-NLS-1$
|
||||||
|
} else {
|
||||||
|
buf.append("../"); //$NON-NLS-1$
|
||||||
}
|
}
|
||||||
if(path == null)
|
|
||||||
path = new Path(".."); //$NON-NLS-1$
|
|
||||||
else
|
|
||||||
path.append(".."); //$NON-NLS-1$
|
|
||||||
tmp = tmp.removeLastSegments(1);
|
tmp = tmp.removeLastSegments(1);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue