Hi Nils,
Please create a bugzilla report
regarding this and I’ll take a look into this ASAP.
Thanks,
Mikhail
From:
cdt-dev-bounces@xxxxxxxxxxx [mailto:cdt-dev-bounces@xxxxxxxxxxx] On Behalf Of Hagge, Nils
Sent: Monday, April 16, 2007 4:15
PM
To: cdt-dev@xxxxxxxxxxx
Subject: [cdt-dev] (no subject)
I have/found a problem in the new CDT 4.0.0 running with
Eclipse 3.3.
We have a special plug-in that deals with crossplatform c development.
This plugin has to translate "unix style" path names when running
under windows with cygwin. E.g.
/usr/include .... becomes D:/cygwin/usr/incude and so on.
The plugin worked well with CDT 3.1.2 but does not longer
with the
latest version.
The problem is related to the method
CProjet.computeSourceRoots (see below).
In the former version it called getResolvedPathEntries(), which in turn
calls after several related calls the tool specific optionPathConverter.
The optionPathConverter is responsible for the conversion of the paths.
But in CDT 4.0.0 this calls is commented out. It seems to me
that the
structure of the project related information has severly been changed.
Can someone help me with this?
Why has the call to geTResolvedPathEntries() been cancelled?
How can I assure that the optionPathConverter gets called again correctly?
========================== CDT 4.0.0
=======================================================
package org.eclipse.cdt.internal.core.model;
public class CProject extends Openable implements ICProject
{ ....
protected List computeSourceRoots() throws
CModelException {
//IPathEntry[] entries =
getResolvedPathEntries();
<------- missing call
ICSourceEntry[] entries = null;
CProjectDescription des =
(CProjectDescription)CProjectDescriptionManager.getInstance().getProjectDescription(getProject(),
false);
if(des != null){
ICConfigurationDescription cfg =
des.getIndexConfiguration();
if(cfg != null)
entries = cfg.getSourceEntries();
}
if(entries != null){
ArrayList list = new ArrayList(entries.length);
for (int i = 0; i < entries.length; i++) {
// if (entries[i].getEntryKind() ==
IPathEntry.CDT_SOURCE) {
ICSourceEntry sourceEntry = (ICSourceEntry)entries[i];
ISourceRoot root = getSourceRoot(sourceEntry);
if (root != null) {
list.add(root);
}
// }
}
return list;
}
return new ArrayList(0);
}
========================== CDT 3.1.2
========================================================
protected List computeSourceRoots() throws CModelException {
IPathEntry[] entries = getResolvedPathEntries();
ArrayList list = new ArrayList(entries.length);
for (int i = 0; i < entries.length; i++) {
if (entries[i].getEntryKind() ==
IPathEntry.CDT_SOURCE) {
ISourceEntry sourceEntry =
(ISourceEntry)entries[i];
ISourceRoot root =
getSourceRoot(sourceEntry);
if (root != null) {
list.add(root);
}
}
}
return list;
}