ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Conor MacNeill" <co...@cognet.com.au>
Subject RE: Problem with Property Task
Date Mon, 10 Jul 2000 10:18:31 GMT
Akbar,

>
> Well, changing C:/ and D:/ to C:\ and D:\ made it work (with ant3.1 and
> classpath concatenation). But I don't understand why. Earlier it
> worked with
> C:/

OK - This is why. Say you are running ant from your C: drive and you have
put in a path of C:/test. The version of translatePath you have been using
converts this to C;\test. which is a path consisting of a directory C, which
probably doesn't exist, and a directory \test. Now since you are running on
C: this resolves to C:\test which is what you wanted but for the wrong
reasons :-)

Now when you have D:/test this is translated to a directory D and a
directory \test which resolves to C:\test which is not what you wanted.

> but when I added D:/ it didn't, and when that is changed to
> C:\ and D:\
> it works :(  Maybe I can try to have a look at the "/" and "\" anomaly and
> send in a patch.
>

In any case I committed a patch on the weekend which means translatePath
will now translate D:/test to D:\test. (If Phil Hanna is reading - you were
right :-)

>
> <javac ...>
>     <classpath>
>         <path value="C:\" />
>         <path value="D:\" />
>         <path value="E:\" />
>         <path value="F:\" />
>     </classpath>
> </javac>
>
> Ugh! This doesn't look too good but it is better than a classpath
> which runs

Thomas Haas has proposed something quite similar and I think there is some
agreement that we will eventualy adopt that as a way of definining paths.

Conor


Mime
View raw message