1
0
Fork 0
mirror of https://github.com/eclipse-cdt/cdt synced 2025-07-01 22:25:25 +02:00

Fix for [Bug 171976] Internal builder does not handle linked folders

This commit is contained in:
Mikhail Sennikovsky 2007-05-11 12:15:42 +00:00
parent d6dee0e045
commit e4cac036c2

View file

@ -286,19 +286,23 @@ public class BuildDescriptionManager {
if(!location.isAbsolute())
return location;
IPath path = null;
// IPath path = null;
IPath tmp = cwd;
StringBuffer buf = null;
while(tmp.segmentCount() != 0){
if(tmp.isPrefixOf(location)){
IPath p = location.removeFirstSegments(tmp.segmentCount()).setDevice(null);
if(path == null)
if(buf == null)
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);
}