[pkg-java] r13505 - in tags/java-wrappers: . 0.1.21 0.1.21/debian
Vincent Fourmond
fourmond at alioth.debian.org
Mon Apr 4 19:20:13 UTC 2011
Author: fourmond
Date: 2011-04-04 19:20:12 +0000 (Mon, 04 Apr 2011)
New Revision: 13505
Added:
tags/java-wrappers/0.1.21/
tags/java-wrappers/0.1.21/debian/changelog
tags/java-wrappers/0.1.21/debian/control
tags/java-wrappers/0.1.21/debian/java-wrappers.install
tags/java-wrappers/0.1.21/debian/rules
tags/java-wrappers/0.1.21/get-classpath
tags/java-wrappers/0.1.21/java-wrappers.sh
tags/java-wrappers/0.1.21/jvm-list.sh
Removed:
tags/java-wrappers/0.1.21/debian/changelog
tags/java-wrappers/0.1.21/debian/control
tags/java-wrappers/0.1.21/debian/java-wrappers.install
tags/java-wrappers/0.1.21/debian/rules
tags/java-wrappers/0.1.21/java-wrappers.sh
tags/java-wrappers/0.1.21/jvm-list.sh
Log:
[svn-buildpackage] Tagging java-wrappers 0.1.21
Deleted: tags/java-wrappers/0.1.21/debian/changelog
===================================================================
--- trunk/java-wrappers/debian/changelog 2011-04-01 09:47:57 UTC (rev 13487)
+++ tags/java-wrappers/0.1.21/debian/changelog 2011-04-04 19:20:12 UTC (rev 13505)
@@ -1,141 +0,0 @@
-java-wrappers (0.1.18) unstable; urgency=low
-
- * The "let's break Java applications in Wheezy !" upload, or, in other
- words, upload to unstable
- * Switching to format 3.0 (native)
-
- -- Vincent Fourmond <fourmond at debian.org> Fri, 11 Feb 2011 13:35:24 +0100
-
-java-wrappers (0.1.17) experimental; urgency=low
-
- [ Gabriele Giacone ]
- * First step toward java-alternatives integration
-
- [ Vincent Fourmond ]
- * Final step (closes: #609731); thanks Gabriele for the first ;-)...
- * Conforms to standards 3.9.1
-
- -- Vincent Fourmond <fourmond at debian.org> Thu, 13 Jan 2011 23:01:43 +0100
-
-java-wrappers (0.1.16) unstable; urgency=low
-
- * Adding default as a valid jre choice, and make it the default for
- 'all'; patch courtesy of Torsten Werner <twerner at debian.org>
- (closes: #580180)
- * Slightly arrange the documentation, which addresses to some extent bug
- #578944, but probably not satisfyingly enough.
- * Conforms to 3.8.4
- * Adding ${misc:Depends} for potential dh-induced dependencies
-
- -- Vincent Fourmond <fourmond at debian.org> Tue, 04 May 2010 23:42:54 +0200
-
-java-wrappers (0.1.15) unstable; urgency=low
-
- * Switch to Section java
-
- -- Vincent Fourmond <fourmond at debian.org> Wed, 29 Apr 2009 20:04:02 +0200
-
-java-wrappers (0.1.14) unstable; urgency=low
-
- * Fix absolute path in locate_jar (closes: #526087). Thanks to Paul
- Millar <paul.millar at desy.de> for spotting and for the patch.
- * Conforms to 3.8.1
-
- -- Vincent Fourmond <fourmond at debian.org> Wed, 29 Apr 2009 19:13:40 +0200
-
-java-wrappers (0.1.13) unstable; urgency=low
-
- * Now that lenny is out, it's time to an upload to unstable !
-
- -- Vincent Fourmond <fourmond at debian.org> Sun, 15 Feb 2009 15:41:01 +0100
-
-java-wrappers (0.1.12) experimental; urgency=low
-
- * Now provides java2, java5 and java6 aliases that correspond respectively
- to the java2-runtime, java5-runtime and java6-runtime virtual packages
- (closes: #514339)
-
- -- Vincent Fourmond <fourmond at debian.org> Sun, 08 Feb 2009 16:38:13 +0100
-
-java-wrappers (0.1.11) experimental; urgency=low
-
- * Adding (back) the sunmin5 alias for jabref
-
- -- Vincent Fourmond <fourmond at debian.org> Sat, 22 Nov 2008 14:13:19 +0100
-
-java-wrappers (0.1.10) experimental; urgency=low
-
- * Added Vcs-* fields
- * Adding cacaooj6 runtime + adding it to the openjdk alias. (closes: #503819)
-
- -- Vincent Fourmond <fourmond at debian.org> Sun, 16 Nov 2008 03:17:33 +0100
-
-java-wrappers (0.1.9) experimental; urgency=low
-
- * Added a 'all' alias, and make find_java_runtime take no arguments
- as all
-
- -- Vincent Fourmond <fourmond at debian.org> Mon, 22 Sep 2008 23:57:26 +0200
-
-java-wrappers (0.1.8) experimental; urgency=low
-
- * The 'oops, I missed a syntax error release' - fix a missing
- fi in java-wrappers.sh
- * Fixed a few other syntax errors
-
- -- Vincent Fourmond <fourmond at debian.org> Tue, 16 Sep 2008 00:04:37 +0200
-
-java-wrappers (0.1.7) experimental; urgency=low
-
- * Rewrite of find_java_runtime in a much more flexible fashion...
- (closes: #494744)
-
- -- Vincent Fourmond <fourmond at debian.org> Tue, 22 Jul 2008 23:49:08 +0200
-
-java-wrappers (0.1.6) unstable; urgency=low
-
- * Add openjdk6 to the list of runtime flavors
- * java-wrappers.sh now understands a JAVA_FLAVOR environment variable.
- * Already conforms to policy 3.8.0
-
- -- Vincent Fourmond <fourmond at debian.org> Sat, 19 Jul 2008 22:59:31 +0200
-
-java-wrappers (0.1.5) unstable; urgency=low
-
- * Fix the pattern for conjuring up a JAVA_HOME when it is missing.
- (closes: #478054)
-
- -- Vincent Fourmond <fourmond at debian.org> Sat, 03 May 2008 09:30:16 +0200
-
-java-wrappers (0.1.4) unstable; urgency=low
-
- * Improved find_java_runtime to take several arguments
-
- -- Vincent Fourmond <fourmond at debian.org> Wed, 27 Feb 2008 00:42:03 +0100
-
-java-wrappers (0.1.3) unstable; urgency=low
-
- * Small documentation fixes
- * Fix small typos in java-wrappers.sh
- * Fix a problem with JAVA_BINDIR
-
- -- Vincent Fourmond <fourmond at debian.org> Wed, 27 Feb 2008 00:38:23 +0100
-
-java-wrappers (0.1.2) unstable; urgency=low
-
- * Adding link for the LGPL in debian/copyright
- * Closing ITP (closes: #467067)
-
- -- Vincent Fourmond <fourmond at debian.org> Fri, 22 Feb 2008 20:38:52 +0100
-
-java-wrappers (0.1.1) unstable; urgency=low
-
- * Ooops, maintainer is Java Packages, not java mailing-list !
-
- -- Vincent Fourmond <fourmond at debian.org> Wed, 13 Feb 2008 22:10:34 +0100
-
-java-wrappers (0.1) unstable; urgency=low
-
- * Initial release.
-
- -- Vincent Fourmond <fourmond at debian.org> Mon, 11 Feb 2008 20:02:05 +0100
Copied: tags/java-wrappers/0.1.21/debian/changelog (from rev 13504, trunk/java-wrappers/debian/changelog)
===================================================================
--- tags/java-wrappers/0.1.21/debian/changelog (rev 0)
+++ tags/java-wrappers/0.1.21/debian/changelog 2011-04-04 19:20:12 UTC (rev 13505)
@@ -0,0 +1,166 @@
+java-wrappers (0.1.21) experimental; urgency=low
+
+ * Final form of the find_jar_classpath function that now only performs
+ path expansion for the argument, but not for the elements found in the
+ manifests that should be full paths anyway (closes: #563197)
+ * Trim down significantly the number of JVMs available, as fortunately
+ the dozens-of-jvms dark age is long gone (closes: #612903)
+ * Make it sure that mistakes such as find_java_runtime default-jre won't
+ go unnoticed.
+
+ -- Vincent Fourmond <fourmond at debian.org> Mon, 04 Apr 2011 21:08:31 +0200
+
+java-wrappers (0.1.20) experimental; urgency=low
+
+ * Adding unzip as we need it to get the classpath correctly...
+ * Switch to dh 7
+
+ -- Vincent Fourmond <fourmond at debian.org> Mon, 04 Apr 2011 09:44:15 +0200
+
+java-wrappers (0.1.19) experimental; urgency=low
+
+ * First draft of a recursive classpath resolution function.
+
+ -- Vincent Fourmond <fourmond at debian.org> Sun, 03 Apr 2011 01:38:16 +0200
+
+java-wrappers (0.1.18) unstable; urgency=low
+
+ * The "let's break Java applications in Wheezy !" upload, or, in other
+ words, upload to unstable
+ * Switching to format 3.0 (native)
+
+ -- Vincent Fourmond <fourmond at debian.org> Fri, 11 Feb 2011 13:35:24 +0100
+
+java-wrappers (0.1.17) experimental; urgency=low
+
+ [ Gabriele Giacone ]
+ * First step toward java-alternatives integration
+
+ [ Vincent Fourmond ]
+ * Final step (closes: #609731); thanks Gabriele for the first ;-)...
+ * Conforms to standards 3.9.1
+
+ -- Vincent Fourmond <fourmond at debian.org> Thu, 13 Jan 2011 23:01:43 +0100
+
+java-wrappers (0.1.16) unstable; urgency=low
+
+ * Adding default as a valid jre choice, and make it the default for
+ 'all'; patch courtesy of Torsten Werner <twerner at debian.org>
+ (closes: #580180)
+ * Slightly arrange the documentation, which addresses to some extent bug
+ #578944, but probably not satisfyingly enough.
+ * Conforms to 3.8.4
+ * Adding ${misc:Depends} for potential dh-induced dependencies
+
+ -- Vincent Fourmond <fourmond at debian.org> Tue, 04 May 2010 23:42:54 +0200
+
+java-wrappers (0.1.15) unstable; urgency=low
+
+ * Switch to Section java
+
+ -- Vincent Fourmond <fourmond at debian.org> Wed, 29 Apr 2009 20:04:02 +0200
+
+java-wrappers (0.1.14) unstable; urgency=low
+
+ * Fix absolute path in locate_jar (closes: #526087). Thanks to Paul
+ Millar <paul.millar at desy.de> for spotting and for the patch.
+ * Conforms to 3.8.1
+
+ -- Vincent Fourmond <fourmond at debian.org> Wed, 29 Apr 2009 19:13:40 +0200
+
+java-wrappers (0.1.13) unstable; urgency=low
+
+ * Now that lenny is out, it's time to an upload to unstable !
+
+ -- Vincent Fourmond <fourmond at debian.org> Sun, 15 Feb 2009 15:41:01 +0100
+
+java-wrappers (0.1.12) experimental; urgency=low
+
+ * Now provides java2, java5 and java6 aliases that correspond respectively
+ to the java2-runtime, java5-runtime and java6-runtime virtual packages
+ (closes: #514339)
+
+ -- Vincent Fourmond <fourmond at debian.org> Sun, 08 Feb 2009 16:38:13 +0100
+
+java-wrappers (0.1.11) experimental; urgency=low
+
+ * Adding (back) the sunmin5 alias for jabref
+
+ -- Vincent Fourmond <fourmond at debian.org> Sat, 22 Nov 2008 14:13:19 +0100
+
+java-wrappers (0.1.10) experimental; urgency=low
+
+ * Added Vcs-* fields
+ * Adding cacaooj6 runtime + adding it to the openjdk alias. (closes: #503819)
+
+ -- Vincent Fourmond <fourmond at debian.org> Sun, 16 Nov 2008 03:17:33 +0100
+
+java-wrappers (0.1.9) experimental; urgency=low
+
+ * Added a 'all' alias, and make find_java_runtime take no arguments
+ as all
+
+ -- Vincent Fourmond <fourmond at debian.org> Mon, 22 Sep 2008 23:57:26 +0200
+
+java-wrappers (0.1.8) experimental; urgency=low
+
+ * The 'oops, I missed a syntax error release' - fix a missing
+ fi in java-wrappers.sh
+ * Fixed a few other syntax errors
+
+ -- Vincent Fourmond <fourmond at debian.org> Tue, 16 Sep 2008 00:04:37 +0200
+
+java-wrappers (0.1.7) experimental; urgency=low
+
+ * Rewrite of find_java_runtime in a much more flexible fashion...
+ (closes: #494744)
+
+ -- Vincent Fourmond <fourmond at debian.org> Tue, 22 Jul 2008 23:49:08 +0200
+
+java-wrappers (0.1.6) unstable; urgency=low
+
+ * Add openjdk6 to the list of runtime flavors
+ * java-wrappers.sh now understands a JAVA_FLAVOR environment variable.
+ * Already conforms to policy 3.8.0
+
+ -- Vincent Fourmond <fourmond at debian.org> Sat, 19 Jul 2008 22:59:31 +0200
+
+java-wrappers (0.1.5) unstable; urgency=low
+
+ * Fix the pattern for conjuring up a JAVA_HOME when it is missing.
+ (closes: #478054)
+
+ -- Vincent Fourmond <fourmond at debian.org> Sat, 03 May 2008 09:30:16 +0200
+
+java-wrappers (0.1.4) unstable; urgency=low
+
+ * Improved find_java_runtime to take several arguments
+
+ -- Vincent Fourmond <fourmond at debian.org> Wed, 27 Feb 2008 00:42:03 +0100
+
+java-wrappers (0.1.3) unstable; urgency=low
+
+ * Small documentation fixes
+ * Fix small typos in java-wrappers.sh
+ * Fix a problem with JAVA_BINDIR
+
+ -- Vincent Fourmond <fourmond at debian.org> Wed, 27 Feb 2008 00:38:23 +0100
+
+java-wrappers (0.1.2) unstable; urgency=low
+
+ * Adding link for the LGPL in debian/copyright
+ * Closing ITP (closes: #467067)
+
+ -- Vincent Fourmond <fourmond at debian.org> Fri, 22 Feb 2008 20:38:52 +0100
+
+java-wrappers (0.1.1) unstable; urgency=low
+
+ * Ooops, maintainer is Java Packages, not java mailing-list !
+
+ -- Vincent Fourmond <fourmond at debian.org> Wed, 13 Feb 2008 22:10:34 +0100
+
+java-wrappers (0.1) unstable; urgency=low
+
+ * Initial release.
+
+ -- Vincent Fourmond <fourmond at debian.org> Mon, 11 Feb 2008 20:02:05 +0100
Deleted: tags/java-wrappers/0.1.21/debian/control
===================================================================
--- trunk/java-wrappers/debian/control 2011-04-01 09:47:57 UTC (rev 13487)
+++ tags/java-wrappers/0.1.21/debian/control 2011-04-04 19:20:12 UTC (rev 13505)
@@ -1,20 +0,0 @@
-Source: java-wrappers
-Section: java
-Priority: optional
-Maintainer: Debian Java Maintainers <pkg-java-maintainers at lists.alioth.debian.org>
-Uploaders: Vincent Fourmond <fourmond at debian.org>
-Build-Depends: debhelper (>= 5)
-Standards-Version: 3.9.1
-Vcs-Svn: svn://svn.debian.org/svn/pkg-java/trunk/java-wrappers
-Vcs-Browser: http://svn.debian.org/viewsvn/pkg-java/trunk/java-wrappers
-
-
-Package: java-wrappers
-Depends: ${misc:Depends}
-Architecture: all
-Description: wrappers for java executables
- Wrapper script facilities for java executables.
- .
- This package can be used by packagers of java programs to
- provide java runtime detection, jar lookup and a consistent
- user interface (debugging, environment variables).
\ No newline at end of file
Copied: tags/java-wrappers/0.1.21/debian/control (from rev 13496, trunk/java-wrappers/debian/control)
===================================================================
--- tags/java-wrappers/0.1.21/debian/control (rev 0)
+++ tags/java-wrappers/0.1.21/debian/control 2011-04-04 19:20:12 UTC (rev 13505)
@@ -0,0 +1,20 @@
+Source: java-wrappers
+Section: java
+Priority: optional
+Maintainer: Debian Java Maintainers <pkg-java-maintainers at lists.alioth.debian.org>
+Uploaders: Vincent Fourmond <fourmond at debian.org>
+Build-Depends: debhelper (>= 7)
+Standards-Version: 3.9.1
+Vcs-Svn: svn://svn.debian.org/svn/pkg-java/trunk/java-wrappers
+Vcs-Browser: http://svn.debian.org/viewsvn/pkg-java/trunk/java-wrappers
+
+
+Package: java-wrappers
+Depends: ${misc:Depends}, unzip
+Architecture: all
+Description: wrappers for java executables
+ Wrapper script facilities for java executables.
+ .
+ This package can be used by packagers of java programs to
+ provide java runtime detection, jar lookup and a consistent
+ user interface (debugging, environment variables).
\ No newline at end of file
Deleted: tags/java-wrappers/0.1.21/debian/java-wrappers.install
===================================================================
--- trunk/java-wrappers/debian/java-wrappers.install 2011-04-01 09:47:57 UTC (rev 13487)
+++ tags/java-wrappers/0.1.21/debian/java-wrappers.install 2011-04-04 19:20:12 UTC (rev 13505)
@@ -1,2 +0,0 @@
-java-wrappers.sh usr/lib/java-wrappers
-jvm-list.sh usr/lib/java-wrappers
\ No newline at end of file
Copied: tags/java-wrappers/0.1.21/debian/java-wrappers.install (from rev 13489, trunk/java-wrappers/debian/java-wrappers.install)
===================================================================
--- tags/java-wrappers/0.1.21/debian/java-wrappers.install (rev 0)
+++ tags/java-wrappers/0.1.21/debian/java-wrappers.install 2011-04-04 19:20:12 UTC (rev 13505)
@@ -0,0 +1,3 @@
+java-wrappers.sh usr/lib/java-wrappers
+jvm-list.sh usr/lib/java-wrappers
+get-classpath usr/lib/java-wrappers
\ No newline at end of file
Deleted: tags/java-wrappers/0.1.21/debian/rules
===================================================================
--- trunk/java-wrappers/debian/rules 2011-04-01 09:47:57 UTC (rev 13487)
+++ tags/java-wrappers/0.1.21/debian/rules 2011-04-04 19:20:12 UTC (rev 13505)
@@ -1,46 +0,0 @@
-#!/usr/bin/make -f
-# MAde with the aid of dh_make, by Craig Small
-# Sample debian/rules that uses debhelper. GNU copyright 1997 by Joey Hess.
-# Some lines taken from debmake, by Cristoph Lameter.
-
-# Uncomment this to turn on verbose mode.
-#export DH_VERBOSE=1
-
-clean:
- dh_testdir
- dh_testroot
- dh_clean
-
-install: install-stamp
-install-stamp:
- dh_testdir
- dh_testroot
- dh_clean -k
- dh_installdirs
-
- touch install-stamp
-
-binary-arch:
-
-# Build architecture-independent files here.
-# Pass -i to all debhelper commands in this target to reduce clutter.
-binary-indep: build install
- dh_testdir -i
- dh_testroot -i
- dh_installdocs -i
- dh_installexamples -i
- dh_installman -i
- dh_install -i
- dh_installchangelogs -i
- dh_link -i
- dh_compress -i
- dh_fixperms -i
- dh_installdeb -i
- dh_gencontrol -i
- dh_md5sums -i
- dh_builddeb -i
-
- dh_builddeb
-
-binary: binary-indep binary-arch
-.PHONY: build clean binary-indep binary-arch binary install configure
Copied: tags/java-wrappers/0.1.21/debian/rules (from rev 13496, trunk/java-wrappers/debian/rules)
===================================================================
--- tags/java-wrappers/0.1.21/debian/rules (rev 0)
+++ tags/java-wrappers/0.1.21/debian/rules 2011-04-04 19:20:12 UTC (rev 13505)
@@ -0,0 +1,3 @@
+#!/usr/bin/make -f
+%:
+ dh $@
Copied: tags/java-wrappers/0.1.21/get-classpath (from rev 13489, trunk/java-wrappers/get-classpath)
===================================================================
--- tags/java-wrappers/0.1.21/get-classpath (rev 0)
+++ tags/java-wrappers/0.1.21/get-classpath 2011-04-04 19:20:12 UTC (rev 13505)
@@ -0,0 +1,40 @@
+#! /usr/bin/perl
+
+
+# get-classpayth, copyright 2011 by Vincent Fourmond
+
+# This program is free software: you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation, either version 2 of the License, or
+# (at your option) any later version.
+
+# This program is distributed in the hope that it will be useful, but
+# WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+# General Public License for more details.
+
+# You should have received a copy of the GNU General Public License
+# along with this program. If not, see
+# <http://www.gnu.org/licenses/>.
+
+$file = shift(@ARGV);
+open MANIFEST, "unzip -p \"$file\" META-INF/MANIFEST.MF | ";
+my $cp = "";
+while(my $line = <MANIFEST>) {
+ if($line =~ /Class-Path:\s*(.*)/) {
+ $cp = $1;
+ }
+ elsif($cp) {
+
+ if($line =~ /^ (.*)/) {
+ $cp .= $1;
+ }
+ else {
+ last;
+ }
+ }
+}
+close MANIFEST;
+$cp =~ s/\r//g;
+print "$cp\n";
+
Deleted: tags/java-wrappers/0.1.21/java-wrappers.sh
===================================================================
--- trunk/java-wrappers/java-wrappers.sh 2011-04-01 09:47:57 UTC (rev 13487)
+++ tags/java-wrappers/0.1.21/java-wrappers.sh 2011-04-04 19:20:12 UTC (rev 13505)
@@ -1,278 +0,0 @@
-# wrappers.sh: various functions to be used by Java script wrappers
-# Copyright 2008 by Vincent Fourmond <fourmond at debian.org>
-#
-# This library is free software; you can redistribute it and/or
-# modify it under the terms of the GNU Lesser General Public
-# License as published by the Free Software Foundation; either
-# version 2.1 of the License, or (at your option) any later version.
-
-# This library is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-# Lesser General Public License for more details.
-
-# You should have received a copy of the GNU Lesser General Public
-# License along with this library; if not, write to the Free Software
-# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
-
-# Import the list of JVMs
-
-. /usr/lib/java-wrappers/jvm-list.sh
-
-# Display a debugging message
-java_debug() {
- if [ "$DEBUG_WRAPPER" ]; then
- echo "[debug] $0: $@" >&2;
- fi
-}
-
-# Displays a warning
-java_warning() {
- echo "[warning] $0: $@" >&2;
-}
-
-# Exit with an error message
-java_fail() {
- echo "[error] $0: $@" >&2;
- exit 1;
-}
-
-# Try to get the amount of memory available on the machine to come up
-# with a decent -Xmx argument, returned as the value of the
-# determined_xmx_arg (defaults in kilobytes, so you should add k
-# afterwards)
-determine_xmx_arg() {
- # Yes, that's ugly, so what ??
- mem=`free -k 2>/dev/null | head -n2 | tail -n1 | sed -r s/'[^0-9]+//' | cut -d' ' -f1`
-
-}
-
-# Try to find a Java runtime and set JAVA_HOME and JAVA_CMD accordingly.
-# If JAVA_CMD exists, nothing is done. If JAVA_HOME exists, only that
-# is searched.
-#
-# The full list of JVM names understood can be found in the file
-# /usr/lib/java-wrappers/jvm-list.sh.
-#
-# More than one argument can be specified; they will be taken into account
-# in that order; the first one found will be selected.
-#
-# If JAVA_DEBUGGER is set, we try to use jdb rather than java, if it is
-# present.
-#
-# This information is currently *far from complete* !!!
-find_java_runtime() {
-
- if [ "$JAVA_CMD" ]; then
- if which "$JAVA_CMD" > /dev/null; then
- java_debug "Using already set JAVA_CMD = '$JAVA_CMD' => '"`which "$JAVA_CMD"`"'"
- return 0; # Nothing to do
- else
- java_warning "JAVA_CMD was set to '$JAVA_CMD', but which(1) does not find it."
- java_warning "Therefore ignoring JAVA_CMD"
- fi
- fi
-
- if [ "$JAVA_BINDIR" ]; then
- if [ "$JAVA_DEBUGGER" ] && [ -x "$JAVA_BINDIR/jdb" ]; then
- JAVA_CMD="$JAVA_BINDIR/jdb"
- elif [ -x "$JAVA_BINDIR/java" ]; then
- JAVA_CMD="$JAVA_BINDIR/java"
- fi
- if [ "$JAVA_CMD" ]; then
- java_debug "Using '$JAVA_CMD' from JAVA_BINDIR = '$JAVA_BINDIR'"
- return 0;
- else
- java_warning "JAVA_BINDIR = '$JAVA_BINDIR' does not point to a java binary"
- fi
- fi
-
- if [ -z "$JAVA_HOME" ]; then
-
- # We now try to look for a reasonable JAVA_HOME.
- # First, narrow the choices according to what
- # was asked.
- #
- # Please see the list of understood jvms in
- # /usr/lib/java-wrappers/jvm-list.sh
-
- DIRS=""
-
- # If no arguments are given, we take it as 'all'
- if test -z "$1"; then
- set all
- fi
-
- while test "$1"
- do
- found_jvm=$(eval "echo -n \$__jvm_$1")
- if [ -z "$found_jvm" ]; then
- java_warning "JVM flavor '${1:-none}' not understood"
- else
- DIRS="$DIRS $found_jvm"
- shift
- fi
- done
- # Nothing means everything
- if [ -z "$DIRS" ]; then
- DIRS=$all_runtimes
- fi
- # First, we check if __jvm_alt is within the possible choices:
- if echo "$DIRS" | fgrep "$__jvm_alt" > /dev/null ; then
- JAVA_HOME="$__jvm_alt"
- java_debug "Picking up the JVM designated by the alternatives system: "
- java_debug " JAVA_HOME = '$JAVA_HOME'"
- else
-
- # And pick up the first one that works reasonably
- for dir in $DIRS; do
- if [ -x $dir/bin/java ]; then
- JAVA_HOME=$dir
- break;
- fi
- done
- fi
- else
- java_debug "Using provided JAVA_HOME = '$JAVA_HOME'"
- fi
- if [ "$JAVA_HOME" ] ; then
- if [ "$JAVA_DEBUGGER" ] && [ -x "$JAVA_HOME/bin/jdb" ]; then
- JAVA_CMD="$JAVA_HOME/bin/jdb"
- else
- JAVA_CMD="$JAVA_HOME/bin/java"
- fi
- java_debug "Found JAVA_HOME = '$JAVA_HOME'"
- java_debug "Found JAVA_CMD = '$JAVA_CMD'"
- return 0 # Fine
- else
- java_warning "No java runtime was found"
- return 1;
- fi
-}
-
-
-# Some initializations:
-if [ "$JAVA_CLASSPATH" ]; then
- java_debug "Building classpath on JAVA_CLASSPATH = '$JAVA_CLASSPATH'"
-else
- JAVA_CLASSPATH=
-fi
-if [ "$DESTDIR" ]; then
- java_debug "Using DESTDIR = '$DESTDIR'"
-else
- DESTDIR=""
-fi
-
-if [ "$JAVA_JARPATH" ]; then
- java_debug "Jar lookup is done in JAVA_JARPATH = '$JAVA_JARPATH'"
-else
- JAVA_JARPATH=$DESTDIR/usr/share/java
-fi
-
-
-# If the user provides a JAVA_FLAVOR environment variable, we
-# force the runtime to be the given flavor, such as for fund_java_runtime
-if [ "$JAVA_FLAVOR" ]; then
- find_java_runtime "$JAVA_FLAVOR" || \
- java_warning "Could not find runtime for user-supplied flavor '${JAVA_FLAVOR}"
-fi
-
-
-# Same as find_java_runtime, but fails with an error if
-# nothing is found.
-require_java_runtime() {
- find_java_runtime "$@" || \
- java_fail "Unable to find an appropriate java runtime. See java_wrappers(7) for help"
-}
-
-# Looks for a jar file and returns its location as the
-# found_jar variable, or fails if no jar was found.
-locate_jar() {
- jar="$1"
- if [ -r $JAVA_JARPATH/$jar ]; then
- found_jar=$JAVA_JARPATH/$jar
- elif [ -r $JAVA_JARPATH/$jar.jar ]; then
- found_jar=$JAVA_JARPATH/$jar.jar
- elif [ -r $jar ]; then
- # Maybe issue a warning that jars should not be looked
- # for absolutely ?
- found_jar=$jar
- elif [ -r $jar.jar ]; then
- # Maybe issue a warning that jars should not be looked
- # for absolutely ?
- found_jar=$jar.jar
- else
- return 1 # Not found
- fi
- return 0 # Found
-}
-
-# Find jars and add them to the classpath
-find_jars() {
- looked_for_jars=1
- for jar in $@ ; do
- if locate_jar $jar; then
- JAVA_CLASSPATH=$JAVA_CLASSPATH:$found_jar
- else
- java_warning "Unable to locate $jar in $JAVA_JARPATH"
- fi
- done
-}
-
-# Adds the first jar found to the classpath. Useful for alternative
-# dependencies.
-find_one_jar_in() {
- looked_for_jars=1
- for jar in $@ ; do
- if locate_jar $jar; then
- JAVA_CLASSPATH=$JAVA_CLASSPATH:$found_jar
- return 0
- fi
- done
- java_warning "Could fine none of $@ in $JAVA_JARPATH"
- return 1
-}
-
-# Runs the program !
-run_java() {
- if [ -z "$JAVA_CMD" ]; then
- java_warning "No JAVA_CMD set for run_java, falling back to JAVA_CMD = java"
- JAVA_CMD=java
- fi
- # We try to conjure up a JAVA_HOME from JAVA_CMD, if the former
- # is absent. Idea coming from bug #404728.
- if [ -z "$JAVA_HOME" ]; then
- full_cmd_path="$(readlink -f `which $JAVA_CMD`)"
- JAVA_HOME="${full_cmd_path%bin/*}"
- java_debug "Using JAVA_CMD to find JAVA_HOME = '$JAVA_HOME'"
- fi
- if [ "$FORCE_CLASSPATH" ]; then
- java_debug "Using imposed classpath : FORCE_CLASSPATH = '$FORCE_CLASSPATH'";
- cp="-classpath $FORCE_CLASSPATH";
- elif [ "$JAVA_CLASSPATH" ]; then
- cp="-classpath $JAVA_CLASSPATH";
- else
- cp="";
- fi
- # Exporting JAVA_HOME, I guess it can't hurt much, can it ?
- export JAVA_HOME
- java_debug "Environment variable CLASSPATH is '$CLASSPATH'"
- java_debug "Runnning $JAVA_CMD $JAVA_ARGS $cp $@"
- exec $JAVA_CMD $JAVA_ARGS $cp "$@"
-}
-
-# Runs a java jar.
-# You don't have to use this function to run a jar, but you might find
-# it useful, though.
-run_jar() {
- if [ "$looked_for_jars" ]; then
- java_warning "It is most likely useless to use find_jar when running"
- java_warning "a class with run_jar (-classpath is ignored)"
- fi
- if locate_jar $1; then
- shift
- run_java -jar "$@"
- else
- java_fail "Unable to find jar $1 in $JAVA_JARPATH"
- fi
-}
\ No newline at end of file
Copied: tags/java-wrappers/0.1.21/java-wrappers.sh (from rev 13504, trunk/java-wrappers/java-wrappers.sh)
===================================================================
--- tags/java-wrappers/0.1.21/java-wrappers.sh (rev 0)
+++ tags/java-wrappers/0.1.21/java-wrappers.sh 2011-04-04 19:20:12 UTC (rev 13505)
@@ -0,0 +1,320 @@
+# wrappers.sh: various functions to be used by Java script wrappers
+# Copyright 2008 by Vincent Fourmond <fourmond at debian.org>
+#
+# This library is free software; you can redistribute it and/or
+# modify it under the terms of the GNU Lesser General Public
+# License as published by the Free Software Foundation; either
+# version 2.1 of the License, or (at your option) any later version.
+
+# This library is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+# Lesser General Public License for more details.
+
+# You should have received a copy of the GNU Lesser General Public
+# License along with this library; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
+
+# Import the list of JVMs
+
+. /usr/lib/java-wrappers/jvm-list.sh
+
+# Display a debugging message
+java_debug() {
+ if [ "$DEBUG_WRAPPER" ]; then
+ echo "[debug] $0: $@" >&2;
+ fi
+}
+
+# Displays a warning
+java_warning() {
+ echo "[warning] $0: $@" >&2;
+}
+
+# Exit with an error message
+java_fail() {
+ echo "[error] $0: $@" >&2;
+ exit 1;
+}
+
+# Try to get the amount of memory available on the machine to come up
+# with a decent -Xmx argument, returned as the value of the
+# determined_xmx_arg (defaults in kilobytes, so you should add k
+# afterwards)
+determine_xmx_arg() {
+ # Yes, that's ugly, so what ??
+ mem=`free -k 2>/dev/null | head -n2 | tail -n1 | sed -r s/'[^0-9]+//' | cut -d' ' -f1`
+
+}
+
+# Try to find a Java runtime and set JAVA_HOME and JAVA_CMD accordingly.
+# If JAVA_CMD exists, nothing is done. If JAVA_HOME exists, only that
+# is searched.
+#
+# The full list of JVM names understood can be found in the file
+# /usr/lib/java-wrappers/jvm-list.sh.
+#
+# More than one argument can be specified; they will be taken into account
+# in that order; the first one found will be selected.
+#
+# If JAVA_DEBUGGER is set, we try to use jdb rather than java, if it is
+# present.
+#
+# This information is currently *far from complete* !!!
+find_java_runtime() {
+
+ if [ "$JAVA_CMD" ]; then
+ if which "$JAVA_CMD" > /dev/null; then
+ java_debug "Using already set JAVA_CMD = '$JAVA_CMD' => '"`which "$JAVA_CMD"`"'"
+ return 0; # Nothing to do
+ else
+ java_warning "JAVA_CMD was set to '$JAVA_CMD', but which(1) does not find it."
+ java_warning "Therefore ignoring JAVA_CMD"
+ fi
+ fi
+
+ if [ "$JAVA_BINDIR" ]; then
+ if [ "$JAVA_DEBUGGER" ] && [ -x "$JAVA_BINDIR/jdb" ]; then
+ JAVA_CMD="$JAVA_BINDIR/jdb"
+ elif [ -x "$JAVA_BINDIR/java" ]; then
+ JAVA_CMD="$JAVA_BINDIR/java"
+ fi
+ if [ "$JAVA_CMD" ]; then
+ java_debug "Using '$JAVA_CMD' from JAVA_BINDIR = '$JAVA_BINDIR'"
+ return 0;
+ else
+ java_warning "JAVA_BINDIR = '$JAVA_BINDIR' does not point to a java binary"
+ fi
+ fi
+
+ if [ -z "$JAVA_HOME" ]; then
+
+ # We now try to look for a reasonable JAVA_HOME.
+ # First, narrow the choices according to what
+ # was asked.
+ #
+ # Please see the list of understood jvms in
+ # /usr/lib/java-wrappers/jvm-list.sh
+
+ DIRS=""
+
+ # If no arguments are given, we take it as 'all'
+ if test -z "$1"; then
+ set all
+ fi
+
+ while test "$1"
+ do
+ if echo $1 | egrep -- '[^0-9A-Za-z_]'; then
+ java_warning "JVM flavor '${1}' contains illegal characters"
+ else
+ found_jvm=$(eval "echo -n \$__jvm_$1")
+ if [ -z "$found_jvm" ] ; then
+ java_warning "JVM flavor '${1:-none}' not understood"
+ else
+ DIRS="$DIRS $found_jvm"
+ fi
+ fi
+ shift
+ done
+ # Nothing means everything
+ if [ -z "$DIRS" ]; then
+ DIRS=$all_runtimes
+ fi
+ # First, we check if __jvm_alt is within the possible choices:
+ if echo "$DIRS" | fgrep "$__jvm_alt" > /dev/null ; then
+ JAVA_HOME="$__jvm_alt"
+ java_debug "Picking up the JVM designated by the alternatives system: "
+ java_debug " JAVA_HOME = '$JAVA_HOME'"
+ else
+
+ # And pick up the first one that works reasonably
+ for dir in $DIRS; do
+ if [ -x $dir/bin/java ]; then
+ JAVA_HOME=$dir
+ break;
+ fi
+ done
+ fi
+ else
+ java_debug "Using provided JAVA_HOME = '$JAVA_HOME'"
+ fi
+ if [ "$JAVA_HOME" ] ; then
+ if [ "$JAVA_DEBUGGER" ] && [ -x "$JAVA_HOME/bin/jdb" ]; then
+ JAVA_CMD="$JAVA_HOME/bin/jdb"
+ else
+ JAVA_CMD="$JAVA_HOME/bin/java"
+ fi
+ java_debug "Found JAVA_HOME = '$JAVA_HOME'"
+ java_debug "Found JAVA_CMD = '$JAVA_CMD'"
+ return 0 # Fine
+ else
+ java_warning "No java runtime was found"
+ return 1;
+ fi
+}
+
+
+# Some initializations:
+if [ "$JAVA_CLASSPATH" ]; then
+ java_debug "Building classpath on JAVA_CLASSPATH = '$JAVA_CLASSPATH'"
+else
+ JAVA_CLASSPATH=
+fi
+if [ "$DESTDIR" ]; then
+ java_debug "Using DESTDIR = '$DESTDIR'"
+else
+ DESTDIR=""
+fi
+
+if [ "$JAVA_JARPATH" ]; then
+ java_debug "Jar lookup is done in JAVA_JARPATH = '$JAVA_JARPATH'"
+else
+ JAVA_JARPATH=$DESTDIR/usr/share/java
+fi
+
+
+# If the user provides a JAVA_FLAVOR environment variable, we
+# force the runtime to be the given flavor, such as for find_java_runtime
+if [ "$JAVA_FLAVOR" ]; then
+ find_java_runtime "$JAVA_FLAVOR" || \
+ java_warning "Could not find runtime for user-supplied flavor '${JAVA_FLAVOR}"
+fi
+
+
+# Same as find_java_runtime, but fails with an error if
+# nothing is found.
+require_java_runtime() {
+ find_java_runtime "$@" || \
+ java_fail "Unable to find an appropriate java runtime. See java_wrappers(7) for help"
+}
+
+# Looks for a jar file and returns its location as the
+# found_jar variable, or fails if no jar was found.
+locate_jar() {
+ jar="$1"
+ if [ -r $JAVA_JARPATH/$jar ]; then
+ found_jar=$JAVA_JARPATH/$jar
+ elif [ -r $JAVA_JARPATH/$jar.jar ]; then
+ found_jar=$JAVA_JARPATH/$jar.jar
+ elif [ -r $jar ]; then
+ found_jar=$jar
+ elif [ -r $jar.jar ]; then
+ found_jar=$jar.jar
+ else
+ return 1 # Not found
+ fi
+ return 0 # Found
+}
+
+# Find jars and add them to the classpath
+find_jars() {
+ looked_for_jars=1
+ for jar in $@ ; do
+ if locate_jar $jar; then
+ JAVA_CLASSPATH=$JAVA_CLASSPATH:$found_jar
+ else
+ java_warning "Unable to locate $jar in $JAVA_JARPATH"
+ fi
+ done
+}
+
+# Recursively adds the jar and its classpath to the classpath
+_recurse_jar_classpath() {
+ if [ -r "$1" ]; then
+ if echo $JAVA_CLASSPATH | fgrep "$1"; then
+ return 0;
+ fi
+ JAVA_CLASSPATH=$JAVA_CLASSPATH:$1
+ java_debug "Looking at classpath of jar: '$1'"
+ for jar in $(/usr/lib/java-wrappers/get-classpath "$1"); do
+ if [ "${jar##/}" = "$jar" ]; then
+ java_warning "jar file $1 contains relative classpath element: $jar"
+ else
+ _recurse_jar_classpath $jar;
+ fi
+ done
+ else
+ java_debug "Unable to find file $1 that may be needed"
+ return 1;
+ fi
+}
+
+# This function tries to mimick the behaviour of the -jar option of
+# the java executable, by adding the target jar and all its classpath
+# recursively.
+#
+# This function is experimental for now, and its interface is not very
+# well specified yet.
+#
+# It will return without problem if the target class already is in the
+# classpath. It aborts with an error if a JAR file can't be found.
+find_jar_classpath() {
+ if locate_jar "$1"; then
+ looked_for_jars=1
+ _recurse_jar_classpath $found_jar
+ else
+ java_warn "Unable to find the jar file $jar"
+ return 1;
+ fi
+}
+
+
+
+# Adds the first jar found to the classpath. Useful for alternative
+# dependencies.
+find_one_jar_in() {
+ looked_for_jars=1
+ for jar in $@ ; do
+ if locate_jar $jar; then
+ JAVA_CLASSPATH=$JAVA_CLASSPATH:$found_jar
+ return 0
+ fi
+ done
+ java_warning "Could fine none of $@ in $JAVA_JARPATH"
+ return 1
+}
+
+# Runs the program !
+run_java() {
+ if [ -z "$JAVA_CMD" ]; then
+ java_warning "No JAVA_CMD set for run_java, falling back to JAVA_CMD = java"
+ JAVA_CMD=java
+ fi
+ # We try to conjure up a JAVA_HOME from JAVA_CMD, if the former
+ # is absent. Idea coming from bug #404728.
+ if [ -z "$JAVA_HOME" ]; then
+ full_cmd_path="$(readlink -f `which $JAVA_CMD`)"
+ JAVA_HOME="${full_cmd_path%bin/*}"
+ java_debug "Using JAVA_CMD to find JAVA_HOME = '$JAVA_HOME'"
+ fi
+ if [ "$FORCE_CLASSPATH" ]; then
+ java_debug "Using imposed classpath : FORCE_CLASSPATH = '$FORCE_CLASSPATH'";
+ cp="-classpath $FORCE_CLASSPATH";
+ elif [ "$JAVA_CLASSPATH" ]; then
+ cp="-classpath $JAVA_CLASSPATH";
+ else
+ cp="";
+ fi
+ # Exporting JAVA_HOME, I guess it can't hurt much, can it ?
+ export JAVA_HOME
+ java_debug "Environment variable CLASSPATH is '$CLASSPATH'"
+ java_debug "Runnning $JAVA_CMD $JAVA_ARGS $cp $@"
+ exec $JAVA_CMD $JAVA_ARGS $cp "$@"
+}
+
+# Runs a java jar.
+# You don't have to use this function to run a jar, but you might find
+# it useful, though.
+run_jar() {
+ if [ "$looked_for_jars" ]; then
+ java_warning "It is most likely useless to use find_jar when running"
+ java_warning "a class with run_jar (-classpath is ignored)"
+ fi
+ if locate_jar $1; then
+ shift
+ run_java -jar "$@"
+ else
+ java_fail "Unable to find jar $1 in $JAVA_JARPATH"
+ fi
+}
\ No newline at end of file
Deleted: tags/java-wrappers/0.1.21/jvm-list.sh
===================================================================
--- trunk/java-wrappers/jvm-list.sh 2011-04-01 09:47:57 UTC (rev 13487)
+++ tags/java-wrappers/0.1.21/jvm-list.sh 2011-04-04 19:20:12 UTC (rev 13505)
@@ -1,71 +0,0 @@
-# jvm-list.sh: a list of available JVM and some shortcuts
-# Copyright 2008, 2009 by Vincent Fourmond <fourmond at debian.org>
-#
-# This library is free software; you can redistribute it and/or
-# modify it under the terms of the GNU Lesser General Public
-# License as published by the Free Software Foundation; either
-# version 2.1 of the License, or (at your option) any later version.
-
-# This library is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-# Lesser General Public License for more details.
-
-# You should have received a copy of the GNU Lesser General Public
-# License along with this library; if not, write to the Free Software
-# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
-
-# All variables defined here can be used as arguments for the
-# find_java_runtime function if you strip the __jvm_ at the beginning
-# of the variable...
-#
-# They can also be used for the JAVA_FLAVOR environment variable, see
-# java-wrappers(7).
-
-# default runtime
-__jvm_default="/usr/lib/jvm/default-java"
-
-# Sun runtimes
-__jvm_sun4="/usr/lib/j2*1.4-sun"
-__jvm_sun5="/usr/lib/jvm/java-1.5.0-sun /usr/lib/j2*1.5-sun"
-__jvm_sun6="/usr/lib/jvm/java-6-sun /usr/lib/j2*1.6-sun"
-
-# all sun runtimes
-__jvm_sun="$__jvm_sun4 $__jvm_sun5 $__jvm_sun6"
-# Sun version at least 5:
-__jvm_sunmin5="$__jvm_sun5 $__jvm_sun6"
-
-# IBM runtimes. This comes from argouml.sh
-# I'm not quite sure it is still useful, but, we never know !
-__jvm_ibm="/usr/lib/j2*1.[456]-ibm"
-
-
-# Now, free runtimes:
-__jvm_gcj2="/usr/lib/jvm/java-*-gcj-4.* "
-__jvm_gcj5="/usr/lib/jvm/java-1.5*-gcj-4.* "
-__jvm_sablevm="/usr/lib/sablevm" # Probably should be dropped, only in etch
-__jvm_kaffe="/usr/lib/kaffe /usr/lib/kaffe/pthreads /usr/lib/kaffe/jthreads"
-__jvm_icedtea="/usr/lib/jvm/java-7-icedtea" # Probably should be dropped...
-__jvm_cacao="/usr/lib/jvm/cacao"
-__jvm_openjdk6="/usr/lib/jvm/java-6-openjdk"
-__jvm_cacaooj6="/usr/lib/jvm/java-6-cacao/jre"
-
-# And a few aliases
-__jvm_gcj="$__jvm_gcj2"
-__jvm_openjdk="$__jvm_openjdk6 $__jvm_cacaooj6"
-
-# The java* runtimes:
-# -> corresponds to Provides: java6-runtime
-__jvm_java6="$__jvm_openjdk6 $__jvm_cacaooj6 $__jvm_sun6"
-# -> corresponds to Provides: java5-runtime
-__jvm_java5="$__jvm_gcj5 $__jvm_java6 $__jvm_sun5"
-# -> corresponds to Provides: java2-runtime
-__jvm_java2="$__jvm_java5 $__jvm_gcj2"
-
-# current java alternatives
-__jvm_alt=$(readlink /etc/alternatives/java|sed -n 's/\(\/usr\/lib\/jvm\/[^\/]*\)\/.*/\1/p')
-
-# All JVMs
-__jvm_all="$__jvm_default /usr/lib/jvm/* $__jvm_ibm $__jvm_sun4 $__jvm_sablevm $__jvm_kaffe"
-
-# Probably here should come a few meaningful global aliases.
Copied: tags/java-wrappers/0.1.21/jvm-list.sh (from rev 13504, trunk/java-wrappers/jvm-list.sh)
===================================================================
--- tags/java-wrappers/0.1.21/jvm-list.sh (rev 0)
+++ tags/java-wrappers/0.1.21/jvm-list.sh 2011-04-04 19:20:12 UTC (rev 13505)
@@ -0,0 +1,59 @@
+# jvm-list.sh: a list of available JVM and some shortcuts
+# Copyright 2008, 2009 by Vincent Fourmond <fourmond at debian.org>
+#
+# This library is free software; you can redistribute it and/or
+# modify it under the terms of the GNU Lesser General Public
+# License as published by the Free Software Foundation; either
+# version 2.1 of the License, or (at your option) any later version.
+
+# This library is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+# Lesser General Public License for more details.
+
+# You should have received a copy of the GNU Lesser General Public
+# License along with this library; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
+
+# All variables defined here can be used as arguments for the
+# find_java_runtime function if you strip the __jvm_ at the beginning
+# of the variable...
+#
+# They can also be used for the JAVA_FLAVOR environment variable, see
+# java-wrappers(7).
+
+# default runtime
+__jvm_default="/usr/lib/jvm/default-java"
+
+# Sun runtimes
+__jvm_sun6="/usr/lib/jvm/java-6-sun /usr/lib/j2*1.6-sun"
+
+# all sun runtimes
+__jvm_sun="$__jvm_sun6"
+# Sun version at least 5:
+__jvm_sunmin5="$__jvm_sun6"
+
+# Now, free runtimes:
+__jvm_gcj2="/usr/lib/jvm/java-*-gcj-4.* "
+__jvm_gcj5="/usr/lib/jvm/java-1.5*-gcj-4.* "
+__jvm_openjdk6="/usr/lib/jvm/java-6-openjdk"
+
+# And a few aliases
+__jvm_gcj="$__jvm_gcj2"
+__jvm_openjdk="$__jvm_openjdk6"
+
+# The java* runtimes:
+# -> corresponds to Provides: java6-runtime
+__jvm_java6="$__jvm_openjdk6 $__jvm_sun6"
+# -> corresponds to Provides: java5-runtime
+__jvm_java5="$__jvm_gcj5 $__jvm_java6"
+# -> corresponds to Provides: java2-runtime
+__jvm_java2="$__jvm_java5 $__jvm_gcj2"
+
+# current java alternatives
+__jvm_alt=$(readlink /etc/alternatives/java|sed -n 's/\(\/usr\/lib\/jvm\/[^\/]*\)\/.*/\1/p')
+
+# All JVMs
+__jvm_all="$__jvm_default /usr/lib/jvm/*"
+
+# Probably here should come a few meaningful global aliases.
More information about the pkg-java-commits
mailing list