forrest-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Bert Van Kets <>
Subject Re: path space problem
Date Fri, 15 Nov 2002 13:53:23 GMT
There's no need for this.
I have reverse engineered the task  I echoed the command to screen and 
tweaked it till it worked.  The solution is to pass the environment 
variables till the last commend (calling Ant).

This works from a path containing a space when Forrest is deployed in a 
path containing a space!:

"C:\jdk1.3.1_02\bin\java.exe" -classpath 

-Dant.home="%FORREST_HOME%\ant"  -buildfile 
-Dproject.home "%PROJECT_HOME%" -Dforrest.home "%FORREST_HOME%" -emacs 
-logger seed

All I need to do now is get to the point that this command is 
generated.  Shouldn't be too hard.
When this is done, we are completely free of the space problem.

The solution actually lies in the buildup of the paths.  Keeping the paths 
inn the environment variables avoids the problem altogether.  This required 
some changes in the FOR loops though (cd to the jar directory and run the 
FOR there to avoid having the full path in the appended parameter).

I got to run now, will finalize this in an hour or two when I'm home.


At 00:27 16/11/2002 +1100, you wrote:
>On Fri, Nov 15, 2002 at 02:07:11PM +0100, Bert Van Kets wrote:
> > The problem with the Win2K batch file is that parameters are passed
> > through from one batch file to another.  If the path in these
> > parameters can be replaced with environment variables the problem
> > should be solved.  Due to the complexity of the batch calling, I
> > haven't finished the problem solving yet, but I can say that we need to
> > change not only the forrest.bat file but also other bat files (ant.bat
> > etc.)
>Are you testing 0.2rc1 or CVS? 0.2rc1 has:
>call "%ANT_HOME%\bin\ant" ...
>whereas CVS has:
>"%ANT_HOME%\bin\ant" ...
>It was to make debugging easier, but removing the 'call' could solve any
>problems of passing through parameters.
> > One of the problems lies in the fact that the CLASSPATH variable is
> > "built up" and that for some strange reason spaces in the path are
> > replaces by semi colons in the ant.bat file.  I'm still trying to solve
> > this.
>Line 21:
>for %%i in ("%FORREST_HOME%\lib\endorsed\*.jar") do call appendcp.bat %%i
>I think that expands to:
>c:\Program Files\Forrest\... c:\Program Files\Forrest\...
>Which gets tokenized into
>Ie, we would need the individual entries to be quoted:
>"c:\Program Files\Forrest\..." "c:\Program Files\Forrest\..."
>which I've no idea how to do :/
> > Can someone confirm that I can use environment variables in the
> > CLASSPATH (ex. %FORREST_HOME%\lib\endorsed\xml-apis.jar)  if not, how
> > do you define a classpath that contains spaces.  Quotes are out of the
> > question.
> >
> > We are nearing a working version.
>We can delay 0.2 if you think you're near a solution..
> > Bert

View raw message