here seems to be quite a lot of stuff to be implemented. But I think that JNI 1.2 could ease the work in getting a newer classpath to run.
lördag 31 juli 2010
JNI 1.2
When looking at supporting JNI 1.2, this document proved valuable: http://download-llnw.oracle.com/javase/1.4.2/docs/guide/jni/jni-12.html
måndag 19 juli 2010
Native implementations
Now work has been focused on writing mising native stuff to work with GNU Classpath.
I am trying to run HelloWorld using Classpath 0.93 and also 0.98, and catching any unimplemented methods along the way. It is kind of tedious, and the javah-util could really help me out. Classpath 0.98 works equally well as 0.93 -- which doesn't tell us much -- but work with 0.98 might be upped on the priority list, possibly avoiding 0.93 bugs.
I have also updated the wiki-page on Classpath development, and can happily see the atleast one method has turned from red to green! Noteworthy is that not all red methods have been found yet, and a few of the ones in gnu.java.nio (file handling stuff), might already be implemented.
I have also received some JAmiga work from another developer which I'm currently merging with the other stuff; there were a few speed improvements and such (Thank you Thore, I hope you join the project).
onsdag 14 juli 2010
JNI 1.2.. and other thoughts
JAmiga support JNI 1.1.
Ofcourse, the latest is the way to go. Looked at java.sun.com and looked through teh document on JNI functions. It seems rather straightforward to implement the functions in jnienv.c|h.
My latest entry was about javah, and it may seem like I'm jumping between different things to do in JAmiga, but:
a) the javah-util's aim is to help implement the missing JNI methods of GNU CP 0.95
b) JNI 1.2 works differently, and I might get away without my own javah-util
So... I'm thinking that JNI 1.2 is a highet priority.
But then again, I have been looking at JamVM. I have implemented a few thread stuff in it for AmigaOS, but there are some strange reloc issues when I run the binary. So, I am a bit stumped. And I think that work on Amiga specific Classpath JNI stuff, could be used with JamVM, which I think would perhaps be a safer way, since JamVM, a) is being actively developed, b) has Java 6&7 in the works, and c) is actually working ann being used.
So. I really don't know what to do. JAmiga is a nice project, and it has potential, but it huge task to maintain it, and get it working. Other things talking *for* JAmiga is support for MorphOS, Aros, AOS3 and AOS4. But I think JamVM could be made working for those aswell.
Ofcourse, the latest is the way to go. Looked at java.sun.com and looked through teh document on JNI functions. It seems rather straightforward to implement the functions in jnienv.c|h.
My latest entry was about javah, and it may seem like I'm jumping between different things to do in JAmiga, but:
a) the javah-util's aim is to help implement the missing JNI methods of GNU CP 0.95
b) JNI 1.2 works differently, and I might get away without my own javah-util
So... I'm thinking that JNI 1.2 is a highet priority.
But then again, I have been looking at JamVM. I have implemented a few thread stuff in it for AmigaOS, but there are some strange reloc issues when I run the binary. So, I am a bit stumped. And I think that work on Amiga specific Classpath JNI stuff, could be used with JamVM, which I think would perhaps be a safer way, since JamVM, a) is being actively developed, b) has Java 6&7 in the works, and c) is actually working ann being used.
So. I really don't know what to do. JAmiga is a nice project, and it has potential, but it huge task to maintain it, and get it working. Other things talking *for* JAmiga is support for MorphOS, Aros, AOS3 and AOS4. But I think JamVM could be made working for those aswell.
onsdag 7 juli 2010
Say after me: javahhh
Yes, one month after the previous blog. Though I have been doing some work on JAmiga, it hasn't been much. The summer with its sun is here, which puts me outside with a glass of rosé wine.
Anyhow, the work I have made consist of a lite-javah-util. Javah comes with the Java SDK and it creates C-header files for the JNI, for native methods in java classes. I have been using the one on my Ubuntu linux machine, but since it only produces the header files, I still have to do a lot of typing (I believen there were version of javah that also produces skeleton c-source, but I haven't found it anywhere). Basically, my javah-lite (should) produce both header and c-file, with empty skeleton JNI functions, from the java source. The comments from the Java-source should be available, which the original javah does not, so one doesn't need to look at the Javadoc all the time. The JNI stuff should do nothing, but I should be able to run JAmiga with GNU classpath 0.95 (for instance) and make it crash, or hopefully complain about unimplemented methods. When I manage to do this, it is just a matter of going through the JNI code, and implementing the functions.
So, progress is as always slow.
Prenumerera på:
Inlägg (Atom)