Java plug-in for Firefox 3.5 and GNU/Linux
The Java plug-in for Firefox 3.5 is, as usual, a nightmare for GNU/Linux users. I’m in love with Debian, but I wanted Firefox, so I installed it. I got the flash plugin and some add-ons, but Java… There was no way to have it working.
Just look at the magic:
First of all, check you have JRE installed and where is it. I do that with
debian:/usr/lib/jvm/java-gcj/jre# update-alternatives –config java
Hi ha 4 alternatives que proveeixin «java».
Selecció Alternativa
———————————————–
1 /usr/bin/gij-4.3
*+ 2 /usr/lib/jvm/java-gcj/jre/bin/java
3 /usr/lib/jvm/java-6-sun/jre/bin/java
4 /usr/bin/gij-4.2Premeu retorn per a mantenir l’opció per defecte[*], o introduïu un número de selecció: 3
Using ‘/usr/lib/jvm/java-6-sun/jre/bin/java’ to provide ‘java’.
debian:/usr/lib/jvm/java-gcj/jre#
I chose the third option, but please get your favourite flavour. Keep in mind that my Firefox is in /home/edu/firefox .
Now we are going to create a symbolic link in the Firefox folder whose target is a .so file in the Java folder. This way:
debian:/# ln -sf /usr/lib/jvm/java-6-sun/jre/plugin/i386/ns7/libjavaplugin_oji.so /home/edu/firefox/plugins/libjavaplugin_oji.so
Now let’s check that everything’s ok: go to the Firefox plugins folder and list all files:
edu@debian:~/firefox/plugins$ ls -l
total 20
lrwxrwxrwx 1 root root 64 1 jul 23:54 libjavaplugin_oji.so -> /usr/lib/jvm/java-6-sun/jre/plugin/i386/ns7/libjavaplugin_oji.so
-rwxr-xr-x 1 edu edu 15792 29 mai 2008 libnullplugin.so
lrwxrwxrwx 1 root root 39 30 nov 2008 nphelix.so -> /opt/real/RealPlayer/mozilla/nphelix.so
edu@debian:~/firefox/plugins$
If you’re using bash and you see the bold line in red, something went wrong. It should be cyan. You have probably created a link to something that doesn’t exists. Remember that the second part of the ln -sf command ( /usr/lib/jvm/java-6-sun/jre/plugin/i386/ns7/libjavaplugin_oji.so ) may be different depending on your system. You should go to /usr/lib and do some research to find a file called, more or less, libjavaplugin_oji.so .
Enjoy your applets
juliol 2nd, 2009 at 15:28
Hi Eduard,
Have you looked at Iced Tea? It derives mostly from the same codebase, except a few non-free bits which were derived from the free re-implementation from GNU. I think it’s almost as complete as Java nowadays (although I don’t visit Java websites very often anyway).
juliol 2nd, 2009 at 15:33
Hey Robert, I’m not really familiar with Java yet, so I can’t compare it rigorously to something else. Anyway, I visited the icedTea wiki ( http://iced-tea.org/wiki/Main_Page ) and it looks cool at first sight. Specially for the chosen name :p