mirror of
https://github.com/eclipse-cdt/cdt
synced 2025-04-29 19:45:01 +02:00
Consider resource configuration tools during conversion
This commit is contained in:
parent
7c22c0d5f1
commit
dcec32b0ef
2 changed files with 30 additions and 4 deletions
|
@ -2677,7 +2677,32 @@ public class ManagedBuildManager extends AbstractCExtension implements IScannerI
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// walk through each resource configuration and look if there are any converters
|
||||||
|
// available. If so, invoke them.
|
||||||
|
IResourceConfiguration [] resourceConfigs = configuration.getResourceConfigurations();
|
||||||
|
if ( ( resourceConfigs != null) && ( resourceConfigs.length > 0)) {
|
||||||
|
for (int j = 0; j < resourceConfigs.length; j++) {
|
||||||
|
IResourceConfiguration resConfig = resourceConfigs[j];
|
||||||
|
ITool [] resTools = resConfig.getTools();
|
||||||
|
for (int k = 0; k < resTools.length; k++) {
|
||||||
|
ITool resTool = resTools[k];
|
||||||
|
if (forCurrentMbsVersion) {
|
||||||
|
element = ((Tool)resTool).getCurrentMbsVersionConversionElement();
|
||||||
|
} else {
|
||||||
|
element = ((Tool)resTool).getPreviousMbsVersionConversionElement();
|
||||||
|
}
|
||||||
|
if (element != null) {
|
||||||
|
if ( invokeConverter(resTool, element) == null ) {
|
||||||
|
buildInfo.getManagedProject().setValid(false);
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
} // end of if
|
||||||
}
|
}
|
||||||
|
|
||||||
// If control comes here, it means either there is no converter element
|
// If control comes here, it means either there is no converter element
|
||||||
// or converters are invoked successfully
|
// or converters are invoked successfully
|
||||||
return true;
|
return true;
|
||||||
|
|
|
@ -570,11 +570,12 @@ public class Tool extends HoldsOptions implements ITool, IOptionCategory {
|
||||||
IResourceConfiguration resConfig = (IResourceConfiguration) getParent();
|
IResourceConfiguration resConfig = (IResourceConfiguration) getParent();
|
||||||
setSuperClass( resConfig.getParent().getTool(superClassId) );
|
setSuperClass( resConfig.getParent().getTool(superClassId) );
|
||||||
} else {
|
} else {
|
||||||
setSuperClass( ManagedBuildManager.getExtensionTool(superClassId) );
|
setSuperClass( ManagedBuildManager.getExtensionTool(superClassId) );
|
||||||
|
|
||||||
// Check for migration support
|
|
||||||
checkForMigrationSupport();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Check for migration support
|
||||||
|
checkForMigrationSupport();
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// Get the unused children, if any
|
// Get the unused children, if any
|
||||||
|
|
Loading…
Add table
Reference in a new issue