RFC and PATCH - Defining variables in the linker script without defining them as symbols on the file

Zack Weinberg zack@codesourcery.com
Thu Jul 8 17:04:00 GMT 2004


Guilherme Destefani <gd@helixbrasil.com.br> writes:

> This patch add to the linker a command like PROVIDE(var=value), named
> TEMPORARY(var=value) that can be used to define variables just for
> temporary use, so those variables won't be sent to the file as a symbol.

Ooh, nifty.  Would you please investigate adding the ability to set
these variables from the command line?  The desired semantic is that
TEMPORARY(var=value) gets overriden by --some-switch var=value, but
whether or not that happens, /var/ is available for calculation in
the linker script.  (--defsym symbols can't be used for arbitrary
calculation.)

zw



More information about the Binutils mailing list