RE: Small issue with modeler.bat (Win98)

From: Andrus Adamchik (andru..bjectstyle.org)
Date: Fri Oct 29 2004 - 10:20:57 EDT

  • Next message: Mike Kienenberger: "Re: Small issue with modeler.bat (Win98)"

    I am totally ok with modeler-win98.bat if there is no easy way to guess an
    OS version from a batch file. One thin that I found is that on XP "echo
    %OS%" prints "Windows_NT", not sure what it does on Win98.

    Andrus

    > if [ "`uname -s`" = "Windows 98" ]; then
    > ...
    >
    > Oh wait, that won't work. I'd be OK with a separate modeler98-ME.bat
    > file unless someone knows a better solution. (I'm sure there is a better
    > solution, but Mike already knows how poorly I know Windows at that
    > level.)
    >
    > Albert: Might I suggest http://store.apple.com/ ? :-)
    >
    > /dev/mrg
    >
    > -----Original Message-----
    > From: Mike Kienenberger [mailto:mkienen..laska.net]
    > Sent: Friday, October 29, 2004 9:59 AM
    > To: cayenne-use..bjectstyle.org
    > Cc: look..treamyx.com
    > Subject: Re: Small issue with modeler.bat (Win98)
    >
    >
    > Albert <look..treamyx.com> wrote:
    >> I'm just starting to learn Cayenne (1.1, R2). Running modeler.bat on
    >> win98, I need to change the line :
    >>
    >> start "CayenneModeler" "%JAVACMD%" -cp
    > "%CLASSPATH%;%DEFAULT_CLASSPATH%"
    >> %MAIN_CLASS% %*
    >>
    >> (removing "CayenneModeler") to :
    >>
    >> start "%JAVACMD%" -cp "%CLASSPATH%;%DEFAULT_CLASSPATH%" %MAIN_CLASS%
    > %*
    >>
    >> Else, I get "Bad command or file name".
    >>
    >> Running on Win XP is fine with modeler.bat unchanged. I suppose
    > windows
    >> 'start' works differently between os.
    >
    > I'm the one that introduced that problem.
    >
    > http://objectstyle.org/jira/secure/ViewIssue.jspa?key=CAY-99
    >
    > I hadn't realized it broke on Windows 9x/ME.
    >
    > Unfortunately, that change is needed to support spaces in the %JAVACMD%
    > under the Windows NT shell (NT/ 2000/XP).
    >
    > Windows NT (2000 or XP) takes the first argument to be the window title
    > if
    > it's quoted.
    > So start "%JAVACMD%" doesn't work.
    > But if it's unquoted -- start %JAVACMD% -- then spaces aren't handled
    > properly in the path, and, since java is installed by default in
    > "Program
    > Files", that breaks most installations.
    >
    > I'm not certain what a good fix would be yet.
    >
    > I'd rather see the default behavior to support NT-based shells, but at
    > minimum we can add a note in the file for Windows 9x/ME users or we can
    > create a separate 9x bat file.
    >
    > Perhaps I can figure out a way to identify which version of the start
    > command to run.
    >
    > I've reopened and reassigned issue CAY-99 to myself (as my first
    > official
    > act as a committer) and I've appended Albert's comments to it. Albert,
    > if
    > you want, you can go to the issue and assign yourself as a watcher for
    > this
    > issue.
    >
    > -Mike



    This archive was generated by hypermail 2.0.0 : Fri Oct 29 2004 - 10:21:00 EDT