Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

We need the syntax -l:filename in order to support arbitrary file names for shared libraries, at least for RTEMS, see below. I list the Intel linkers here in case someone wants to try, for example, a quick test of new linker script techniques without setting up the cross-compilation environment.

Summary of ld options

If given to a compiler driver instead of directly to ld some of these options need to be prefaced with "-Wl,". However a series of options can be given following a signle preface, e.g., "-Wl,-soname=foo,--hash-style-gnu,-zcombreloc".

OptionNeeds -Wl,
-shared 
-fpic or -fPIC 
-e (optional) 
-soname(tick)
--as-needed(tick)
--no-add-needed(tick)
-zcombreloc(tick)
--zmax-page-size=4K(tick)
--hash-style=gnu(tick)
-l: (instead of -l) 

 

File names, sonames and the needed list

...