From dglo@hyde.ssec.wisc.edu  Thu Nov 29 15:23:10 2001
Return-Path: <dglo@hyde.ssec.wisc.edu>
Received: from ssec.wisc.edu (ssec.wisc.edu [144.92.108.61])
	by hub.freebsd.org (Postfix) with ESMTP id BFD3B37B417
	for <FreeBSD-gnats-submit@freebsd.org>; Thu, 29 Nov 2001 15:23:08 -0800 (PST)
Received: from hyde.ssec.wisc.edu (root@hyde.ssec.wisc.edu [128.104.109.251])
	by ssec.wisc.edu (8.9.3/8.9.3) with ESMTP id RAA18366
	for <FreeBSD-gnats-submit@freebsd.org>; Thu, 29 Nov 2001 17:23:08 -0600
Received: from hyde.ssec.wisc.edu (localhost [127.0.0.1])
	by hyde.ssec.wisc.edu (8.10.2+Sun/8.10.2) with ESMTP id fATNN3k20011
	for <FreeBSD-gnats-submit@freebsd.org>; Thu, 29 Nov 2001 17:23:03 -0600 (CST)
Message-Id: <200111292323.fATNN3k20011@hyde.ssec.wisc.edu>
Date: Thu, 29 Nov 2001 17:23:03 -0600
From: Dave Glowacki <dglo@ssec.wisc.edu>
Sender: dglo@hyde.ssec.wisc.edu
Reply-To: Dave Glowacki <dglo@ssec.wisc.edu>
To: FreeBSD-gnats-submit@freebsd.org
Subject: 'ant' doesn't work if JAVA_HOME not set
X-Send-Pr-Version: 3.113
X-GNATS-Notify:

>Number:         32383
>Category:       ports
>Synopsis:       'javavm' doesn't work if more than 1 argument is specified
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    sobomax
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Thu Nov 29 15:30:01 PST 2001
>Closed-Date:    Mon Feb 18 00:16:58 PST 2002
>Last-Modified:  Mon Feb 18 00:17:18 PST 2002
>Originator:     Dave Glowacki
>Release:        FreeBSD 4.4-STABLE i386
>Organization:
>Environment:
System: FreeBSD eusebius.glowacki.org 4.4-STABLE FreeBSD 4.4-STABLE #0: Mon Nov 19 15:14:03 CST 2001 dglo@eusebius.glowacki.org:/usr/src/sys/compile/EUSEBIUS i386


	
>Description:
	'javavm' only passes the first argument to the java
	executable.
>How-To-Repeat:
	Run 'javavm -classpath foo:bar baz', and it will print

		-classpath requires class path specification
		Usage: java [-options] class [args...]

	because only '-classpath' is passed to the executable.

>Fix:

Apply the following patch:
--- javavmwrapper/src/javavmwrapper.sh.orig	Mon Nov 26 11:21:16 2001
+++ javavmwrapper/src/javavmwrapper.sh	Thu Nov 29 13:57:17 2001
@@ -25,10 +25,12 @@
 
 tryrunVM () {
     if [ -x "${1}" ]; then
-        exec "${1}" ${2}
+        vm=${1}
+        shift
+        exec "${vm}" "${@}"
     fi
 
-    /bin/echo "${IAM}: warning: couldn't start specified JavaVM - \"${1}\"" >&2
+    /bin/echo "${IAM}: warning: couldn't start specified JavaVM - \"${vm}\"" >&2
 }
 
 registerVM () {
>Release-Note:
>Audit-Trail:
Responsible-Changed-From-To: freebsd-ports->sobomax 
Responsible-Changed-By: petef 
Responsible-Changed-When: Thu Nov 29 15:33:12 PST 2001 
Responsible-Changed-Why:  
Over to maintainer 

http://www.FreeBSD.org/cgi/query-pr.cgi?pr=32383 

From: Dave Glowacki <dglo@hyde.ssec.wisc.edu>
To: Cc: FreeBSD-gnats-submit@FreeBSD.ORG
Subject: Re: ports/32383: 'ant' doesn't work if JAVA_HOME not set 
Date: Thu, 29 Nov 2001 17:31:54 -0600

 Oops, the subject line on this PR should, of course, be:
   'javavm' doesn't work if more than 1 argument is specified
 
 Sorry about that!
 
State-Changed-From-To: open->closed 
State-Changed-By: sobomax 
State-Changed-When: Mon Feb 18 00:16:58 PST 2002 
State-Changed-Why:  
The problem has been fixed. 

http://www.freebsd.org/cgi/query-pr.cgi?pr=32383 
>Unformatted:
