I have a number of top level modules in an ear that I want the war to be able to access but I do not want them included in the libs folder as other modules also use them and I end up with classloader issues. Typically what I have done to remedy this is to include the modules required in a Class-Path variable in the war manifest. I have modified the war plugin to check the war's dependencies for the a manifest.classpath property and I want to concatenate the list of the matching libs into a jelly variable that I can use to add a manifest property as follows
<j:set var="manifestclasspath" value="" scope="parent"/> <j:forEach var="lib" items="${pom.artifacts}"> <j:set var="dep" value="${lib.dependency}"/> <j:if test="${dep.getProperty('manifest.classpath') != null}"> <echo>Adding ${lib.name} to Class-Path</echo> <j:set var="manifestclasspath" value="${manifestClasspath} ${lib.name}" scope="parent"/> </j:if> </j:forEach> <ant:manifest> <ant:attribute name="Built-By" value="${user.name}" /> <ant:section name="${pom.package}"> <ant:attribute name="Specification-Title" value="${pom.artifactId}" /> <ant:attribute name="Specification-Version" value="${pom.currentVersion}" /> <ant:attribute name="Specification-Vendor" value="${pom.organization.name}" /> <ant:attribute name="Implementation-Title" value="${pom.package}" /> <ant:attribute name="Implementation-Version" value="${pom.currentVersion}" /> <ant:attribute name="Implementation-Vendor" value="${pom.organization.name}" /> </ant:section> <ant:attribute name="Class-Path" value="${manifestclasspath}" /> </ant:manifest> Although it finds and iterates through each of the marked dependencies fine, resetting the manifestclasspath variable to add the new addition <j:set var="manifestclasspath" value="${manifestClasspath} ${lib.name}" scope="parent"/> doesn't seem to work as it doesn't seem to resolve the manifestclasspath variable and just overwrites the previous contents, leaving only the last dependency in the variable. Is there any way to build up a list like this? Any suggestions would be greatly appreciated. Thanks in advance Stephen ------------------------------------ Stephen Gargan, IT Engineer [EMAIL PROTECTED] ------------------------------------