1
0
Fork 0
mirror of https://github.com/eclipse-cdt/cdt synced 2025-08-31 04:03:27 +02:00

Checked in the fix for the bug# 105754

This commit is contained in:
Mikhail Sennikovsky 2005-08-03 17:06:56 +00:00
parent 7860f3c765
commit 9e2941d120

View file

@ -405,10 +405,11 @@ public class ManagedBuildInfo implements IManagedBuildInfo, IScannerInfo {
*/ */
public String[] getLibsForConfiguration(String extension) { public String[] getLibsForConfiguration(String extension) {
Vector libs = new Vector(); Vector libs = new Vector();
ITool[] tools = getFilteredTools(); ITool tool = getDefaultConfiguration().getTargetTool();
for (int index = 0; index < tools.length; index++) { if(tool == null)
ITool tool = tools[index]; tool = getToolFromOutputExtension(extension);
if (tool.producesFileType(extension)) {
if(tool != null){
IOption[] opts = tool.getOptions(); IOption[] opts = tool.getOptions();
// Look for the lib option type // Look for the lib option type
for (int i = 0; i < opts.length; i++) { for (int i = 0; i < opts.length; i++) {
@ -452,7 +453,6 @@ public class ManagedBuildInfo implements IManagedBuildInfo, IScannerInfo {
continue; continue;
} }
} }
}
} }
return (String[])libs.toArray(new String[libs.size()]); return (String[])libs.toArray(new String[libs.size()]);
} }
@ -739,12 +739,11 @@ public class ManagedBuildInfo implements IManagedBuildInfo, IScannerInfo {
*/ */
public String[] getUserObjectsForConfiguration(String extension) { public String[] getUserObjectsForConfiguration(String extension) {
Vector objs = new Vector(); Vector objs = new Vector();
// Get all the tools for the current config ITool tool = getDefaultConfiguration().getTargetTool();
ITool[] tools = getFilteredTools(); if(tool == null)
for (int index = 0; index < tools.length; index++) { tool = getToolFromOutputExtension(extension);
ITool tool = tools[index];
// The tool is OK for this project nature if(tool != null){
if (tool.producesFileType(extension)) {
IOption[] opts = tool.getOptions(); IOption[] opts = tool.getOptions();
// Look for the user object option type // Look for the user object option type
for (int i = 0; i < opts.length; i++) { for (int i = 0; i < opts.length; i++) {
@ -775,7 +774,6 @@ public class ManagedBuildInfo implements IManagedBuildInfo, IScannerInfo {
continue; continue;
} }
} }
}
} }
return (String[])objs.toArray(new String[objs.size()]); return (String[])objs.toArray(new String[objs.size()]);
} }