Re: Out Of Environment Space on Windows 98

From: Albert (look..treamyx.com)
Date: Mon Feb 28 2005 - 07:04:01 EST

  • Next message: Albert: "Re: Out Of Environment Space on Windows 98"

    Cris Daniluk wrote:

    > As an option, you can do a conditional in the batch file to detect
    > Win95/98/ME vs 2k/XP fairly easily by looking at the environment.
    >
    > I have some examples if necessary, but... Who uses Win98 for Java
    > development anyway? :)

    I still use :)

    Sorry for replying late. I have a suggestion.

    In Win98 (as well as other windows version, but only necessary for
    Win98) - we can create a short-cut. Right click on this short-cut you
    can configure the default environment memory, if not configured, is set
    to 'auto' which I think has the environment memory limitation. The
    default env. memory can be configured from 256 up to 4096 (but 512
    should be sufficient).

    With the proper env. memory set, we do not need to have a different
    (shorter) script.

    The short-cut creates a file with .PIF extension. We can pre-create the
    default setting and distribute this file, but rename the file as .XIF or
    something else none .PIF. As we already had a way to detect windows
    version, all we need to do is to rename the file .XIF to .PIF when Win98
    is detected.

    However, there is some limitation..

    1. If the rename script is built into modeler.bat, then the first time
    modeler.bat is run, and Win98 is detected _and_ .XIF exists - it should
    rename the .XIF to .PIF but terminates - with a message to restart
    again. So subsequent run, when .PIF is found (and is Win98) it will run
    as normal.

    2. I think using this method, it will works only if modeler.bat is
    started from Windows Exprorer, and not via command prompt. If started
    via command prompt, the short-cut for command prompt itself should be
    configured with the proper env. memory setting.

    I hope the explanation is clear.

    Albert

    >
    >
    >>-----Original Message-----
    >>From: Andrus Adamchik [mailto:andru..bjectstyle.org]
    >>Sent: Friday, February 11, 2005 1:52 PM
    >>To: cayenne-deve..bjectstyle.org
    >>Subject: Re: Out Of Environment Space on Windows 98
    >>
    >>I think we shouldn't change any of the existing scripts just
    >>so that they
    >>work on Windows 98 ... Who cares! I would simply put an entry
    >>in the FAQ
    >>explaining how to modify the existing script.
    >>
    >>Andrus
    >>
    >>
    >>
    >>
    >>>I'm finally testing Cayenne under Win98 in order to fix this issue:
    >>>
    >>>http://objectstyle.org/jira/secure/ViewIssue.jspa?key=CAY-99
    >>>
    >>>The patch works fine, but I hit another error.
    >>>
    >>>It turns out that Win9x only allows 256 characters by default in the
    >>>environment!
    >>>
    >>>Considering a minimal set of the following, that's 159 characters.
    >>>
    >>>CAYENNE_HOME=..
    >>>MAIN_CLASS=org.objectstyle.cayenne.modeler.Main
    >>>JAVACMD=%JAVA_HOME%\bin\javaw
    >>>DEFAULT_CLASSPATH=%CAYENNE_HOME%\lib\modeler\cayenne-modeler.jar
    >>>
    >>>You also have to add in JAVA_HOME which is going to be a minimum of
    >>>another 25 characters.
    >>>
    >>>So we're looking at around 184 characters JUST for
    >>
    >>cayenne's modeler.bat
    >>
    >>> file.
    >>>
    >>>That means there can't be more than 70 characters in the
    >>
    >>environment to
    >>
    >>>start with.
    >>>My bare-minimum fresh windows 98 install has 170 characters
    >>
    >>defined in
    >>
    >>>the environment.
    >>>
    >>>That only leaves 80 characters, provided my math is right.
    >>>
    >>>I shorted DEFAULT_CLASSPATH to DC and made it work.
    >>>
    >>>Is there a point to making this more Win9x friendly?
    >>>Or should we just document the problem?
    >>>
    >>>-Mike
    >>
    >>
    >>
    >>
    >>
    >
    >

    -- 
    No virus found in this outgoing message.
    Checked by AVG Anti-Virus.
    Version: 7.0.300 / Virus Database: 266.5.1 - Release Date: 2/27/2005
    



    This archive was generated by hypermail 2.0.0 : Mon Feb 28 2005 - 07:06:05 EST