Hi,
create New S32DS Library project for target MCU, add library source code into project and compile it - the very same procedure as an executable project, but the output is library archive:

To be honest, I never try to link .lib file, but technically it should be okay.
Anyway - what is your goal?
Jiri