You are viewing a plain text version of this content. The canonical link for it is here.
Posted to ivy-user@ant.apache.org by James Mochel <jm...@clearstorysystems.com> on 2007/02/26 21:05:26 UTC

ivyDE unable to Parse correct ivy.xml file

I discovered something interesting today. IvyDE 1.2.0 appears to be
unable to parse a correct ivy.xml (that uses configurations/include )
such as the following:



<?xml version="1.0" encoding="ISO-8859-1"?>
<?xml-stylesheet type="text/xsl"
href="http://www.jayasoft.fr/org/ivyrep/ivy-doc.xsl"?>

<ivy-module version="1.3">
    <info 
        organisation="clearstory"
        module="css-utils"
        status="integration">
          </info>
          <configurations>
                   <include file="../../common-build/common-
configurations.xml"/> 
          </configurations>
    <publications>
          <artifact name="css-utils" type="jar" ext="jar"/>
          <artifact name="css-utils-test" type="jar" ext="jar"/>
    </publications>                             
          <dependencies>
                   <dependency org="clearstory" name="ems-common" c
onf="build" rev="latest.integration"/> 

                   <dependency org="jboss" name="jboss-j2ee" rev="4.0.0"
conf="build->master(*)"/>
                   <dependency org="sun" name="javamail" rev="1.4"/>
                  <dependency org="sun" name="jaf" rev="1.1"/>
          </dependencies>
</ivy-module>



If the ivy.xml is not already in use IvyDE will not even recognize it
AND if you remove the <include> tag and use the ivy.xml file as a
library in IvyDE it will load correctly BUT the minute the <include> tag
is added back you get the following message:


Parse exception in c:\code\ems-trunk\components\css-util\ivy.xml
problem occurred while parsing ivy file. Message: 
c:\eclipse-installations\3.3M5\eclipse\..\..\common-build\common-configu
rations.xml (The system cannot find the path specified) in
file:/c:/code/ems-trunk/components\css-util\ivy.xml


Which, as you can see, looks like the ivy.xml is being resolved against
the Eclipse installation folder rather than the parent folder of the
ivy.xml file. 

 

The ANT version of the build behaves correctly and finds the
common-configurations.xml file.

 

Any suggestions for how to work around this for now ?

 

Thanks

 

Jim Mochel

 

 



Re: ivyDE unable to Parse correct ivy.xml file

Posted by Xavier Hanin <xa...@gmail.com>.
On 2/26/07, James Mochel <jm...@clearstorysystems.com> wrote:
>
>
> I discovered something interesting today. IvyDE 1.2.0 appears to be
> unable to parse a correct ivy.xml (that uses configurations/include )
> such as the following:
>
>
>
> <?xml version="1.0" encoding="ISO-8859-1"?>
> <?xml-stylesheet type="text/xsl"
> href="http://www.jayasoft.fr/org/ivyrep/ivy-doc.xsl"?>
>
> <ivy-module version="1.3">
>     <info
>         organisation="clearstory"
>         module="css-utils"
>         status="integration">
>           </info>
>           <configurations>
>                    <include file="../../common-build/common-
> configurations.xml"/>
>           </configurations>
>     <publications>
>           <artifact name="css-utils" type="jar" ext="jar"/>
>           <artifact name="css-utils-test" type="jar" ext="jar"/>
>     </publications>
>           <dependencies>
>                    <dependency org="clearstory" name="ems-common" c
> onf="build" rev="latest.integration"/>
>
>                    <dependency org="jboss" name="jboss-j2ee" rev="4.0.0"
> conf="build->master(*)"/>
>                    <dependency org="sun" name="javamail" rev="1.4"/>
>                   <dependency org="sun" name="jaf" rev="1.1"/>
>           </dependencies>
> </ivy-module>
>
>
>
> If the ivy.xml is not already in use IvyDE will not even recognize it
> AND if you remove the <include> tag and use the ivy.xml file as a
> library in IvyDE it will load correctly BUT the minute the <include> tag
> is added back you get the following message:
>
>
> Parse exception in c:\code\ems-trunk\components\css-util\ivy.xml
> problem occurred while parsing ivy file. Message:
> c:\eclipse-installations\3.3M5\eclipse\..\..\common-build\common-configu
> rations.xml (The system cannot find the path specified) in
> file:/c:/code/ems-trunk/components\css-util\ivy.xml
>
>
> Which, as you can see, looks like the ivy.xml is being resolved against
> the Eclipse installation folder rather than the parent folder of the
> ivy.xml file.
>
>
>
> The ANT version of the build behaves correctly and finds the
> common-configurations.xml file.
>
>
>
> Any suggestions for how to work around this for now ?


Ah, damned relative paths. As you may know, relative paths are very well
supported in Ivy, there are several open issues in JIRA about that. I hope
this will be improved in next version.
For the moment, I would recommend to use an absolute path. Remember that you
can use Ivy variables in your ivy file, so your configuration file can be
relative to your ivyconf directory for example:
<include file="${ivy.conf.dir}/common-configurations.xml"/>

- Xavier

Thanks
>
>
>
> Jim Mochel
>
>
>
>
>
>
>