Skip to main content



      Home
Home » Archived » DSDP - Real-Time Software Components (RTSC) » How to add pre-built library to RTSC-ed one ?
How to add pre-built library to RTSC-ed one ? [message #778546] Fri, 13 January 2012 03:23 Go to next message
Eclipse UserFriend
Hello,

In the config.bld, we can add C source objects to RTSC-ed library.

var Build = xdc.useModule('xdc.bld.BuildEnvironment');
var Pkg = xdc.useModule('xdc.bld.PackageContents');
 
/* ---- what to build ---- */
 
for each (var targ in Build.targets) {
    Pkg.addLibrary("lib/isqrt_loop", targ).addObjects(["isqrt_loop.c"]);
}


With such a script, the C sources are compiled and then added to RTSC library appropriately.

Now, I would like to know how to add pre-built library to RTSC library.
In this case, how can I add "pre-built.lib" to isqrt_loop.lib ?

Best Regards,
Kawada
Re: How to add pre-built library to RTSC-ed one ? [message #778741 is a reply to message #778546] Fri, 13 January 2012 13:34 Go to previous messageGo to next message
Eclipse UserFriend
Kawada,
each package can supply multiple libraries when being used in a configuration. It's done through the function getLibs, which is implemented in package.xs. In many cases, a package does not implement getLibs because the default implementation can handle the most common case with only one library per package.
Here is a guide for adding getLibs in cases where a package has only pre-built libraries, which is not exactly the same as your case, but the guide should help you write your getLibs.
There is another user guide for writing getLibs, which mostly deals with the cases where your package supports multiple targets and can possibly be invoked for build targets that your package does not support.
Re: How to add pre-built library to RTSC-ed one ? [message #778963 is a reply to message #778741] Sat, 14 January 2012 03:37 Go to previous message
Eclipse UserFriend
Hello Sasha,

Thanks for the quick response ! I got it. Making RTSC package for pre-built lib, and using "require" keyword for it in wrapper package would solve my issue.

Best Regards,
Kawada

Previous Topic:new XML(...) error
Next Topic:xdc -j4
Goto Forum:
  


Current Time: Sun May 11 17:20:49 EDT 2025

Powered by FUDForum. Page generated in 0.03220 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top