This is the mail archive of the
java-patches@gcc.gnu.org
mailing list for the Java project.
Re: Java runtime patch: compile resource files into executables
- To: "Per Bothner" <per at bothner dot com>
- Subject: Re: Java runtime patch: compile resource files into executables
- From: "Anthony Green" <green at redhat dot com>
- Date: Sun, 2 Sep 2001 20:25:00 -0700
- Cc: <gcc-patches at gcc dot gnu dot org>, <java-patches at gcc dot gnu dot org>
- References: <200109030108.SAA02067@fencer.cygnus.com> <m2itf1rn7h.fsf@eureka.bothner.com>
Per wrote:
> Note that we also want to be able to add resource files to shared
> libraries.
Yes, this works. I tried it with gnu.regexp which I've built into
lib-gnu-regexp.so. The Makefile includes...
props.o: $(srcdir)/upstream/src/gnu/regexp/MessagesBundle.properties
gcj -fPIC -R gnu/regexp/MessagesBundle.properties -o props.o -c $<
..and the runtime has no problem finding this.
> Some of these shared libraries will be associated with
> their own classloaders, and in that case the name of the resource
> is local to the classloader. (I'm referring to my SharedLibLoader
> class, which I need to check in!)
I see. Right now I've got a global list of core files. I suppose there
should eventually be a chain per classloader. I can make this change once you
check your changes in (but I'd prefer not to wait).
> +typedef struct core_chain_struct
> +{
> + int name_length;
> + char *name;
> + int data_length;
> + char *data;
>
> Should this be:
>
> jint name_length;
> const char *name;
> jint data_length;
> const void *data;
The jint change isn't necessary, but I can make the other changes.
AG