This is the mail archive of the
java@gcc.gnu.org
mailing list for the Java project.
Linking question
- From: Mark Anderson <mark at panonet dot net>
- To: java at gcc dot gnu dot org
- Date: Mon, 21 Oct 2002 14:10:33 +0100
- Subject: Linking question
I have just started using gcj and I am trying to compile some code into native
form. This code relies on other code found in JAR files which I have
specified using -I.
An example of the command I am using is given below along with its output:
gcj --main=LinkTest -Iutil_jar.jar -o LinkTest LinkTest.java
/tmp/ccigNOif.o: In function `LinkTest::main(JArray<java::lang::String*>*)':
/tmp/ccigNOif.o(.text+0x44): undefined reference to
`com::ravnaandtines::util::text::Hexprint::fmt(int)'
collect2: ld returned 1 exit status
I understand that the error is being caused because the com....Hexprint class
is not availble in a library as native code. However, I thought that with gcj
you could mix native and bytecodes.
Therefore, my question is do I need to compile the JAR file to native code or
is there any way I can create my binary without doing this?
--
Regards,
Mark