cancel
Showing results for 
Search instead for 
Did you mean: 

Library files

ssk
Associate II
Posted on January 07, 2016 at 11:18

I want to generate library files for my C modules. E.g. I have a C module for timer with functions for initialization, configuration, start and stop. I want to generate a library module which I can use in SPC5Studio project and call the required API from other C modules. Is it possible with SPC5Studio?

Can I build C module to generate library files?

Thanks.

Mike
2 REPLIES 2
Erwan YVIN
ST Employee
Posted on January 07, 2016 at 16:12

Hello Mike ,

You should create an alternate project for this :

Script and Makefile

1) generate your .o files by an other makefile

2) ppc-free-vle-ar ruv yourlib.a *.o 

   or ppc-cle-ar ruv yourlib.a *.o 

In your application :

3) Update user.mak file

# Define ASM defines here

UADEFS      =

# List all user directories here

UINCDIR     =

# List the user directory to look for the libraries here

ULIBDIR     =

# List all user libraries here

ULIBS       =

   Best regards

                  Erwan

ssk
Associate II
Posted on January 15, 2016 at 10:43

Thanks Erwan. I shall look into building the library files.

Best Regards,

Mike