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> //    private static Class _c = gnu.java.locale.Calendar.class;

Martin> (after uncommenting the Class-statement)

Martin> Is there a difference between building .java->.o and
Martin> .java->.class->.o?

Yes.  There is no way to directly represent "foo.class" in Java
bytecode.  Instead Java compilers generate a synthetic method that
uses Class.forName() to find the class.  This means that when you
compile the .class to .o, you no longer have a direct reference to the
symbol.

I don't think you said what platform you're on.  If you can I highly
recommend using dynamic linking instead of static linking.  That will
fix all these difficulties.

Tom


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