public inbox for java@gcc.gnu.org
 help / color / mirror / Atom feed
From: <stephen@mombasa.anthro.utah.edu>
To: java-discuss@sourceware.cygnus.com
Subject: Compilation/ld problem
Date: Sat, 01 Apr 2000 00:00:00 -0000	[thread overview]
Message-ID: <Pine.LNX.4.10.10001302221540.12502-100000@mombasa.anthro.utah.edu> (raw)

Short version: 
	Compilation fails on a simple  program that uses
	BigIntegers.

I am using RedHat 6.0, out of the box, and I installed gcc with
the following RPMs from rufus.w3.org:

gcc-2.95.2-3.i386.rpm
gcc-java-2.95.2-3.i386.rpm
gcc-libgcj-2.95.2-3.i386.rpm
cpp-2.95.2-3.i386.rpm
binutils-2.9.5.0.22-4.i386.rpm

---> My BigInteger Hello World looks like this:

cut->--------
	import java.math.BigInteger;

	public class Hello {
	    public static void main(String[] args) {
		BigInteger test_integer = new BigInteger("1");

		System.out.println("Hello World!");
	  }
	}
cut->--------

	When I compile it like this:
		gcj -c Hello.java
		gcj --main=Hello -o Hello Hello.o
	I get the following errors:

Hello.o: In function `Hello::main(JArray<java::lang::String *> *)':
/home/stephen/bin/src/Java/Mars_II/Mars_II_New/Hello.java:5: undefined
reference to `_CL_Q34java4math10BigInteger'
/home/stephen/bin/src/Java/Mars_II/Mars_II_New/Hello.java:5: undefined
reference to `java::math::BigInteger::BigInteger(java::lang::String *)'
collect2: ld returned 1 exit status

	Is there a way to fix this?

Thanks,
Steve

             reply	other threads:[~2000-04-01  0:00 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2000-04-01  0:00 stephen [this message]
2000-04-01  0:00 ` Anthony Green

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=Pine.LNX.4.10.10001302221540.12502-100000@mombasa.anthro.utah.edu \
    --to=stephen@mombasa.anthro.utah.edu \
    --cc=java-discuss@sourceware.cygnus.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).