I want to include a jar file (ant-contrib.jar) in my ant build.xml from within a zip.
How can i do that without unzipping the zip file.
I have tried to use the jarURLConnect.
<property url="jar:file:/D:/testing.zip!/testing/ant-contrib.jar" />
But this gives me a
java.lang.IllegalArgumentException: Malformed \uxxxx encoding.
There is no error if I replace “ant-contrib.jar” with a “test.properties” file.
Can anybody please help..
The
propertytag is for including properties, which would be in a property file. A jar file isn’t a property file. The property docs are pretty clear.You need to unzip the file in order to add it to a classpath, and then actually add it to a classpath: see the path-like structures documentation. It’s not just a property, though.