[
Date Prev][
Date Next][
Thread Prev][
Thread Next][
Date Index][
Thread Index]
[
List Home]
| [cdt-dev] Defining new Build Properties / Automatic tool settings adjustment with Build Properties | 
Hi,
 
I want automatically 
adjust my tool setting, depending on the target type, the user can select in the 
New Project Wizard Page. Therefore I defined new project templates 
and template associations :
 
plugin.xml:
...
<extension 
point="org.eclipse.cdt.core.templates">
    
<template id="test.templates.project.executable" location="/templates/template.xml" 
projectType="org.eclipse.cdt.build.core.buildArtefactType.exe" />
    
<template id="test.templates.project.staticLib" location="/templates/template.xml" 
projectType="org.eclipse.cdt.build.core.buildArtefactType.staticLib"/>
</extension>
<extension point="org.eclipse.cdt.core.templateAssociations">
    <template id="test.templates.project.executable">
        
<toolChain id="com.siemens.ad.audis.toolchain.base" 
/>
    
</template>
        
<template id="test.templates.project.staticLib">
    <toolChain id="com.siemens.ad.audis.toolchain.base" />
    
</template>
</extension>
...
template.xml
...
<property-group id="basics" label="Basic Settings" 
description="Basic properties of an AUDIS executable 
project" type="PAGES-ONLY" 
help="help.html">
    <property id="targetType" 
label="Target Type" 
description="Select the target type." 
type="select" default="x86" hidden="false" 
mandatory="true" 
persist="true">
        
<item label="x86" value="x86"/>
        
<item label="ARM" value="ARM"/>
    
</property>
    
</property-group>
...
(see 
result in project.jpg)
<extension 
point="org.eclipse.cdt.managedbuilder.core.buildProperties"  id="test.baseproperties"  name="Test  Base Build Properties 
Definition">
        
<propertyType  id="test.buildproperty.targetType"  name="Target Type" />
        
<propertyValue property="test.buildproperty.targetType" id="test.targetType.x86" name="x86" />
        
<propertyValue property="test.buildproperty.targetType" id="test.targetType.arm" name="ARM" />
</extension>
In the build definitions I would 
like to use supported properties and enablement mechanism to specify tool 
property values e.g. the value for compiler property "command". 
<extension name="Test Build Definitions" point="org.eclipse.cdt.managedbuilder.core.buildDefinitions">
    <managedBuildRevision 
fileVersion="4.0.0" />
    <tool id="com.siemens.ad.rtp.audis.generic.tools.compiler.c" name="Generic Test GCC C Compiler" superClass="cdt.managedbuild.tool.gnu.c.compiler">
        
<supportedProperties>
            
<property id="test.buildproperty.targetType">
            
<value id="test.targetType.x86" />
            
<value id="test.targetType.arm" 
/>
        
</property>
Where can I find 
an enablement-description? Is it possible to set the value of a 
tool property (command), dependent on  build properties? Or is it only used 
for options? And how can I set a relationship from my own build properties to a 
user input?
Any 
idea/example? How can help?
Irene
With best regards,
Irene Schlemper 
Siemens 
AG 
Industry Sector
Industry Automation Division
Advanced Technologies 
& Standards 
I IA&DT ATS 13 
Gleiwitzer Str. 555 
90475 
Nuremberg, Germany 
Tel.: +49 (911) 895-3290 
Fax: +49 (911) 895-3715 
mailto:irene.schlemper@xxxxxxxxxxx 
Siemens Aktiengesellschaft: 
Chairman of the Supervisory Board: Gerhard Cromme; Managing Board: Peter 
Loescher, Chairman, President and Chief Executive Officer; Wolfgang Dehen, 
Heinrich Hiesinger, Joe Kaeser, Barbara Kux, Hermann Requardt, Siegfried 
Russwurm, Peter Y. Solmssen; Registered offices: Berlin and Munich, Germany; 
Commercial registries: Berlin Charlottenburg, HRB 12300, Munich, HRB 6684; 
WEEE-Reg.-No. DE 23691322 
 
 
Attachment:
project.JPG
Description: project.JPG