FreeBSD Bugzilla – Attachment 64643 Details for
Bug 96050
Allow java/javavmwrapper to report the location of the JVM
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
file.diff
file.diff (text/plain), 2.00 KB, created by
Jean-Baptiste Quenot
on 2006-04-19 16:50:15 UTC
(
hide
)
Description:
file.diff
Filename:
MIME Type:
Creator:
Jean-Baptiste Quenot
Created:
2006-04-19 16:50:15 UTC
Size:
2.00 KB
patch
obsolete
>diff -ru javavmwrapper.orig/src/javavm.1 javavmwrapper/src/javavm.1 >--- javavmwrapper.orig/src/javavm.1 Tue Apr 19 00:03:27 2005 >+++ javavmwrapper/src/javavm.1 Wed Apr 19 17:32:22 2006 >@@ -124,6 +124,12 @@ > .Ql 1.5 > and > .Ql 1.5+ . >+.It Ev JAVAVM_PRINT_JAVA_HOME >+When set, find the best suitable JVM and print the corresponding value of >+JAVA_HOME instead of executing the java program. >+.It Ev JAVAVM_PRINT_JAVA_PROGRAM >+When set, find the best suitable JVM and print the path of the Java program >+instead of executing it. > .El > .Sh FILES > .Bl -tag -width indent >diff -ru javavmwrapper.orig/src/javavmwrapper.sh javavmwrapper/src/javavmwrapper.sh >--- javavmwrapper.orig/src/javavmwrapper.sh Fri Nov 4 00:04:40 2005 >+++ javavmwrapper/src/javavmwrapper.sh Wed Apr 19 17:29:22 2006 >@@ -6,6 +6,8 @@ > # They can then be selected from based on environment variables and the > # configuration file. > # >+# Please have a look at the javavm(1) man page for more information. >+# > # ---------------------------------------------------------------------------- > # "THE BEER-WARE LICENSE" (Revision 42, (c) Poul-Henning Kamp): > # Maxim Sobolev <sobomax@FreeBSD.org> wrote this file. As long as you retain >@@ -43,13 +45,23 @@ > tryJavaCommand () { > # Check for the command being executable and exec it if so. > if [ -x "${1}" ]; then >- if [ ! -z "${SAVE_PATH}" ]; then >- export PATH=${SAVE_PATH} >+ if [ -z "$JAVAVM_PRINT_JAVA_HOME" -a -z "$JAVAVM_PRINT_JAVA_PROGRAM" ] ; then >+ if [ ! -z "${SAVE_PATH}" ]; then >+ export PATH=${SAVE_PATH} >+ fi >+ >+ exec "${@}" >+ echo "${IAM}: error: couldn't run specified Java command - \"${1}\"" >&2 >+ exit 1 >+ else >+ if [ -n "$JAVAVM_PRINT_JAVA_HOME" ] ; then >+ echo "${JAVA_HOME}" >+ else >+ echo "${@}" >+ fi >+ exit 0 > fi >- exec "${@}" > fi >- >- echo "${IAM}: warning: couldn't run specified Java command - \"${1}\"" >&2 > } > > #
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 96050
: 64643