Programmable Devices
CPLDs, FPGAs, SoC FPGAs, Configuration, and Transceivers
20703 Discussions

How to build object libraries and assembly Macro-Instructions libraries?

Altera_Forum
Honored Contributor II
1,688 Views

For bare-metal application I need to build libraries of object files and libraries of assembly macro-instruction. 

I look for information in documentations but I could not find anything. 

Thanks for your help. 

Kind regards 

Jerome
0 Kudos
3 Replies
Altera_Forum
Honored Contributor II
583 Views

Hi Jerome,  

Go through the online training. 

https://www.altera.com/support/training/course/osocbarehwlib.html 

 

Kindly refer to the link below  

https://www.altera.com/content/dam/altera-www/global/en_us/pdfs/literature/ug/ug_bm.pdf  

 

It is probably helpful as you might be hoping.  

Thanks.
0 Kudos
Altera_Forum
Honored Contributor II
583 Views

Hello, 

Thanks a lot for your fast reply. 

The online training courses cab help me a lot. 

Today I’ve already created a start project with GCC compiler and ARM compiler. 

I saw the HwLib in the following directory: 

C:\intelFPGA_pro\18.0\embedded\ip\altera\hps\altera_hps\hwlib\include\hwlib.h 

 

These libraries are made for c language and I suppose I will have to redistribute it in binary form. 

But my question was different; I need to build my own macro-instructions libraries using an archived library (BFD ar-compatible for example). It seems that is possible with the GNU compiler but not with ARM compiler. 

My question was; how to create an archived library of macro-instructions with the tools DS-5 AE. This library will be loaded by the .mlib directive of GNU assembler (for example). 

Thanks for your help 

Jerome
0 Kudos
Altera_Forum
Honored Contributor II
583 Views

To create a new object library it necessary tu use ARMAR tools : 

 

https://developer.arm.com/docs/dui0476/g/creating-libraries/creating-a-new-object-library 

 

Once the library is made it's necessary to declare it in project property --> setting-->ARM Linker --> Libraries --> User libraries files. 

 

Jerome
0 Kudos
Reply