Ratha
Ratha

Reputation: 9692

" No suitable relative path" in Ant (os: windows)

Im facing above mentioned issue in Ant when i use "manifestclasspath" in my build.xml.

The issue i get in windows is;

No suitable relative path .................

C:\Users\TOSH\Desktop\sampleserver\repository\components\plugins\XmlSchema_1.4.7.wso2v2.jar

My build.xml is as follows;

<path id="jar.classpath">
            <pathelement path="${class.dir}"/>          
            <fileset dir="${basedir}/../../../repository/components/plugins">
                <include name="*.jar"/>
            </fileset>          
    </path>

    <target name="init">
        <mkdir dir="${class.dir}"/>
        <manifestclasspath property="tem.classpath" jarfile="pathing.jar">
            <classpath refid="jar.classpath"/>
        </manifestclasspath> 
        <jar destfile="pathing.jar" basedir="target/classes">
            <manifest>              
                <attribute name="Class-Path" value="${tem.classpath}"/>
            </manifest>
        </jar>
        <path id="javac.classpath">
            <pathelement path="${class.dir}"/>
            <pathelement path="pathing.jar"/>            
        </path>      
    </target>

Anyone know the reason?

Upvotes: 2

Views: 2785

Answers (1)

Stephen Grinyer
Stephen Grinyer

Reputation: 51

I found this with the SimpleStockQuote sample in the tutorial as well. If you modify the build.xml file (for the tutorial, under samples/axis2Client/build.xml) and change the manifestclasspath task to add the attribute maxParentLevels="5" (or some suitable value, the default of 2 is insufficient) that may solve your issue.

Upvotes: 5

Related Questions