define linker section for entire file

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

define linker section for entire file

Jump to solution
1,240 Views
shanescott
Contributor III

Using "__attribute__"  I am able to locate a function in a particular linker section.  This is ok sometimes but for large files it becomes tedious.  Is there a way to specify a section for the entire file?

Thanks 

0 Kudos
Reply
1 Solution
1,082 Views
BlackNight
NXP Employee
NXP Employee

Not to specify a section for the file, but you can use the object file name in the linker file as shown in

Putting Code of Files into Special Section with the GNU Linker | MCU on Eclipse 

I hope this helps,

Erich

View solution in original post

2 Replies
1,082 Views
shanescott
Contributor III

Perfect! Thanks

0 Kudos
Reply
1,083 Views
BlackNight
NXP Employee
NXP Employee

Not to specify a section for the file, but you can use the object file name in the linker file as shown in

Putting Code of Files into Special Section with the GNU Linker | MCU on Eclipse 

I hope this helps,

Erich