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 teknokrat <ig...@nomura.com> on 2011/08/08 11:37:07 UTC

how to use namespaces

I am trying to figure out namespace support in Ivy. We have the following issue.
We use 3rd party C++ libraries that we place in our repository (nexus). The
problem is that these libraries all have names like libsomething-c++ and nexus
won't allow characters like '+' in artifact names. As such we have to store them
as libsomething-cpp.

I was hoping that namespaces in Ivy would allow us to convert from one name to
the other. That is to say, I want the following dependency in my Ivy file:

<dependency org="org" name="libsomething-c++" rev="1.0" >
    <artifact name="libsomething-c++" e:classifier="linux" ext="so" type="bin" />
</dependency>

And have Ivy automatically get libsomething-cpp from the repository and
translate it to libsomething-c++. I tried the following in my settings file

<namespaces>
  <namespace name="c++">
     <rule>
	<fromsystem>
	   <src module="libsomething\-c\+\+"/>
	   <dest module="libsomething-cpp"/>
	</fromsystem>
	<tosystem>
	  <src module="libsomething\-cpp"/>
	  <dest module="libsomething-c++"/>			
	</tosystem>
     </rule>
  </namespace>
</namespaces>

But this didn't work. Can anyone tell me if this is possible?

cheers