https://issues.apache.org/bugzilla/show_bug.cgi?id=45846

           Summary: Ant 1.7.1 resolves UNC path file imports incorrectly on
                    windows
           Product: Ant
           Version: 1.7.1
          Platform: PC
        OS/Version: Windows XP
            Status: NEW
          Severity: major
          Priority: P2
         Component: Core
        AssignedTo: notifications@ant.apache.org
        ReportedBy: [EMAIL PROTECTED]


Hi,

I have a core build file deployed on a network file system that is accessible
from both windows and unix. This core build file is imported and used by a
number of other project builds that just provide properties to configure the
core build for usage. 

The core build file imports a number of other files containing utility
macrodefs etc. These are deployed in the same directory as the core build (I
use the dirname task to construct the import path for the other files). It uses
UNC style paths to do this, for example:

  <import
file="//u/some/path/accessible/from/windows/and/unix/machines/build.xml"/>

Paths like this were handled without issue in ant 1.6.5. On unix the extra
forward slash was irrelevant and on windows the path seps were flipped by java
to yield a valid UNC path. However, if I run the following import on windows
under a Java 6 VM with ant 1.7.1 I now get this error:

Cannot find build-utils.xml imported from
C:\u\some\path\accessible\from\windows\and\unix\machines\build.xml

I have seen a related problem if I put ant on the path using a UNC path (e.g.
if I deploy my ant install on a network drive). When I run ant I get this
exception.

java.lang.ClassNotFoundException: org.apache.tools.ant.Main
        at java.net.URLClassLoader$1.run(URLClassLoader.java:200)
        at java.security.AccessController.doPrivileged(Native Method)
        at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
        at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
        at java.lang.ClassLoader.loadClass(ClassLoader.java:251)
        at org.apache.tools.ant.launch.Launcher.run(Launcher.java:255)
        at org.apache.tools.ant.launch.Launcher.main(Launcher.java:104)

This goes if I map a network drive to the ant deployment directory and put it
on the path using a path via this drive instead.

Does anyone know what's going one here?

Thanks,

Miles


-- 
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

Reply via email to