Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
RE: [cdt-dev] Problems with implementing a custom dependency generator

Hi Jesper,

Are you trying to make it work with external (e.g. make) or Internal
builder?

The COMMAND dep calculator is supported for external builders only (e.g.
make builder). The code snippet you posted is from the Internal Builder
which does not support this type of dep calculator since the Internal
Builder is using the PDOM-based dep calculator for dependency
calculation.

Mikhail

>-----Original Message-----
>From: cdt-dev-bounces@xxxxxxxxxxx [mailto:cdt-dev-bounces@xxxxxxxxxxx]
On
>Behalf Of Jesper Eskilson
>Sent: Thursday, September 20, 2007 5:50 PM
>To: CDT General developers list.
>Subject: [cdt-dev] Problems with implementing a custom dependency
generator
>
>Hi,
>
>I'm trying to implement my own dependency generator by extending the
>IManagedDependencyGenerator2 interface, as described in the "Managed
>Build System Extensibility Document". I'm using the internal builder
and
>and the calculator type is TYPE_BUILD_COMMANDS.
>
>The problem is that the dependency calculator does not seem to be used.
>The class is called to determine the type, but when I step into the
>calling code, the dependency calculator seems to be discarded.
>
>This is the code I'm looking at:
>
>In
>org.eclipse.cdt.managedbuilder.internal.buildmodel.BuildDescription#get
Depe
>ndencyCalculator()
>
>>
>> 		if(depGenType != null){
>> 			switch(depGenType.getCalculatorType()){
>> 			case
IManagedDependencyGeneratorType.TYPE_NODEPS:
>> 			case
IManagedDependencyGeneratorType.TYPE_NODEPENDENCIES:
>> 				//no dependencies
>> 				break;
>> 			case
IManagedDependencyGeneratorType.TYPE_INDEXER:
>> 			case
IManagedDependencyGeneratorType.TYPE_EXTERNAL:
>> 			case
IManagedDependencyGeneratorType.TYPE_CUSTOM:
>> 				depGen = depGenType;
>> 				break;
>> 			case
IManagedDependencyGeneratorType.TYPE_COMMAND:
>> 			case
IManagedDependencyGeneratorType.TYPE_BUILD_COMMANDS:
>> 			case
>IManagedDependencyGeneratorType.TYPE_PREBUILD_COMMANDS:
>> 				//TODO: may implement the .d file
parsing for deps
>calculation here
>> 				//break;
>> 			default:
>> 				depGen = getPDOMDependencyGenerator();
>> 				break;
>> 			}
>> 		} else {
>> 			depGen = getPDOMDependencyGenerator();
>> 		}
>
>The switch-statements falls through and depGen gets set to the result
of
>getPDOMDependencyGenerator(). It looks like the TYPE_*COMMAND[s]
>constants are ignored.
>
>Any clues on what's going on?
>
>--
>/Jesper
>_______________________________________________
>cdt-dev mailing list
>cdt-dev@xxxxxxxxxxx
>https://dev.eclipse.org/mailman/listinfo/cdt-dev
--------------------------------------------------------------------
Closed Joint Stock Company Intel A/O
Registered legal address: 125252, Moscow, Russian Federation, 
Chapayevsky Per, 14.

This e-mail and any attachments may contain confidential material for
the sole use of the intended recipient(s). Any review or distribution
by others is strictly prohibited. If you are not the intended
recipient, please contact the sender and delete all copies.


Back to the top