jkf 2005/03/15 12:55:05 Modified: src/script Tag: ANT_16_BRANCH ant Log: PR: 31245 cygwin part to handle both unix and windows style paths correctly Revision Changes Path No revision No revision 1.38.2.9 +9 -3 ant/src/script/ant Index: ant =================================================================== RCS file: /home/cvs/ant/src/script/ant,v retrieving revision 1.38.2.8 retrieving revision 1.38.2.9 diff -u -r1.38.2.8 -r1.38.2.9 --- ant 15 Mar 2005 15:29:37 -0000 1.38.2.8 +++ ant 15 Mar 2005 20:55:05 -0000 1.38.2.9 @@ -1,6 +1,6 @@ #! /bin/sh -# Copyright 2001-2004 The Apache Software Foundation +# Copyright 2001-2005 The Apache Software Foundation # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -214,6 +214,10 @@ fi # For Cygwin, switch paths to appropriate format before running java +# For PATHs convert to unix format first, then to windows format to ensure +# both formats are supported. Probably this will fail on directories with ; +# in the name in the path. Let's assume that paths containing ; are more +# rare than windows style paths on cygwin. if $cygwin; then if [ "$OS" = "Windows_NT" ] && cygpath -m .>/dev/null 2>/dev/null ; then format=mixed @@ -223,9 +227,11 @@ ANT_HOME=`cygpath --$format "$ANT_HOME"` ANT_LIB=`cygpath --$format "$ANT_LIB"` JAVA_HOME=`cygpath --$format "$JAVA_HOME"` - LOCALCLASSPATH=`cygpath --path --$format "$LOCALCLASSPATH"` + LCP_TEMP=`cygpath --path --unix "$LOCALCLASSPATH"` + LOCALCLASSPATH=`cygpath --path --$format "$LCP_TEMP"` if [ -n "$CLASSPATH" ] ; then - CLASSPATH=`cygpath --path --$format "$CLASSPATH"` + CP_TEMP=`cygpath --path --unix "$CLASSPATH"` + CLASSPATH=`cygpath --path --$format "$CP_TEMP"` fi CYGHOME=`cygpath --$format "$HOME"` fi
--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]