This is the mail archive of the java@gcc.gnu.org mailing list for the Java project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: How to overcome MissingResourceException (gnu.java.locale.Calendar)


>>>>> "Martin" == Martin Egholm Nielsen <martin@egholm-nielsen.dk> writes:

Martin> However, since I'd like to have my source compatible with Sun's/IBM's
Martin> compiler, I hope there is a way to overcome the need for the explicit
Martin> class-reference?

Martin> but I don't quite understand how this "-u" parameter works.

>From the `ld' documentation:

`-u SYMBOL'
`--undefined=SYMBOL'
     Force SYMBOL to be entered in the output file as an undefined
     symbol.  Doing this may, for example, trigger linking of additional
     modules from standard libraries.  `-u' may be repeated with
     different option arguments to enter additional undefined symbols.
     This option is equivalent to the `EXTERN' linker script command.


The trick is to find the correct mangling of some symbol that is
defined by the class you want to link in.  Usually we recommend using
the _CD_ symbol, as that corresponds to the class object.  One way to
find this is to compile your main program with the explicit class
reference, then use nm to find the symbol name, then remove the
reference from your program.

Tom


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]