[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Switching between different JDK implementations (Debian alternative system & Java)

Holger Rauch wrote:
> When wanting to switch between different JDK implementations on Debian, it
> seems to me one has to use "update-alternatives --config" for each
> individual binary that's in a JDK. That's sort of awkward. Is there really
> no wrapper script that I can pass the vendor and/or version no. to and that
> switches ALL binaries automatically?
> Thanks in advance for any info!

You will find now, as part of java-common, a script
which does what you want.

tmarble@techno 173% update-java-alternatives --help
usage: update-java-alternatives [--jre] [--plugin] [ -t|--test|-v|--verbose]
           -l|--list [<jname>]
           -s|--set <jname>
tmarble@techno 174%

To set automatic priorities, do this
# update-java-alternatives --auto

To select the Sun Java JDK, do this
# update-java-alternatives --set java-1.5.0-sun



P.S. Note the approach to handling different SDK implementations is
     currently under discussion and is likely to evolve.

Senior Java Performance Engineer                       Sun Microsystems, Inc.
http://blogs.sun.com/tmarble                What do you want from Java Libre?

Reply to: