Re: GCJ Compile Error SQLite JDBC

Taufik Chowi <[email protected]>
Newsgroups gmane.comp.gcc.java.devel
Message-ID <[email protected]>
Dear Nektarios,

Thanks for the information. I have one question in your built, is that sqlitejdbc-v044-native.jar can be used in windows box?
i mean, i am not sure, generally if you make native using linux , that means it will generate a native for linux right?
i know in gcj there is something called cross native compiler or something along that line that allow gcj to compile for specific operating system native executable from any linux os, but i dont know if the "make native" can do that or not >.<

my java program need to run well on both Windows and Linux operating system (thanks to everyone, right now, i know for sure it will run well on Linux OS)


again thanks a lot, finally i can see that my java program can definitely be compiled and working with a very powerful serverless database :)


Cheers,


Chowi




----- Original Message ----
From: Nektarios K. Papadopoulos <[email protected]>
To: Taufik Chowi <[email protected]>
Cc: Marco Trudel <[email protected]>; [email protected]
Sent: Tuesday, September 23, 2008 6:14:53 PM
Subject: Re: GCJ Compile Error SQLite JDBC

On 2008-09-23 13:18, Taufik Chowi wrote:
> Dear Marco,
> 
> Oh really?
> ok thanks a lot for the information.
> i will try to find the "build option" that used JNI to access native compiled sqlite library.
> 
> 

I used sqlitejdbc-v044. The build option is:

make native

You get:
build/sqlitejdbc-v044-native.jar
build/Default-i686/libsqlitejdbc.so

I then used a sample class using sqlite jdbc, compiled to .class and used gcj 
like this:

gcj -o myTest -findirect-dispatch -fjni --main=mypackage.myTest 
sqlitejdbc-v044-native.jar mypackage/myTest.class

BTW,
gcj --version
gcj (GCC) 4.2.3 (Ubuntu 4.2.3-2ubuntu6)

Cheers

-- 
Nektarios K. Papadopoulos
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.