[25989] in Athena Bugs
Re: linux 9.3.11: /usr/bin/java
daemon@ATHENA.MIT.EDU (Jonathan Reed)
Tue Aug 24 21:36:47 2004
Mime-Version: 1.0
Message-Id: <p05230101bd519bd77bd8@[18.152.1.192]>
In-Reply-To: <w6m8yc4xmcb.fsf@opus.mit.edu>
Date: Tue, 24 Aug 2004 21:36:15 -0400
To: Jacob Morzinski <jmorzins@mit.edu>
From: Jonathan Reed <jdreed@mit.edu>
Content-Type: text/plain; charset="us-ascii" ; format="flowed"
cc: bugs@mit.edu
Errors-To: bugs-bounces@mit.edu
>
>The current wrapper script for /usr/bin/java is ultimately
>located in /usr/share/java/libgcj-java-placeholder.sh
>and is reached through a chain of symlinks. The chain of
>symlinks is managed by what looks like a custom RedHat hack:
>the alternatives(8) system.
alternatives(8) originated with Debian - the Redhat version is
basically a rewrite of it that removes the dependency on perl. It
was introduced in the RedHat world with 7.3, to manage alternative
MTAs and printing subsystems.
>Unfortunately, using the alternatives system requires that
>we have actual files to point the /usr/bin/java and
>/usr/bin/javac symlinks at. The cluster machines have a local
>version of java, but do not have a local version of javac.
Well, javac and java appear unrelated in the alternatives system, so
in theory we could update one without the other, but that is probably
not desirable.
>
>It looks like that if we wanted to play nice with RedHat and use
>alternatives(8), it would be necessary to write wrapper scripts
>for javac, (and possibly also for jar, java, rmic, and others),
>so that we had our own file to point /usr/bin/javac at.
Well, jar and rmic are alternatives slaves for javac. I think if we
wanted to play nice with RedHat, we could simply have an athena-java
RPM that installed attachandrun scripts for java, javac, jar, etc and
added them to the alternatives system, and then set them using
/sbin/alternatives. It's not too horrible - that's what we do with
the mit-lprng RPM for RHEL 3. However, playing nice doesn't often
get you anywhere when the person you're playing with is the
playground bully and RedHat has a history of deliberately clobbering
packages which use /etc/alternatives to provide something for which
RedHat thinks it should be the canonical source.
-Jon
--
-------------------
Jonathan Reed
jdreed@mit.edu
-------------------