Bob Crispen's help with VRML/JAVA Classpathes
From: Bob Crispen
Subject: The Classpath Problem
How I solved the dreaded Classpath Problem and got Cosmo Player,
WorldView, Community Place, and Live3D 2.0 to live in harmony
on my Win95 PC.
By Bobby Crispen, age (way too old for this foolishness).
Step one: I got NpChooser from the Sony site. That's the
little utility that lets you switch out DLLs in your
Netscape plugins directory, and it's essential if you want
to swap VRML plugins.
Here's how NpChooser works under the hood -- the user interface
is irrelevant. Let's assume you've got four plugins and used
NpChooser so that one and only one of them is active.
Say Live3D is your current VRML plugin. That means in your
Netscape plugins folder (on most installations,
C:\Program Files\Netscape\Navigator\Program\plugins) you've
got a file called Npl3d32.dll.
Suppose you want to make Cosmo Player the active plugin. When
you work the nice user interface, it renames Npl3d32.dll to
_Npl3d32.dll and renames _Npcosmop.dll to Npcosmop.dll. It just
prefaces the filenames of the inactive DLLs with a '_'. This
will be relevant to our discussion in a moment.
Step two: create a folder called C:\java\classes. If you
installed Cosmo Player, you may already have this folder, but
you're going to do some moving around in a minute. Rename the
"vrml" folder in that folder to "sgi". Open it to make sure
it contains another folder called "vrml".
If you installed your Cosmo Player class folder somewhere else,
get it and copy the *inner* folder called "vrml" to
Step three: make folders named "intervista", "netscape", "sony",
and "current" in your C:\java\classes folder.
Step four: copy Intervista's class folders (and their contents)
from C:\Program Files\WorldView for Netscape Navigator\classes
to C:\java\classes\intervista. Check the illustration below to
see if you got the right folders.
Step five: cut (do not leave the file behind) the file Npl3d32.zip
from C:\Program Files\Netscape\ Navigator\Program\plugins and
paste it in C:\java\classes\netscape. Unzip it into the same
folder, so that now you have a folder called "vrml" inside the
Step six: copy the Community Place class zip file vsclass.zip into
C:\java\classes\sony. Unzip it into the same folder, leaving you
with a directory structure that looks like this:
Step seven: edit your C:\Autoexec.bat file and remove all the
lines that set "classpath" or "CLASSPATH". Replace them with
the following single line:
Reboot your computer.
Step eight: by now you should have it all figured out. Pick a
browser with NpChooser. Then go to C:\java\classes\current and
take *everything* out of that folder. Even though the
manufacturer name folders have a "vrml" folder inside them, they
are almost surely different (I'll be researching this, but in the
meantime this is safest).
Then copy *all* the folders and their contents from the
appropriate manufacturer name folder to "current".
Easy peasy. Well, sort of.
Since I'm completely clueless as to DOS shell programming, I'm
hoping someone can make a script to install each plugin that
(a) Look at the plugin DLLs in C:\Program Files\Netscape\
Navigator\Program\plugins and rename the current one
prefacing its filename with a '_' (underscore).
(b) Remove the entire contents of C:\java\classes\current
(c) Copy the entire contents of the appropriate manufacturer
name file in C:\java\classes to C:\java\classes\current.
Now let's talk about the Big Picture. To make it more general,
Netscape needn't be installed in C:\Program Files\Netscape\
Navigator. The registry has a string value in the key
Install Directory. Tack on "program\plugins" to the string
value and you get the name of the folder where all the plugins
Similarly, and this doesn't exist yet (but could), if you
put a key in, say, HKEY_CURRENT_USER\Software\Netscape\
Netscape Navigator\Java called "Classpath Installed" and
give it the value corresponding to C:\java\classes in our
examples, then you would know where to put (and find) the
rest of the folders.
I suggested on www-vrml this morning that installation
programs for VRML plugins look for this key -- if they find
it, install the classes there under their manufacturer name,
and if they don't, ask the user for a preference, and then
set this key for future browsers.
If they did that, then all we poor users would have to do
is use NpChooser to select the plugin we want, and each of
the VRML plugins could, as part of its initialization,
copy the appropriate files to the "Classpath Installed"\
Zooming out still farther, I believe that multiple VRML plugins
are going to be with us for some time. Browser manufacturers
can either recognize this fact or they can continue to
antagonize their users.
Here's a little hint. I did a clean install of Netscape
tonight because I was having problems with WorldView
crashing Netscape when it exited a world. I installed
WorldView as the only Netscape plugin, and it stayed up fine.
The hint's coming shortly now. I then installed Live3D and
lo and behold, WorldView started to crash again.
My first reaction: uninstall Live3D. That was the hint.
Only later did I reinstall it and work out what I had to
do to keep it from crashing WorldView. For every one
person like me, there'll be ten who say "to hell with
Worse, they may say "to hell with VRML".
I don't for a minute believe that my solution is the best
that the bright people in the VRML community can come up
with, but folks, let's get together and agree on *some*
Rev. Bob "Bob" Crispen
Would the last one leaving his youth behind
please turn off the amps?