This is the mail archive of the
java@gcc.gnu.org
mailing list for the Java project.
Re: Fwd: Resources in natively compiled executables
- From: Anthony Green <green at redhat dot com>
- To: Chris Burdess <dog at bluezoo dot org>
- Cc: java at gcc dot gnu dot org
- Date: Thu, 15 Apr 2004 07:49:56 -0700
- Subject: Re: Fwd: Resources in natively compiled executables
- Organization: Red Hat, Inc.
- References: <260A3553-8EE5-11D8-BDB8-000D934FF4B2@bluezoo.org>
On Thu, 2004-04-15 at 06:59, Chris Burdess wrote:
> > If I just compile my jar to native directly, i.e.:
> >
> > # gcj -c -o activation.o activation.jar
> >
> > this works normally. If instead I try:
> >
> > # gcj -c --resource META-INF/mailcap.default --resource
> > META-INF/mimetypes.default -o activation.o activation.jar
> >
> > then it completes with no error but:
The documentation says that you can't specify multiple input files when
using --resource (or -C). You'll need to compile those resource files
into multiple .o files. Even then, it's not clear what you're trying to
do.
This command...
$ gcj -c --resource RESOURCENAME FILENAME -o OBJECTNAME
...will compile FILENAME into OBJECTNAME. The contents of FILENAME
will be available at runtime by reading from the URL
core:/RESOURCENAME. We put core:/ automatically at the end of the
classpath, so methods like ResourceBundle.getBundle(RESOURCENAME) will
magically work.
AG
--
Anthony Green <green@redhat.com>
Red Hat, Inc.