ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Watson, Meg" <>
Subject Question about property name
Date Fri, 21 Apr 2006 12:33:21 GMT

We're (a couple of us here at HP) are in the process of making some
changes to better support Ant on HP's OpenVMS operating system. See 

One of the changes we are making has to do with determining success or
failure based on return value.  On OpenVMS, a return value of 1 (or an
odd value) signifies success, and even numbered return values signify
failure.  Some of our customers rely on this, while others would like us
to act like all the other "Unix-like" platforms.  We'd like to make a
property available that our customers could set to control the behavior.
Are there any guidelines for making up property names?  

We think it should be called something like os.supportVMSExit, which
when set to true would cause the VMS style return values to be used.  By
default, however, the standard Unix-type return values would be used.

At any rate, we have no interest in the actual name/spelling of the
property, so we'd like the Ant dev team's advice.

Just for completeness, here's what we propose...a simple change in to isFailure for this...something like 

    /** Controls whether we honor VMS status or standard Unix exit
status **/
    private static boolean supportVMSExit =
     * Checks whether <code>exitValue</code> signals a failure on the
     * system (OS specific).
     * <p><b>Note</b> that this method relies on the conventions of
     * the OS, it will return false results if the application you are
     * running doesn't follow these conventions.  
     * One notable exception is the Java VM provided by HP for 
     * OpenVMS - it will return 0 if successful (like on any other
     * but this signals a failure on OpenVMS.  On OpenVMS use the
     * property Os.supportVMSExit to have VMS exit semantics honored.
     * @param exitValue the exit value (return code) to be checked.
     * @return <code>true</code> if <code>exitValue</code> signals
    public static boolean isFailure(int exitValue) {
        //on openvms even exit value signals failure;
        // for other platforms nonzero exit value signals failure
        return (Os.isFamily("openvms") && supportVMSExit)
            ? (exitValue % 2 == 0) : (exitValue != 0); 

Thanks for your advice!

Meg Watson
HP OpenVMS Systems Software Group

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message