This comes up a lot, I'll add this to the CE FAQ. If you're building a _library_: * If you're not using XDC's package.bld-based build, you'll have to explicitly define your 'target' via the -Dxdc_target__=<something> option. * If you're using XDC's package.bld-based build, the appropriate xdc_target__ will be defined for you.
If you're building an _executable_, you should run the config step prior to building your application. * If you're not using package.bld to build your app, you'll use "configuro" to configure your app - which will generate a compiler.opt file you should 'cat' into your CFLAGS (this will include the -Dxdc_target__=<something> define). (The CE Examples include a configuro example makefile which does this - likely in examples/ti/sdo/ce/examples/video_copy/*, but may vary based on your CE version.) * If you're using package.bld, similar to the lib build, this happens for free. This all stems from <xdc/std.h>'s extensibility support; the late binding to a 'target' via the -D option lets both your .c code and <xdc/std.h> remain unchanged, and yet system integrators can integrate new 'targets' that neither your .c files nor <xdc/std.h> have seen into the system. Some more background docs: * http://rtsc.eclipse.org/docs-tip/Consuming_Configurable_Content * http://wiki.davincidsp.com/index.php/StdDotH Chris > -----Original Message----- > From: > [email protected] > p.com > [mailto:[email protected] > avincidsp.com] On Behalf Of Ottavio Campana > Sent: Tuesday, June 16, 2009 1:01 AM > To: [email protected] > Subject: problem including xdc/std.h > > I am following the codec engine application developer > user's guide to > develop a custom application using TI h264 HD encoder. > > The first required step is to > > #include <xdc/std.h> > > But when I do it and try to compile I get > > ../../xdc/std.h:128: error: expected specifier-qualifier-list > before 'xdc_IArg' > ../../xdc/std.h:131: error: expected '=', ',', ';', 'asm' or > '__attribute__' before 'xdc_floatToArg' > ../../xdc/std.h:139: error: expected ')' before 'a' > ../../xdc/std.h:181: error: expected '=', ',', ';', 'asm' or > '__attribute__' before 'IArg' > ../../xdc/std.h:182: error: expected '=', ',', ';', 'asm' or > '__attribute__' before 'UArg' > ../../xdc/std.h:184: error: expected '=', ',', ';', 'asm' or > '__attribute__' before 'Int8' > ../../xdc/std.h:185: error: expected '=', ',', ';', 'asm' or > '__attribute__' before 'Int16' > ../../xdc/std.h:186: error: expected '=', ',', ';', 'asm' or > '__attribute__' before 'Int32' > ../../xdc/std.h:191: error: expected '=', ',', ';', 'asm' or > '__attribute__' before 'UInt8' > ../../xdc/std.h:192: error: expected '=', ',', ';', 'asm' or > '__attribute__' before 'UInt16' > ../../xdc/std.h:193: error: expected '=', ',', ';', 'asm' or > '__attribute__' before 'UInt32' > ../../xdc/std.h:204: error: expected '=', ',', ';', 'asm' or > '__attribute__' before 'Uint8' > ../../xdc/std.h:205: error: expected '=', ',', ';', 'asm' or > '__attribute__' before 'Uint16' > ../../xdc/std.h:206: error: expected '=', ',', ';', 'asm' or > '__attribute__' before 'Uint32' > > By reading xdc/std.h, it seems that the file is wrong > because the order > of declarations is incorrect. > > There must be something really stupid that I'm missing, but I cannot > find it. > > -- > Non c'è più forza nella normalità, c'è solo monotonia. > > _______________________________________________ > Davinci-linux-open-source mailing list > [email protected] > http://linux.davincidsp.com/mailman/listinfo/davinci-linux-open-source > _______________________________________________ Davinci-linux-open-source mailing list [email protected] http://linux.davincidsp.com/mailman/listinfo/davinci-linux-open-source
