NetBSD-Java archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
sun-jre15 works with mozilla-1.7.6 on NetBSD-2.0/i386
Hi folks,
If you have NetBSD-2.0 for i386 and want to add Java support to your native
build of mozilla-1.7.6, follow these simple steps and you will be running
applets in less then 5 minutes (or more if you haven't built mozilla yet):
First install from pkgsrc the following packages (newer releases should also
work) if you haven't already done it :
mozilla-1.7.6 (www/mozilla)
suse_base-9.1nb5 (emulators/suse_base)
suse_compat-9.1 (emulators/suse_compat)
suse_x11-9.1nb1 (emulators/suse_x11)
sun-jre15-5.0.2 (lang/sun-jre15)
Then issue the following commands (the "$" prompt indicates any user can do it,
"#" indicates commands that should be run by root) :
$ cat >/tmp/javaglue15.c <<EOF
#include <stdio.h>
#include <errno.h>
#undef stdin
#undef stdout
#undef stderr
FILE *stdin=&__sF[0], *stdout=&__sF[1], *stderr=&__sF[2];
int *__errno_location(void) { return __errno(); }
EOF
$ /usr/bin/gcc -o /tmp/libjavaglue15.so -shared /tmp/javaglue15.c
# mkdir -p /usr/local/lib
# cp /tmp/libjavaglue15.so /usr/local/lib
# cp -p /etc/ld.so.conf /etc/ld.so.conf.orig
# cat >>/etc/ld.so.conf <<EOF
libX11.so.6 machdep.fpu_present 0:/usr/X11R6/lib/libX11.so
libX11.so.6 machdep.fpu_present 1:/usr/X11R6/lib/libX11.so
libdl.so.2 machdep.fpu_present 0:/usr/lib/libc.so
libdl.so.2 machdep.fpu_present 1:/usr/lib/libc.so
libc.so.6 machdep.fpu_present 0:/usr/lib/libc.so,/usr/local/lib/libjavaglue15.so
libc.so.6 machdep.fpu_present 1:/usr/lib/libc.so,/usr/local/lib/libjavaglue15.so
EOF
# ldconfig
# cd /usr/pkg/lib/mozilla/plugins
# ln -s ../../../java/sun-1.5/plugin/i386/ns7/libjavaplugin_oji.so
Make sure that the maximum data segment size assigned to your user is at least
262144. This can be done by adding the following line:
ulimit -S -d 262144
to /etc/profile for sh, ksh, and bash users, and by adding the following line:
limit datasize 262144
to /etc/csh.login for csh and tcsh users.
You may also wish to set JAVA_HOME to /usr/pkg/java/sun-1.5 and add
$JAVA_HOME/bin to your PATH, but it seems this is not required if you just want
to run applets.
That's it. BTW, it works with mozilla-1.7.6 but not (yet) with firefox.
Among the applets I found at http://java.sun.com/applets/ the following work ok:
http://java.sun.com/applets/other/AudioItem/
http://java.sun.com/applets/other/BouncingHeads/
http://java.sun.com/applets/other/Bubbles/
http://java.sun.com/applets/other/Bullets/alphabullet.html
http://java.sun.com/applets/other/Hangman/
http://java.sun.com/applets/other/ImageLoop/
http://java.sun.com/applets/other/ImageTest/
http://java.sun.com/applets/other/ScrollingImages/
http://java.sun.com/applets/other/TumblingDuke/
http://java.sun.com/applets/other/UnderConstruction/
http://java.sun.com/applets/other/WordMatch/
http://java.sun.com/applets/archive/beta/Abacus/
http://java.sun.com/applets/archive/beta/Cannon/
http://java.sun.com/applets/archive/beta/Crossword/
http://java.sun.com/applets/archive/beta/Escher/
http://java.sun.com/applets/archive/beta/LED/
http://java.sun.com/applets/archive/beta/NeonSign/
http://java.sun.com/applets/archive/beta/Pythagoras/
http://java.sun.com/applets/archive/beta/Voltage/
These fail at initialisation:
http://java.sun.com/applets/other/Bullets/dukebullet.html
http://java.sun.com/applets/archive/beta/DiningPhilosophers/
http://java.sun.com/applets/archive/beta/NuclearPlant/
http://java.sun.com/applets/archive/beta/StarField/
http://java.sun.com/applets/archive/beta/SystemInfo/
And this one crashes a couple of seconds after it starts:
http://java.sun.com/applets/other/Bullets/huebullet.html
Oh, I don't know Linux enough to tell if errno codes are the same as in NetBSD.
If this is not the case then __errno_location should probably be adapted.
Off topic: If you haven't visited http://www.ffii.org/ yet, please do so before
it's too late.
Off topic again: If you want to declare your income in France, here are the
steps :
1) Install the Linux binary distribution of mozilla because Sun's Java
HotSpot(TM) Client VM 1.5.0_02-b09 crashes with some applets when run from a
NetBSD-native mozilla.
To install mozilla-linux (www/mozilla-bin) you can put "MOZ_PLATFORM=linux" in
/etc/mk.conf.
2) wget
https://static.ir.dgi.minefi.gouv.fr/secure/installation/crypto/nes6/teleir_cryptolib.jar
"rmd160 teleir_cryptolib.jar" should yeld:
RMD160 (teleir_cryptolib.jar) = 075747651fd4a2279575e776362a081720d7065f
and "ls -lT teleir_cryptolib.jar" should yeld:
-r--r--r-- 1 root wheel 331391 Oct 22 11:22:24 2004 teleir_cryptolib.jar
3) Put teleir_cryptolib.jar in $JAVA_HOME/lib/ext
4) export LANG=en_US.ISO-8859-1 (othewise the step were you sign your
declaration will fail...)
Do *not* install appletPKIN6.jar, check.jar nor Scroll.jar.
Also remember: Removing your ~/.java directory often solves problems like
corrupted settings.
Regards,
BSD for Ever
Home |
Main Index |
Thread Index |
Old Index