Linux port of JNI Shared Stubs Examples
Hi,
For those of you who's familiar with Sheng Liang's JNI book, you might
find the attached file interesting. It is my attempt at porting the JNI
Shared Stubs Examples to Linux/x86. Could someone please tested it out
and see if it works ("It worked on my machine(TM)").
I did this to learn the internals of JNI and to try to make some of the
native services available to Java. One thing I would really liked would
be a wrapper around GNU readline library, so that I can add command line
editing to some of the fine tools available over the Internet (such as
the Rhino JavaScript interpreter from Mozilla.org).
I hope this is useful to at least one other person. But if it is not,
that's OK too. :)
README.linux:
=
This is a Linux/x86 port of the Shared Stubs JNI Examples by Sheng
Liang,
available from the http://java.sun.com/products/jdk/faq/jnifaq.html
page, in
files jnistb10.zip, jnistb10.tar.Z or jnistb10.tar.gz.
I added the file dispatch_i386-pc-linux-gnu.s, which is a port of
dispatch_sparc.s to Linux/x86/gas.
The code in dispatch.c and Main.java is aware of Linux now.
The script in makefile.unix is aware of the Linux/x86 port now.
Nothing else is changed. I have tested this port on Red Hat 6.1 (kernel
version 2.2.12-20, glibc version 2.1.2-11) with IBM JDK 1.1.8,
Sun/Inprise JDK
1.2.2 RC1 and RC2, Blackdown JDK 1.2.2 RC2/RC3.
LICENSE --- I'm not going to be bothered with a license for 73 lines of
code.
Treat the dispatch_i386-pc-linux-gnu.s as if it were posted on a mailing
list.
--
Weiqi Gao
[EMAIL PROTECTED]
jnistb-1.0.tar.gz
Re: Threads
[EMAIL PROTECTED] wrote: > > Hello, > I'm using JDK1.2.2 and Suze6.2. > Can someone tell me how I can use the option "green threads" of VM instead > "native threads"? You can either specify it with the command that runs the JVM: java -green ... or set it in the environment: export THREADS_FLAG=green java ... Nathan > Thank You. > Daniel FONTAINE > Université de Versailles Saint-QUENTIN en Yvelines > FRANCE > [EMAIL PROTECTED] > > -- > To UNSUBSCRIBE, email to [EMAIL PROTECTED] > with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED] -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
RC4
Blackdown 1.2.2 RC4 is up on ftp.tux.org: ftp://ftp.tux.org/java/JDK-1.2.2/i386/rc4 -Peter http://armedbear.org -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: RC4
Peter Graves wrote: > > Blackdown 1.2.2 RC4 is up on ftp.tux.org: > > ftp://ftp.tux.org/java/JDK-1.2.2/i386/rc4 > Also in that directory: the debut of the JDK1.2 Java plug-in for Netscape! Nathan > -Peter > http://armedbear.org > > -- > To UNSUBSCRIBE, email to [EMAIL PROTECTED] > with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED] -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: RC4
Sparclinux too. Karl Peter Graves <[EMAIL PROTECTED]> writes: > Blackdown 1.2.2 RC4 is up on ftp.tux.org: > > ftp://ftp.tux.org/java/JDK-1.2.2/i386/rc4 > > -Peter > http://armedbear.org > > > -- > To UNSUBSCRIBE, email to [EMAIL PROTECTED] > with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED] -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
problems with JIT in RC4
Hi, I've installed RC4 on my potato box today and noticed that CPU intensive applets slowed down to a crawl. For example, one of them was eating about 14% of CPU time in RC3 with sunwjit active and now it eats 100%. In fact it looks like switching JIT _off_ in RC4 gives me more speed!? Anyone can confirm this? Regards, Milek -- mailto:[EMAIL PROTECTED] | "Man in the Moon and other weird things" - http://wfmh.org.pl/~thorgal/ | see it at http://wfmh.org.pl/~thorgal/Moon/ -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: RC4 - what it is about?
Is it simply bug fixing release? Jacob Nikom Nathan Meyers wrote: > > Peter Graves wrote: > > > > Blackdown 1.2.2 RC4 is up on ftp.tux.org: > > > > ftp://ftp.tux.org/java/JDK-1.2.2/i386/rc4 > > > > Also in that directory: the debut of the JDK1.2 Java plug-in for > Netscape! > > Nathan > > > -Peter > > http://armedbear.org > > > > -- > > To UNSUBSCRIBE, email to [EMAIL PROTECTED] > > with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED] > > -- > To UNSUBSCRIBE, email to [EMAIL PROTECTED] > with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED] -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
information to get started
hello Ive been planning on learning java development for a couple weeks now and im getting pretty sick of just sitting around -- id like to get started :P I picked up Just Java 2 from Sun and Pure Java 2 from Sams..both of which, IMO, werent very good books at all. Just Java trys to explain the terms in such a simplified manner, you completely miss the point, while Pure Java is way advanced for where im at right now. Maybe itll be usefull later on. Where is there good documentation or even online books on the internet for learning Java? I hear Thinking in Java is good, but is it up to date on Java2? I have to go online/free style now considering Ive spent too much on books and other computer-related stuff, my budget is too low for it right now. Also, I downloaded JBuilder for Linux, but it seems like it would spoil me in means of actually learning the language..the VB-style method for the swing apps is an example.. Are there any decend devel environments for Java? or am i better off going the joe/jed/vi route? Thanks for your time = Joe Topjian [EMAIL PROTECTED] http://auximini.cjb.net Even a stopped clock gives the right time twice a day __ Do You Yahoo!? Talk to your friends online with Yahoo! Messenger. http://im.yahoo.com -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: RC4 - what it is about?
Jacob Nikom wrote: > > Is it simply bug fixing release? At least... but there are some important breakthroughs. A look at the README shows that some longstanding problems have been addressed: - The "incompatible raster" problems have been fixed, allowing Swing/AWT apps to run on many more X servers. Also fixed is the problem preventing use with X servers with non-native byte order. - The Java Platform Debugging Architecture is now present (back-ported from JDK1.3), as is a new graphical debugger. If everything works, it might even put the Inprise JDK port out of business :-). - More problems with native thread and green thread robustness have been addressed. Nathan > > Jacob Nikom > > Nathan Meyers wrote: > > > > Peter Graves wrote: > > > > > > Blackdown 1.2.2 RC4 is up on ftp.tux.org: > > > > > > ftp://ftp.tux.org/java/JDK-1.2.2/i386/rc4 > > > > > > > Also in that directory: the debut of the JDK1.2 Java plug-in for > > Netscape! > > > > Nathan > > > > > -Peter > > > http://armedbear.org > > > > > > -- > > > To UNSUBSCRIBE, email to [EMAIL PROTECTED] > > > with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED] > > > > -- > > To UNSUBSCRIBE, email to [EMAIL PROTECTED] > > with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED] -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: RC4 - what it is about?
Nathan, Thank you very much for your message - the information about graphical debugger was very important for me. I have problem with JBuilder installation - famous "No free memory" message, so I thought I could use javadt. Unfortunately, when I tried to use 'javadt' I could not find any documentation about it. Its usage looks intuitive, but in reality it is deceiving. I could not open any files with File->Open menu item, I could not set up any break points, etc. When I click on Help menu, nothing happened. It is also very slow on my PIII 500MHz machine. Do you know where I can find any docs and why it is so slow? Regards, Jacob Nikom Nathan Meyers wrote: > > Jacob Nikom wrote: > > > > Is it simply bug fixing release? > > At least... but there are some important breakthroughs. A look at the > README shows that some longstanding problems have been addressed: > > - The "incompatible raster" problems have been fixed, allowing Swing/AWT > apps to run on many more X servers. Also fixed is the problem preventing > use with X servers with non-native byte order. > > - The Java Platform Debugging Architecture is now present (back-ported > from JDK1.3), as is a new graphical debugger. If everything works, it > might even put the Inprise JDK port out of business :-). > > - More problems with native thread and green thread robustness have been > addressed. > > Nathan > > > > > Jacob Nikom > > > > Nathan Meyers wrote: > > > > > > Peter Graves wrote: > > > > > > > > Blackdown 1.2.2 RC4 is up on ftp.tux.org: > > > > > > > > ftp://ftp.tux.org/java/JDK-1.2.2/i386/rc4 > > > > > > > > > > Also in that directory: the debut of the JDK1.2 Java plug-in for > > > Netscape! > > > > > > Nathan > > > > > > > -Peter > > > > http://armedbear.org > > > > > > > > -- > > > > To UNSUBSCRIBE, email to [EMAIL PROTECTED] > > > > with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED] > > > > > > -- > > > To UNSUBSCRIBE, email to [EMAIL PROTECTED] > > > with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED] -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: information to get started
Have you looked at http://java.sun.com/docs/books/tutorial/ Also, look at http://www.javalinux.net/ about development environments Jacob Nikom "Joe T." wrote: > > hello > Ive been planning on learning java development for a > couple weeks now and im getting pretty sick of just > sitting around -- id like to get started :P > > I picked up Just Java 2 from Sun and Pure Java 2 from > Sams..both of which, IMO, werent very good books at > all. Just Java trys to explain the terms in such a > simplified manner, you completely miss the point, > while Pure Java is way advanced for where im at right > now. Maybe itll be usefull later on. > > Where is there good documentation or even online books > on the internet for learning Java? I hear Thinking in > Java is good, but is it up to date on Java2? I have > to go online/free style now considering Ive spent too > much on books and other computer-related stuff, my > budget is too low for it right now. > > Also, I downloaded JBuilder for Linux, but it seems > like it would spoil me in means of actually learning > the language..the VB-style method for the swing apps > is an example.. > Are there any decend devel environments for Java? or > am i better off going the joe/jed/vi route? > > Thanks for your time > > = > Joe Topjian > [EMAIL PROTECTED] > http://auximini.cjb.net > > Even a stopped clock gives the right time twice a day > __ > Do You Yahoo!? > Talk to your friends online with Yahoo! Messenger. > http://im.yahoo.com > > -- > To UNSUBSCRIBE, email to [EMAIL PROTECTED] > with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED] -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
SunJCE, JDK-1.2.2RC4 -- problems finding it
Howdy, all. Word from On High at work says that we're moving to Java for our work, which is causing this old C++ programmer a little bit of consternation. But hey, spraining your brain is good exercise. :) The particular problem I'm facing is trying to get Sun's JCE to play nice with the Linux JDK-1.2.2RC4. Right now, the JDK is installed in /usr/local; I untarred the JCE in /home/rjhansen. It generated a jce1.2 subdirectory, and down another level from that I found jce1_2-do.jar. I set a CLASSPATH environment variable to point at /home/rjhansen/jce1.2/lib, but when I try and compile code using the sun.misc.* and javax.crypto.* packages, it tells me it can't find them. Now, I'm doing something wrong here, obviously, but I don't for the life of me know what it is I'm doing wrong. I couldn't find anything on the Linux Documentation Project about this problem, the newsgroups didn't turn up any help, and a quick browsing of the archives of this list didn't turn up anything, either. So please, if you're going to flame about "RTFFAQ", keep in mind I've already tried other recourses. :) -- Robert J. Hansen Senior Security Specialist, Exemplary Technologies [EMAIL PROTECTED] (work), [EMAIL PROTECTED] (home) OpenPGP Public Key available on request -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: SunJCE, JDK-1.2.2RC4 -- problems finding it
"Robert J. Hansen" wrote: > > Howdy, all. Word from On High at work says that we're moving to Java > for our work, which is causing this old C++ programmer a little bit of > consternation. But hey, spraining your brain is good exercise. :) > > The particular problem I'm facing is trying to get Sun's JCE to play > nice with the Linux JDK-1.2.2RC4. Right now, the JDK is installed in > /usr/local; I untarred the JCE in /home/rjhansen. It generated a jce1.2 > subdirectory, and down another level from that I found jce1_2-do.jar. > > I set a CLASSPATH environment variable to point at > /home/rjhansen/jce1.2/lib, but when I try and compile code using the > sun.misc.* and javax.crypto.* packages, it tells me it can't find them. The CLASSPATH needs to point at the actual jarfile, not the directory it's in. Something like this: export CLASSPATH=/home/rjhansen/jce1.2/lib/jce1_2-do.jar javac ... Nathan > > Now, I'm doing something wrong here, obviously, but I don't for the life > of me know what it is I'm doing wrong. I couldn't find anything on the > Linux Documentation Project about this problem, the newsgroups didn't > turn up any help, and a quick browsing of the archives of this list > didn't turn up anything, either. > > So please, if you're going to flame about "RTFFAQ", keep in mind I've > already tried other recourses. :) > > -- > Robert J. Hansen > Senior Security Specialist, Exemplary Technologies > [EMAIL PROTECTED] (work), [EMAIL PROTECTED] (home) > OpenPGP Public Key available on request > > -- > To UNSUBSCRIBE, email to [EMAIL PROTECTED] > with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED] -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: RC4 - what it is about?
Jacob Nikom wrote: > > Nathan, > > Thank you very much for your message - the information > about graphical debugger was very important for me. > I have problem with JBuilder installation - famous "No > free memory" message, so I thought I could use javadt. > > Unfortunately, when I tried to use 'javadt' I could not > find any documentation about it. Its usage looks intuitive, > but in reality it is deceiving. I could not open any files > with File->Open menu item, I could not set up any break > points, etc. When I click on Help menu, nothing happened. It comes from Sun. As they say at http://web2.java.sun.com/products/jpda/doc/gui.html: "This release of Java Platform Debugger Architecture includes a simple GUI debugging tool - javadt. It is included as an example and demonstration of JDI. It is not a finished or polished debugger and is missing many features of importance for real debugging work." For what it's worth, the RC4 README.linux also mentions that jdb has been ported to JPDA. If that cures its flakiness problems (which I haven't had a chance to verify), it would make jdb useful with the excellent ddd GUI front-end. You might give that a try. Nathan > > It is also very slow on my PIII 500MHz machine. Do you > know where I can find any docs and why it is so slow? > > Regards, > > Jacob Nikom > > Nathan Meyers wrote: > > > > Jacob Nikom wrote: > > > > > > Is it simply bug fixing release? > > > > At least... but there are some important breakthroughs. A look at the > > README shows that some longstanding problems have been addressed: > > > > - The "incompatible raster" problems have been fixed, allowing Swing/AWT > > apps to run on many more X servers. Also fixed is the problem preventing > > use with X servers with non-native byte order. > > > > - The Java Platform Debugging Architecture is now present (back-ported > > from JDK1.3), as is a new graphical debugger. If everything works, it > > might even put the Inprise JDK port out of business :-). > > > > - More problems with native thread and green thread robustness have been > > addressed. > > > > Nathan > > > > > > > > Jacob Nikom > > > > > > Nathan Meyers wrote: > > > > > > > > Peter Graves wrote: > > > > > > > > > > Blackdown 1.2.2 RC4 is up on ftp.tux.org: > > > > > > > > > > ftp://ftp.tux.org/java/JDK-1.2.2/i386/rc4 > > > > > > > > > > > > > Also in that directory: the debut of the JDK1.2 Java plug-in for > > > > Netscape! > > > > > > > > Nathan > > > > > > > > > -Peter > > > > > http://armedbear.org > > > > > > > > > > -- > > > > > To UNSUBSCRIBE, email to [EMAIL PROTECTED] > > > > > with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED] > > > > > > > > -- > > > > To UNSUBSCRIBE, email to [EMAIL PROTECTED] > > > > with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED] > > -- > To UNSUBSCRIBE, email to [EMAIL PROTECTED] > with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED] -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
