/var/www/restricted/ssh/stm32/www/stm32circle/ STM CircleOS forum / add_to_circle multiple fils

Username:     
Password:     
             

Forum

# 1   2009-06-22 06:03:42 add_to_circle multiple fils

semsem
New member
Registered: 2009-04-01
Posts: 6

add_to_circle multiple fils

Hi,
if i have a project made of multiple files, how can i produce a final output to use add_to_circle to add it? I read that add_to_circle only adds  *.o and *.Lib. does this mean that i have to build a library? is there any other way.
when i'm building a library it is not linking only compiling. i have some sprintf which the linker later complain (when i try to use add_to_circle)  that there is some dependencies he can't resolve. how can i fix that.

Thanks

Offline

 

# 2   2009-06-23 10:08:57 add_to_circle multiple fils

VincentC
Administrator
Registered: 2007-11-08
Posts: 149

Re: add_to_circle multiple fils

Hi,

Yes, you must provide Circle_Mgr.exe with either a .o or a .lib file.

In a future release we will rework the way this is done, because for now it can be quite tricky, especially when the application uses things like malloc or sprintf, which is your case.

In the meantime the best thing to do for you is to include the sources of the small printf library, and also the syscalls.c file from the IO_putchar library, directly in your library. You can find all these sources in your <Ride>\lib\ARM directory and its subdirectories.

Be careful that the files in your lib that are called by other files in your lib should be placed after them, as the gcc linker is a one-pass linker, and the calling functions must be analyzed before the called functions. Basically, place the file containing sprintf after your own files, and place the syscalls.c file last.

I hope it helps.

Best Regards,

Vincent

Offline

 

Board footer