Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [cdt-dev] Programmatic creating of custom toolchains

Hi Caroline,
I am pretty skeptical about that. It looks to me that current MBS toolchain is not intended to be created programmatically from outside. The design was for it to be "easily" created from plugin.xml markup. ToolChain class is internal and IToolChain interface is marked with @noextend @noimplement. AFAICS, there are some other indications in the code. If I were to implement or modify it from outside plugin I'd brace for a few of difficult issues to solve. 

What is the reason to switch providers (/options) programmatically on toolchain level? Perhaps the logic could be implemented inside the provider?

Thanks,
Andrew

On Fri, Nov 23, 2012 at 6:36 AM, Rieder, Caroline <caroline.rieder@xxxxxxxxxxxxx> wrote:

Hi all,

 

I am trying to programmatically create a toolchain with corresponding tools.

I saw that multiple parts of such a toolchain are only available via internal API.

 

What I am missing:

 

How can I programmatically define the language settings providers for a toolchain?

ToolChain provides getDefaultLanguageSettingsProviderIds() but there is no API to set such providers for a created toolchain.

 

So how could I implement this to get the same results as when defined within plugin.xml like this?

 

  <toolChain

        archList="all"

        id="com.windriver.cdt.core.WRGnuToolChain"

        languageSettingsProviders="com.windriver.cdt.core.project.WRGnuBuiltinSpecsDetector"

        name="WR Gnu Tool Chain"

        supportsManagedBuild="false">

 

How can I add a tool option to get the same as when defining within plugin.xml like this? I could only find

 

        <option

              browseType="directory"

              id="com.windriver.cdt.core.gnu.c.settings.holder.incpaths"

              name="Include Paths"

              command="-I"

              valueType="includePath">

        </option>

 

Could somebody please give me a hint on how to accomplish this (if possible by using as little internal CDT code as possible)?

 

Thanks in advance!!

 

Best regards,

Caroline

 

Caroline Rieder | Wind River | Senior Engineer
Tel +43 662 457915 56

 


_______________________________________________
cdt-dev mailing list
cdt-dev@xxxxxxxxxxx
https://dev.eclipse.org/mailman/listinfo/cdt-dev



Back to the top