This is the mail archive of the
java@gcc.gnu.org
mailing list for the Java project.
How to use jdbc?
- To: java at gcc dot gnu dot org
- Subject: How to use jdbc?
- From: Adrian Custer <acuster at nature dot berkeley dot edu>
- Date: 27 Jul 2001 21:13:49 -0700
Hey everyone,
I'm trying out jdbc. I finally got the program working using sun's java
but I don't like it, I'd rather be Free. :-)
I have a program (attached). When I do the following:
1) setenv PATH /usr/local/gcc3_0/bin:$PATH
setenv LD_LIBRARY_PATH /usr/local/gcc3_0/lib/
2) gcj --main=DatabaseTester.java -o DatabaseTester DatabaseTester.java
I get:
/home/acuster/tmp/ccuuonhUmain%O: In function `main':
/home/acuster/tmp/ccafMTcVmain.i(.text+0x1a): undefined reference to
`DatabaseTester::java::class$'
collect2: ld returned 1 exit status
I tried copying the postgres .jar file into /usr/local/gcc3_0/share/lib/
but that didn't help. I tried a bunch of other stuff. If anyone has a
good example of how one can set up the compiler, userProgramme, Database
to get them working together, please let me know.
Thanks for any info,
adrian
acuster@nature.berkeley.educational