You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@commons.apache.org by Michael Mehrle <mi...@datasaur.com> on 2003/10/16 23:52:37 UTC
Problems with manifestclasspath task
Let's get right to it:
I'm defining my taskdef as such:
<taskdef name="manifestclasspath" classname="org.apache.commons.hivemind.ant.ManifestClassPath">
<classpath>
<pathelement location="${build.lib}/commons-hivemind-1.0-alpha-2.jar"/>
</classpath>
</taskdef>
... and here's my JAR task:
<!-- =================================================================== -->
<!-- Packages the distribution to a JAR -->
<!-- =================================================================== -->
<target name="jar" depends="dist">
<manifestclasspath directory="${build.home}" property="mani.class.path">
<classpath refid="manifest.class.path"/>
</manifestclasspath>
<jar jarfile="${run.lib}/${app.name}.jar" basedir="${build.classes}">
<include name="**"/>
<manifest>
<attribute name="Built-By" value="${user.name}"/>
<attribute name="Main-Class" value="test.tdg.AllTests"/>
<attribute name="Class-Path" value="${mani.class.path}"/>
</manifest>
</jar>
</target>
... and this is what I'm getting:
BUILD FAILED
java.lang.StringIndexOutOfBoundsException: String index out of range: -1
at java.lang.String.substring(String.java:1444)
at java.lang.String.substring(String.java:1411)
at org.apache.commons.hivemind.ant.ManifestClassPath.execute(ManifestClassPath.java
:138)
at org.apache.tools.ant.Task.perform(Task.java:341)
at org.apache.tools.ant.Target.execute(Target.java:309)
at org.apache.tools.ant.Target.performTasks(Target.java:336)
at org.apache.tools.ant.Project.executeTarget(Project.java:1339)
at org.apache.tools.ant.Project.executeTargets(Project.java:1255)
at org.apache.tools.ant.Main.runBuild(Main.java:609)
at org.apache.tools.ant.Main.start(Main.java:196)
at org.apache.tools.ant.Main.main(Main.java:235)
Total time: 16 seconds
java.lang.StringIndexOutOfBoundsException: String index out of range: -1
at java.lang.String.substring(String.java:1444)
at java.lang.String.substring(String.java:1411)
at org.apache.commons.hivemind.ant.ManifestClassPath.execute(ManifestClassPath.java
:138)
at org.apache.tools.ant.Task.perform(Task.java:341)
at org.apache.tools.ant.Target.execute(Target.java:309)
at org.apache.tools.ant.Target.performTasks(Target.java:336)
at org.apache.tools.ant.Project.executeTarget(Project.java:1339)
at org.apache.tools.ant.Project.executeTargets(Project.java:1255)
at org.apache.tools.ant.Main.runBuild(Main.java:609)
at org.apache.tools.ant.Main.start(Main.java:196)
at org.apache.tools.ant.Main.main(Main.java:235)
String index out of range: -1
Re: [HiveMind] Problems with manifestclasspath task
Posted by Michael Mehrle <mi...@datasaur.com>.
Okay, I tried that (removed the 'build.home' path), and now my jar task just
gets stuck and never exits. If I do a control-c and try to open the jar file
in Winzip it tells me that the file is corrupted.
Any suggestions on what to do?
----- Original Message -----
From: "Howard M. Lewis Ship" <hl...@comcast.net>
To: "'Jakarta Commons Users List'" <co...@jakarta.apache.org>
Sent: Friday, October 17, 2003 11:40 AM
Subject: RE: [HiveMind] Problems with manifestclasspath task
Looking at the code, the problem is that the directory, ${build.home}, is in
the classpath and
referenced as the directory.
That's triggering the bug; I can fix the bug shortly, but in the meantime,
remove ${build.home} from
the manifest.class.path.
--
Howard M. Lewis Ship
Creator, Tapestry: Java Web Components
http://jakarta.apache.org/tapestry
http://jakarta.apache.org/commons/sandbox/hivemind/
http://javatapestry.blogspot.com
> -----Original Message-----
> From: Michael Mehrle [mailto:michael@datasaur.com]
> Sent: Friday, October 17, 2003 2:39 PM
> To: Jakarta Commons Users List
> Subject: Re: [HiveMind] Problems with manifestclasspath task
>
>
> Here it is:
>
> <path id="manifest.class.path">
> <pathelement path="${build.home}"/>
> <pathelement path="${run.lib}" /><!-- images and
> properties files-->
> <fileset dir="${run.lib}">
> <include name="**/*.jar"/>
> </fileset>
> </path>
>
> ----- Original Message -----
> From: "Howard M. Lewis Ship" <hl...@comcast.net>
> To: "'Jakarta Commons Users List'" <co...@jakarta.apache.org>
> Sent: Friday, October 17, 2003 11:07 AM
> Subject: RE: [HiveMind] Problems with manifestclasspath task
>
>
> > I'm curious what your manifest.class.path path looks like.
> >
>
>
> Let's get right to it:
>
> I'm defining my taskdef as such:
>
> <taskdef name="manifestclasspath"
> classname="org.apache.commons.hivemind.ant.ManifestClassPath">
> <classpath>
> <pathelement
> location="${build.lib}/commons-hivemind-1.0-alpha-2.jar"/>
> </classpath>
> </taskdef>
>
> ... and here's my JAR task:
>
> <!--
> ==============================================================
> ===== -->
> <!-- Packages the distribution to a JAR -->
> <!--
> ==============================================================
> ===== -->
> <target name="jar" depends="dist">
> <manifestclasspath directory="${build.home}"
> property="mani.class.path">
> <classpath refid="manifest.class.path"/>
> </manifestclasspath>
> <jar jarfile="${run.lib}/${app.name}.jar" basedir="${build.classes}">
> <include name="**"/>
> <manifest>
> <attribute name="Built-By" value="${user.name}"/>
> <attribute name="Main-Class" value="test.tdg.AllTests"/>
> <attribute name="Class-Path" value="${mani.class.path}"/>
> </manifest>
> </jar>
> </target>
>
> ... and this is what I'm getting:
>
>
> BUILD FAILED
> java.lang.StringIndexOutOfBoundsException: String index out
> of range: -1
> at java.lang.String.substring(String.java:1444)
> at java.lang.String.substring(String.java:1411)
> at
> org.apache.commons.hivemind.ant.ManifestClassPath.execute(Mani
> festClassPath.
> java
> :138)
> at org.apache.tools.ant.Task.perform(Task.java:341)
> at org.apache.tools.ant.Target.execute(Target.java:309)
> at org.apache.tools.ant.Target.performTasks(Target.java:336)
> at
> org.apache.tools.ant.Project.executeTarget(Project.java:1339)
> at
> org.apache.tools.ant.Project.executeTargets(Project.java:1255)
> at org.apache.tools.ant.Main.runBuild(Main.java:609)
> at org.apache.tools.ant.Main.start(Main.java:196)
> at org.apache.tools.ant.Main.main(Main.java:235)
>
> Total time: 16 seconds
> java.lang.StringIndexOutOfBoundsException: String index out
> of range: -1
> at java.lang.String.substring(String.java:1444)
> at java.lang.String.substring(String.java:1411)
> at
> org.apache.commons.hivemind.ant.ManifestClassPath.execute(Mani
> festClassPath.
> java
> :138)
> at org.apache.tools.ant.Task.perform(Task.java:341)
> at org.apache.tools.ant.Target.execute(Target.java:309)
> at org.apache.tools.ant.Target.performTasks(Target.java:336)
> at
> org.apache.tools.ant.Project.executeTarget(Project.java:1339)
> at
> org.apache.tools.ant.Project.executeTargets(Project.java:1255)
> at org.apache.tools.ant.Main.runBuild(Main.java:609)
> at org.apache.tools.ant.Main.start(Main.java:196)
> at org.apache.tools.ant.Main.main(Main.java:235)
> String index out of range: -1
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: commons-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: commons-user-help@jakarta.apache.org
>
---------------------------------------------------------------------
To unsubscribe, e-mail: commons-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: commons-user-help@jakarta.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commons-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: commons-user-help@jakarta.apache.org
RE: [HiveMind] Problems with manifestclasspath task
Posted by "Howard M. Lewis Ship" <hl...@comcast.net>.
Looking at the code, the problem is that the directory, ${build.home}, is in the classpath and
referenced as the directory.
That's triggering the bug; I can fix the bug shortly, but in the meantime, remove ${build.home} from
the manifest.class.path.
--
Howard M. Lewis Ship
Creator, Tapestry: Java Web Components
http://jakarta.apache.org/tapestry
http://jakarta.apache.org/commons/sandbox/hivemind/
http://javatapestry.blogspot.com
> -----Original Message-----
> From: Michael Mehrle [mailto:michael@datasaur.com]
> Sent: Friday, October 17, 2003 2:39 PM
> To: Jakarta Commons Users List
> Subject: Re: [HiveMind] Problems with manifestclasspath task
>
>
> Here it is:
>
> <path id="manifest.class.path">
> <pathelement path="${build.home}"/>
> <pathelement path="${run.lib}" /><!-- images and
> properties files-->
> <fileset dir="${run.lib}">
> <include name="**/*.jar"/>
> </fileset>
> </path>
>
> ----- Original Message -----
> From: "Howard M. Lewis Ship" <hl...@comcast.net>
> To: "'Jakarta Commons Users List'" <co...@jakarta.apache.org>
> Sent: Friday, October 17, 2003 11:07 AM
> Subject: RE: [HiveMind] Problems with manifestclasspath task
>
>
> > I'm curious what your manifest.class.path path looks like.
> >
>
>
> Let's get right to it:
>
> I'm defining my taskdef as such:
>
> <taskdef name="manifestclasspath"
> classname="org.apache.commons.hivemind.ant.ManifestClassPath">
> <classpath>
> <pathelement
> location="${build.lib}/commons-hivemind-1.0-alpha-2.jar"/>
> </classpath>
> </taskdef>
>
> ... and here's my JAR task:
>
> <!--
> ==============================================================
> ===== -->
> <!-- Packages the distribution to a JAR -->
> <!--
> ==============================================================
> ===== -->
> <target name="jar" depends="dist">
> <manifestclasspath directory="${build.home}"
> property="mani.class.path">
> <classpath refid="manifest.class.path"/>
> </manifestclasspath>
> <jar jarfile="${run.lib}/${app.name}.jar" basedir="${build.classes}">
> <include name="**"/>
> <manifest>
> <attribute name="Built-By" value="${user.name}"/>
> <attribute name="Main-Class" value="test.tdg.AllTests"/>
> <attribute name="Class-Path" value="${mani.class.path}"/>
> </manifest>
> </jar>
> </target>
>
> ... and this is what I'm getting:
>
>
> BUILD FAILED
> java.lang.StringIndexOutOfBoundsException: String index out
> of range: -1
> at java.lang.String.substring(String.java:1444)
> at java.lang.String.substring(String.java:1411)
> at
> org.apache.commons.hivemind.ant.ManifestClassPath.execute(Mani
> festClassPath.
> java
> :138)
> at org.apache.tools.ant.Task.perform(Task.java:341)
> at org.apache.tools.ant.Target.execute(Target.java:309)
> at org.apache.tools.ant.Target.performTasks(Target.java:336)
> at
> org.apache.tools.ant.Project.executeTarget(Project.java:1339)
> at
> org.apache.tools.ant.Project.executeTargets(Project.java:1255)
> at org.apache.tools.ant.Main.runBuild(Main.java:609)
> at org.apache.tools.ant.Main.start(Main.java:196)
> at org.apache.tools.ant.Main.main(Main.java:235)
>
> Total time: 16 seconds
> java.lang.StringIndexOutOfBoundsException: String index out
> of range: -1
> at java.lang.String.substring(String.java:1444)
> at java.lang.String.substring(String.java:1411)
> at
> org.apache.commons.hivemind.ant.ManifestClassPath.execute(Mani
> festClassPath.
> java
> :138)
> at org.apache.tools.ant.Task.perform(Task.java:341)
> at org.apache.tools.ant.Target.execute(Target.java:309)
> at org.apache.tools.ant.Target.performTasks(Target.java:336)
> at
> org.apache.tools.ant.Project.executeTarget(Project.java:1339)
> at
> org.apache.tools.ant.Project.executeTargets(Project.java:1255)
> at org.apache.tools.ant.Main.runBuild(Main.java:609)
> at org.apache.tools.ant.Main.start(Main.java:196)
> at org.apache.tools.ant.Main.main(Main.java:235)
> String index out of range: -1
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: commons-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: commons-user-help@jakarta.apache.org
>
---------------------------------------------------------------------
To unsubscribe, e-mail: commons-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: commons-user-help@jakarta.apache.org
Re: [HiveMind] Problems with manifestclasspath task
Posted by Michael Mehrle <mi...@datasaur.com>.
Here it is:
<path id="manifest.class.path">
<pathelement path="${build.home}"/>
<pathelement path="${run.lib}" /><!-- images and properties files-->
<fileset dir="${run.lib}">
<include name="**/*.jar"/>
</fileset>
</path>
----- Original Message -----
From: "Howard M. Lewis Ship" <hl...@comcast.net>
To: "'Jakarta Commons Users List'" <co...@jakarta.apache.org>
Sent: Friday, October 17, 2003 11:07 AM
Subject: RE: [HiveMind] Problems with manifestclasspath task
> I'm curious what your manifest.class.path path looks like.
>
Let's get right to it:
I'm defining my taskdef as such:
<taskdef name="manifestclasspath"
classname="org.apache.commons.hivemind.ant.ManifestClassPath">
<classpath>
<pathelement location="${build.lib}/commons-hivemind-1.0-alpha-2.jar"/>
</classpath>
</taskdef>
... and here's my JAR task:
<!-- =================================================================== -->
<!-- Packages the distribution to a JAR -->
<!-- =================================================================== -->
<target name="jar" depends="dist">
<manifestclasspath directory="${build.home}" property="mani.class.path">
<classpath refid="manifest.class.path"/>
</manifestclasspath>
<jar jarfile="${run.lib}/${app.name}.jar" basedir="${build.classes}">
<include name="**"/>
<manifest>
<attribute name="Built-By" value="${user.name}"/>
<attribute name="Main-Class" value="test.tdg.AllTests"/>
<attribute name="Class-Path" value="${mani.class.path}"/>
</manifest>
</jar>
</target>
... and this is what I'm getting:
BUILD FAILED
java.lang.StringIndexOutOfBoundsException: String index out of range: -1
at java.lang.String.substring(String.java:1444)
at java.lang.String.substring(String.java:1411)
at
org.apache.commons.hivemind.ant.ManifestClassPath.execute(ManifestClassPath.
java
:138)
at org.apache.tools.ant.Task.perform(Task.java:341)
at org.apache.tools.ant.Target.execute(Target.java:309)
at org.apache.tools.ant.Target.performTasks(Target.java:336)
at org.apache.tools.ant.Project.executeTarget(Project.java:1339)
at org.apache.tools.ant.Project.executeTargets(Project.java:1255)
at org.apache.tools.ant.Main.runBuild(Main.java:609)
at org.apache.tools.ant.Main.start(Main.java:196)
at org.apache.tools.ant.Main.main(Main.java:235)
Total time: 16 seconds
java.lang.StringIndexOutOfBoundsException: String index out of range: -1
at java.lang.String.substring(String.java:1444)
at java.lang.String.substring(String.java:1411)
at
org.apache.commons.hivemind.ant.ManifestClassPath.execute(ManifestClassPath.
java
:138)
at org.apache.tools.ant.Task.perform(Task.java:341)
at org.apache.tools.ant.Target.execute(Target.java:309)
at org.apache.tools.ant.Target.performTasks(Target.java:336)
at org.apache.tools.ant.Project.executeTarget(Project.java:1339)
at org.apache.tools.ant.Project.executeTargets(Project.java:1255)
at org.apache.tools.ant.Main.runBuild(Main.java:609)
at org.apache.tools.ant.Main.start(Main.java:196)
at org.apache.tools.ant.Main.main(Main.java:235)
String index out of range: -1
---------------------------------------------------------------------
To unsubscribe, e-mail: commons-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: commons-user-help@jakarta.apache.org
RE: [HiveMind] Problems with manifestclasspath task
Posted by "Howard M. Lewis Ship" <hl...@comcast.net>.
I'm curious what your manifest.class.path path looks like.
--
Howard M. Lewis Ship
Creator, Tapestry: Java Web Components
http://jakarta.apache.org/tapestry
http://jakarta.apache.org/commons/sandbox/hivemind/
http://javatapestry.blogspot.com
> -----Original Message-----
> From: Michael Mehrle [mailto:michael@datasaur.com]
> Sent: Friday, October 17, 2003 1:59 PM
> To: Jakarta Commons Users List
> Subject: Re: [HiveMind] Problems with manifestclasspath task
>
>
> Danke fuer die Hilfe, Christian :-)
>
> ----- Original Message -----
> From: "Christian Essl" <ch...@yahoo.de>
> To: "Jakarta Commons Users List" <co...@jakarta.apache.org>
> Sent: Friday, October 17, 2003 9:09 AM
> Subject: [HiveMind] Problems with manifestclasspath task
>
>
> > I can't answer your question but I resend it with [HiveMind] in the
> > Subject. A thing you should always do. On Fri, 17 Oct 2003 07:42:25
> > -0700, Michael Mehrle <mi...@datasaur.com> wrote:
> >
> > > ----- Original Message ----- From: "Michael Mehrle"
> > > <mi...@datasaur.com>
> > > To: <co...@jakarta.apache.org>
> > > Sent: Thursday, October 16, 2003 2:52 PM
> > > Subject: Problems with manifestclasspath task
> > >
> > >
> > > Let's get right to it:
> > >
> > > I'm defining my taskdef as such:
> > >
> > > <taskdef name="manifestclasspath"
> > > classname="org.apache.commons.hivemind.ant.ManifestClassPath">
> > > <classpath>
> > > <pathelement
> > > location="${build.lib}/commons-hivemind-1.0-alpha-2.jar"/>
> > > </classpath>
> > > </taskdef>
> > >
> > > ... and here's my JAR task:
> > >
> > > <!--
> =================================================================== -
> > >
> > >
> > > ->
> > > <!-- Packages the distribution to a JAR -->
> > > <!--
> =================================================================== -
> > >
> > >
> > > ->
> > > <target name="jar" depends="dist">
> > > <manifestclasspath directory="${build.home}"
> > > property="mani.class.path"> <classpath
> refid="manifest.class.path"/>
> > > </manifestclasspath> <jar jarfile="${run.lib}/${app.name}.jar"
> > > basedir="${build.classes}"> <include name="**"/>
> > > <manifest>
> > > <attribute name="Built-By" value="${user.name}"/>
> > > <attribute name="Main-Class" value="test.tdg.AllTests"/>
> > > <attribute name="Class-Path" value="${mani.class.path}"/>
> > > </manifest>
> > > </jar>
> > > </target>
> > >
> > > ... and this is what I'm getting:
> > >
> > >
> > > BUILD FAILED
> > > java.lang.StringIndexOutOfBoundsException: String index out of
> > > range: -1 at java.lang.String.substring(String.java:1444)
> > > at java.lang.String.substring(String.java:1411)
> > > at
> > >
> org.apache.commons.hivemind.ant.ManifestClassPath.execute(Mani
> festClassPath.
> > >
> > >
> > > java
> > > :138)
> > > at org.apache.tools.ant.Task.perform(Task.java:341)
> > > at org.apache.tools.ant.Target.execute(Target.java:309)
> > > at org.apache.tools.ant.Target.performTasks(Target.java:336)
> > > at org.apache.tools.ant.Project.executeTarget(Project.java:1339)
> > > at org.apache.tools.ant.Project.executeTargets(Project.java:1255)
> > > at org.apache.tools.ant.Main.runBuild(Main.java:609)
> > > at org.apache.tools.ant.Main.start(Main.java:196)
> > > at org.apache.tools.ant.Main.main(Main.java:235)
> > >
> > > Total time: 16 seconds
> > > java.lang.StringIndexOutOfBoundsException: String index out of
> > > range: -1 at java.lang.String.substring(String.java:1444)
> > > at java.lang.String.substring(String.java:1411)
> > > at
> > >
> org.apache.commons.hivemind.ant.ManifestClassPath.execute(Mani
> festClassPath.
> > >
> > >
> > > java
> > > :138)
> > > at org.apache.tools.ant.Task.perform(Task.java:341)
> > > at org.apache.tools.ant.Target.execute(Target.java:309)
> > > at org.apache.tools.ant.Target.performTasks(Target.java:336)
> > > at org.apache.tools.ant.Project.executeTarget(Project.java:1339)
> > > at org.apache.tools.ant.Project.executeTargets(Project.java:1255)
> > > at org.apache.tools.ant.Main.runBuild(Main.java:609)
> > > at org.apache.tools.ant.Main.start(Main.java:196)
> > > at org.apache.tools.ant.Main.main(Main.java:235)
> > > String index out of range: -1
> > >
> > >
> > >
> --------------------------------------------------------------------
> > > -
> > > To unsubscribe, e-mail:
> commons-user-unsubscribe@jakarta.apache.org
> > > For additional commands, e-mail:
> commons-user-help@jakarta.apache.org
> > >
> >
> >
> >
> > --
> > Christian Essl http://jucas.sourceforge.net
> >
> >
> ---------------------------------------------------------------------
> > To unsubscribe, e-mail: commons-user-unsubscribe@jakarta.apache.org
> > For additional commands, e-mail:
> commons-user-help@jakarta.apache.org
> >
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: commons-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: commons-user-help@jakarta.apache.org
>
---------------------------------------------------------------------
To unsubscribe, e-mail: commons-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: commons-user-help@jakarta.apache.org
Re: [HiveMind] Problems with manifestclasspath task
Posted by Michael Mehrle <mi...@datasaur.com>.
Danke fuer die Hilfe, Christian :-)
----- Original Message -----
From: "Christian Essl" <ch...@yahoo.de>
To: "Jakarta Commons Users List" <co...@jakarta.apache.org>
Sent: Friday, October 17, 2003 9:09 AM
Subject: [HiveMind] Problems with manifestclasspath task
> I can't answer your question but I resend it with [HiveMind] in the
> Subject. A thing you should always do. On Fri, 17 Oct 2003 07:42:25 -0700,
> Michael Mehrle <mi...@datasaur.com> wrote:
>
> > ----- Original Message ----- From: "Michael Mehrle"
> > <mi...@datasaur.com>
> > To: <co...@jakarta.apache.org>
> > Sent: Thursday, October 16, 2003 2:52 PM
> > Subject: Problems with manifestclasspath task
> >
> >
> > Let's get right to it:
> >
> > I'm defining my taskdef as such:
> >
> > <taskdef name="manifestclasspath"
> > classname="org.apache.commons.hivemind.ant.ManifestClassPath">
> > <classpath>
> > <pathelement location="${build.lib}/commons-hivemind-1.0-alpha-2.jar"/>
> > </classpath>
> > </taskdef>
> >
> > ... and here's my JAR task:
> >
> > <!--
=================================================================== -
> >
> >
> > ->
> > <!-- Packages the distribution to a JAR -->
> > <!--
=================================================================== -
> >
> >
> > ->
> > <target name="jar" depends="dist">
> > <manifestclasspath directory="${build.home}" property="mani.class.path">
> > <classpath refid="manifest.class.path"/>
> > </manifestclasspath>
> > <jar jarfile="${run.lib}/${app.name}.jar" basedir="${build.classes}">
> > <include name="**"/>
> > <manifest>
> > <attribute name="Built-By" value="${user.name}"/>
> > <attribute name="Main-Class" value="test.tdg.AllTests"/>
> > <attribute name="Class-Path" value="${mani.class.path}"/>
> > </manifest>
> > </jar>
> > </target>
> >
> > ... and this is what I'm getting:
> >
> >
> > BUILD FAILED
> > java.lang.StringIndexOutOfBoundsException: String index out of range: -1
> > at java.lang.String.substring(String.java:1444)
> > at java.lang.String.substring(String.java:1411)
> > at
> >
org.apache.commons.hivemind.ant.ManifestClassPath.execute(ManifestClassPath.
> >
> >
> > java
> > :138)
> > at org.apache.tools.ant.Task.perform(Task.java:341)
> > at org.apache.tools.ant.Target.execute(Target.java:309)
> > at org.apache.tools.ant.Target.performTasks(Target.java:336)
> > at org.apache.tools.ant.Project.executeTarget(Project.java:1339)
> > at org.apache.tools.ant.Project.executeTargets(Project.java:1255)
> > at org.apache.tools.ant.Main.runBuild(Main.java:609)
> > at org.apache.tools.ant.Main.start(Main.java:196)
> > at org.apache.tools.ant.Main.main(Main.java:235)
> >
> > Total time: 16 seconds
> > java.lang.StringIndexOutOfBoundsException: String index out of range: -1
> > at java.lang.String.substring(String.java:1444)
> > at java.lang.String.substring(String.java:1411)
> > at
> >
org.apache.commons.hivemind.ant.ManifestClassPath.execute(ManifestClassPath.
> >
> >
> > java
> > :138)
> > at org.apache.tools.ant.Task.perform(Task.java:341)
> > at org.apache.tools.ant.Target.execute(Target.java:309)
> > at org.apache.tools.ant.Target.performTasks(Target.java:336)
> > at org.apache.tools.ant.Project.executeTarget(Project.java:1339)
> > at org.apache.tools.ant.Project.executeTargets(Project.java:1255)
> > at org.apache.tools.ant.Main.runBuild(Main.java:609)
> > at org.apache.tools.ant.Main.start(Main.java:196)
> > at org.apache.tools.ant.Main.main(Main.java:235)
> > String index out of range: -1
> >
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: commons-user-unsubscribe@jakarta.apache.org
> > For additional commands, e-mail: commons-user-help@jakarta.apache.org
> >
>
>
>
> --
> Christian Essl http://jucas.sourceforge.net
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: commons-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: commons-user-help@jakarta.apache.org
>
---------------------------------------------------------------------
To unsubscribe, e-mail: commons-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: commons-user-help@jakarta.apache.org
[HiveMind] Problems with manifestclasspath task
Posted by Christian Essl <ch...@yahoo.de>.
I can't answer your question but I resend it with [HiveMind] in the
Subject. A thing you should always do. On Fri, 17 Oct 2003 07:42:25 -0700,
Michael Mehrle <mi...@datasaur.com> wrote:
> ----- Original Message ----- From: "Michael Mehrle"
> <mi...@datasaur.com>
> To: <co...@jakarta.apache.org>
> Sent: Thursday, October 16, 2003 2:52 PM
> Subject: Problems with manifestclasspath task
>
>
> Let's get right to it:
>
> I'm defining my taskdef as such:
>
> <taskdef name="manifestclasspath"
> classname="org.apache.commons.hivemind.ant.ManifestClassPath">
> <classpath>
> <pathelement location="${build.lib}/commons-hivemind-1.0-alpha-2.jar"/>
> </classpath>
> </taskdef>
>
> ... and here's my JAR task:
>
> <!-- =================================================================== -
>
>
> ->
> <!-- Packages the distribution to a JAR -->
> <!-- =================================================================== -
>
>
> ->
> <target name="jar" depends="dist">
> <manifestclasspath directory="${build.home}" property="mani.class.path">
> <classpath refid="manifest.class.path"/>
> </manifestclasspath>
> <jar jarfile="${run.lib}/${app.name}.jar" basedir="${build.classes}">
> <include name="**"/>
> <manifest>
> <attribute name="Built-By" value="${user.name}"/>
> <attribute name="Main-Class" value="test.tdg.AllTests"/>
> <attribute name="Class-Path" value="${mani.class.path}"/>
> </manifest>
> </jar>
> </target>
>
> ... and this is what I'm getting:
>
>
> BUILD FAILED
> java.lang.StringIndexOutOfBoundsException: String index out of range: -1
> at java.lang.String.substring(String.java:1444)
> at java.lang.String.substring(String.java:1411)
> at
> org.apache.commons.hivemind.ant.ManifestClassPath.execute(ManifestClassPath.
>
>
> java
> :138)
> at org.apache.tools.ant.Task.perform(Task.java:341)
> at org.apache.tools.ant.Target.execute(Target.java:309)
> at org.apache.tools.ant.Target.performTasks(Target.java:336)
> at org.apache.tools.ant.Project.executeTarget(Project.java:1339)
> at org.apache.tools.ant.Project.executeTargets(Project.java:1255)
> at org.apache.tools.ant.Main.runBuild(Main.java:609)
> at org.apache.tools.ant.Main.start(Main.java:196)
> at org.apache.tools.ant.Main.main(Main.java:235)
>
> Total time: 16 seconds
> java.lang.StringIndexOutOfBoundsException: String index out of range: -1
> at java.lang.String.substring(String.java:1444)
> at java.lang.String.substring(String.java:1411)
> at
> org.apache.commons.hivemind.ant.ManifestClassPath.execute(ManifestClassPath.
>
>
> java
> :138)
> at org.apache.tools.ant.Task.perform(Task.java:341)
> at org.apache.tools.ant.Target.execute(Target.java:309)
> at org.apache.tools.ant.Target.performTasks(Target.java:336)
> at org.apache.tools.ant.Project.executeTarget(Project.java:1339)
> at org.apache.tools.ant.Project.executeTargets(Project.java:1255)
> at org.apache.tools.ant.Main.runBuild(Main.java:609)
> at org.apache.tools.ant.Main.start(Main.java:196)
> at org.apache.tools.ant.Main.main(Main.java:235)
> String index out of range: -1
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: commons-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: commons-user-help@jakarta.apache.org
>
--
Christian Essl http://jucas.sourceforge.net
---------------------------------------------------------------------
To unsubscribe, e-mail: commons-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: commons-user-help@jakarta.apache.org
Problems with manifestclasspath task - anyone??
Posted by Michael Mehrle <mi...@datasaur.com>.
Have not received a single reply - is anyone looking at this?
----- Original Message -----
From: "Michael Mehrle" <mi...@datasaur.com>
To: <co...@jakarta.apache.org>
Sent: Thursday, October 16, 2003 2:52 PM
Subject: Problems with manifestclasspath task
Let's get right to it:
I'm defining my taskdef as such:
<taskdef name="manifestclasspath"
classname="org.apache.commons.hivemind.ant.ManifestClassPath">
<classpath>
<pathelement location="${build.lib}/commons-hivemind-1.0-alpha-2.jar"/>
</classpath>
</taskdef>
... and here's my JAR task:
<!-- =================================================================== -->
<!-- Packages the distribution to a JAR -->
<!-- =================================================================== -->
<target name="jar" depends="dist">
<manifestclasspath directory="${build.home}" property="mani.class.path">
<classpath refid="manifest.class.path"/>
</manifestclasspath>
<jar jarfile="${run.lib}/${app.name}.jar" basedir="${build.classes}">
<include name="**"/>
<manifest>
<attribute name="Built-By" value="${user.name}"/>
<attribute name="Main-Class" value="test.tdg.AllTests"/>
<attribute name="Class-Path" value="${mani.class.path}"/>
</manifest>
</jar>
</target>
... and this is what I'm getting:
BUILD FAILED
java.lang.StringIndexOutOfBoundsException: String index out of range: -1
at java.lang.String.substring(String.java:1444)
at java.lang.String.substring(String.java:1411)
at
org.apache.commons.hivemind.ant.ManifestClassPath.execute(ManifestClassPath.
java
:138)
at org.apache.tools.ant.Task.perform(Task.java:341)
at org.apache.tools.ant.Target.execute(Target.java:309)
at org.apache.tools.ant.Target.performTasks(Target.java:336)
at org.apache.tools.ant.Project.executeTarget(Project.java:1339)
at org.apache.tools.ant.Project.executeTargets(Project.java:1255)
at org.apache.tools.ant.Main.runBuild(Main.java:609)
at org.apache.tools.ant.Main.start(Main.java:196)
at org.apache.tools.ant.Main.main(Main.java:235)
Total time: 16 seconds
java.lang.StringIndexOutOfBoundsException: String index out of range: -1
at java.lang.String.substring(String.java:1444)
at java.lang.String.substring(String.java:1411)
at
org.apache.commons.hivemind.ant.ManifestClassPath.execute(ManifestClassPath.
java
:138)
at org.apache.tools.ant.Task.perform(Task.java:341)
at org.apache.tools.ant.Target.execute(Target.java:309)
at org.apache.tools.ant.Target.performTasks(Target.java:336)
at org.apache.tools.ant.Project.executeTarget(Project.java:1339)
at org.apache.tools.ant.Project.executeTargets(Project.java:1255)
at org.apache.tools.ant.Main.runBuild(Main.java:609)
at org.apache.tools.ant.Main.start(Main.java:196)
at org.apache.tools.ant.Main.main(Main.java:235)
String index out of range: -1
---------------------------------------------------------------------
To unsubscribe, e-mail: commons-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: commons-user-help@jakarta.apache.org