-Ur option documentation

Nick Clifton nickc@redhat.com
Wed May 10 10:59:33 GMT 2023


Hi Guys,

OK, how about this rewording of the option's description:

   For programs that do not use constructors or destructors,
   or ELF based systems that use the newer SHT_INIT_ARRY
   section type this option is equivalent to -r: it generates
   relocatable output -- i.e., an output file that can in turn
   serve as input to ld.  For qualifying binaries however the
   -Ur option is different in that it *does* resolve
   references to constructors, unlike -r.

   It does not work to use -Ur on files that were themselves
   linked with -Ur; once the constructor table has been built,
   it cannot be added to.  Use -Ur only for the last partial
   link, and -r for the others.

Cheers
   Nick



More information about the Binutils mailing list