Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [cdt-dev] Re: outputType of tool is .c file

> 1. The generated output (.c) file is stored in the
>    <project_dir>/<config_dir> directory, which, in my case is:
>    "testbool/Debug"
> 2. The relevant tool settings are as follows:
>     (a) Tool that generates .c file as output
>     <outputType
>           buildVariable="PSM_FILE"
>           id="cradle.toolchain.boolgenerator.output"
>           name="Bool output"
>           outputNames="psm_%.c"/>
>     (b) Tool (C compiler) that accepts .c files as input
>     <inputType
>       buildVariable="C_SRCS"
>       dependencyCalculator="org.eclipse.cdt.managedbuilder.makegen.gnu.DefaultGCCDependencyCalculator"
>       dependencyContentType="org.eclipse.cdt.core.cHeader"
>       dependencyExtensions="h"
>       sources="c,C">
>     </inputType>
> Still, the .c file gets compiled.
> Is there anything additional for the tool attributes?


I think the problem is the fact that the output extension of your 'psm'
tool is defined to be .c, which probably results in the 'psm_%' file ending
up in the objects list (you can check this in the files). You
could trick the makefile generator by using a different (dummy) extension
for your 'psm' tool. Then to get some dependency on your 'psm' file you
could add an extra inputType to the linker tool using the dummy extension
and buildVariable="PSM_FILE". Using some 'sed' magic to get the tool
commands right might do the trick.

Or you could go with the earlier suggestion to use your own makefile
generator, in which case you have full control over extension handling...


Back to the top