You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tomcat.apache.org by Sean Qiu <se...@gmail.com> on 2006/10/19 09:40:18 UTC

[build]fail message

Hi, everybody.
I am going to build Tomcat by myself by following the step from
http://tomcat.apache.org/tomcat-5.5-doc/building.html.
But unfortunately i failed as the message listed below.
At first i think maybe i miss the ecj*.jar, but after putting the newest one
in the $ANT_HOME/lib, it still fails.
And according the message, the java.lang.NoSuchMethodError, is this problem
caused by different version of ecj???

Thanks for your help.

=====================
init:

build-webapps-precompile:
[jasper2] java.lang.NoSuchMethodError:
org.eclipse.jdt.internal.compiler.CompilationResult.getProblems
()[Lorg/eclipse/jdt/core/compiler/IProblem;
[jasper2] at org.apache.jasper.compiler.JDTCompiler$2.acceptResult(
JDTCompiler.java:345)
[jasper2] at org.eclipse.jdt.internal.compiler.Compiler.compile(
Compiler.java:417)
[jasper2] at org.apache.jasper.compiler.JDTCompiler.generateClass(
JDTCompiler.java:404)
[jasper2] at org.apache.jasper.compiler.Compiler.compile(Compiler.java:297)
[jasper2] at org.apache.jasper.compiler.Compiler.compile(Compiler.java:276)
[jasper2] at org.apache.jasper.compiler.Compiler.compile(Compiler.java:264)
[jasper2] at org.apache.jasper.JspCompilationContext.compile(
JspCompilationContext.java:563)
[jasper2] at org.apache.jasper.servlet.JspServletWrapper.loadTagFile(
JspServletWrapper.java:210)
[jasper2] at org.apache.jasper.compiler.TagFileProcessor.loadTagFile(
TagFileProcessor.java:515)
[jasper2] at org.apache.jasper.compiler.TagFileProcessor.access$000(
TagFileProcessor.java:48)
[jasper2] at
org.apache.jasper.compiler.TagFileProcessor$TagFileLoaderVisitor.visit(
TagFileProcessor.java:566)
[jasper2] at org.apache.jasper.compiler.Node$CustomTag.accept(Node.java
:1441)
[jasper2] at org.apache.jasper.compiler.Node$Nodes.visit(Node.java:2163)
[jasper2] at org.apache.jasper.compiler.Node$Visitor.visitBody(Node.java
:2213)
[jasper2] at org.apache.jasper.compiler.Node$Visitor.visit(Node.java:2219)
[jasper2] at org.apache.jasper.compiler.Node$Root.accept(Node.java:456)
[jasper2] at org.apache.jasper.compiler.Node$Nodes.visit(Node.java:2163)
[jasper2] at org.apache.jasper.compiler.TagFileProcessor.loadTagFiles(
TagFileProcessor.java:584)
[jasper2] at org.apache.jasper.compiler.Compiler.generateJava(Compiler.java
:178)
[jasper2] at org.apache.jasper.compiler.Compiler.compile(Compiler.java:295)
[jasper2] at org.apache.jasper.JspC.processFile(JspC.java:986)
[jasper2] at org.apache.jasper.JspC.execute(JspC.java:1135)
[jasper2] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
[jasper2] at sun.reflect.NativeMethodAccessorImpl.invoke(
NativeMethodAccessorImpl.java:39)
[jasper2] at sun.reflect.DelegatingMethodAccessorImpl.invoke(
DelegatingMethodAccessorImpl.java:25)
[jasper2] at java.lang.reflect.Method.invoke(Method.java:585)
[jasper2] at org.apache.tools.ant.TaskAdapter.execute(TaskAdapter.java:123)
[jasper2] at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java
:275)
[jasper2] at org.apache.tools.ant.Task.perform(Task.java:364)
[jasper2] at org.apache.tools.ant.Target.execute(Target.java:341)
[jasper2] at org.apache.tools.ant.Target.performTasks(Target.java:369)
[jasper2] at org.apache.tools.ant.Project.executeSortedTargets(Project.java
:1216)
[jasper2] at org.apache.tools.ant.helper.SingleCheckExecutor.executeTargets(
SingleCheckExecutor.java:37)
[jasper2] at org.apache.tools.ant.Project.executeTargets(Project.java:1068)
[jasper2] at org.apache.tools.ant.taskdefs.Ant.execute(Ant.java:382)
[jasper2] at org.apache.tools.ant.taskdefs.CallTarget.execute(
CallTarget.java:107)
[jasper2] at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java
:275)
[jasper2] at org.apache.tools.ant.Task.perform(Task.java:364)
[jasper2] at org.apache.tools.ant.Target.execute(Target.java:341)
[jasper2] at org.apache.tools.ant.Target.performTasks(Target.java:369)
[jasper2] at org.apache.tools.ant.Project.executeSortedTargets(Project.java
:1216)
[jasper2] at org.apache.tools.ant.helper.SingleCheckExecutor.executeTargets(
SingleCheckExecutor.java:37)
[jasper2] at org.apache.tools.ant.Project.executeTargets(Project.java:1068)
[jasper2] at org.apache.tools.ant.taskdefs.Ant.execute(Ant.java:382)
[jasper2] at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java
:275)
[jasper2] at org.apache.tools.ant.Task.perform(Task.java:364)
[jasper2] at org.apache.tools.ant.Target.execute(Target.java:341)
[jasper2] at org.apache.tools.ant.Target.performTasks(Target.java:369)
[jasper2] at org.apache.tools.ant.Project.executeSortedTargets(Project.java
:1216)
[jasper2] at org.apache.tools.ant.Project.executeTarget(Project.java:1185)
[jasper2] at org.apache.tools.ant.helper.DefaultExecutor.executeTargets(
DefaultExecutor.java:40)
[jasper2] at org.apache.tools.ant.Project.executeTargets(Project.java:1068)
[jasper2] at org.apache.tools.ant.Main.runBuild(Main.java:668)
[jasper2] at org.apache.tools.ant.Main.startAnt(Main.java:187)
[jasper2] at org.apache.tools.ant.launch.Launcher.run(Launcher.java:246)
[jasper2] at org.apache.tools.ant.launch.Launcher.main(Launcher.java:67)

BUILD FAILED
/home/qbit/harmony/workspace/tomcat2/build.xml:39: The following error
occurred while executing this line:
/home/qbit/harmony/workspace/tomcat2/build/build.xml:830: The following
error occurred while executing this line:
/home/qbit/harmony/workspace/tomcat2/build/build.xml:446:
java.lang.NoSuchMethodError:
org.eclipse.jdt.internal.compiler.CompilationResult.getProblems
()[Lorg/eclipse/jdt/core/compiler/IProblem;


-- 
Sean Qiu

Re: [build]fail message

Posted by Yoav Shapira <yo...@apache.org>.
Hi,


On 10/24/06, Sean Qiu <se...@gmail.com> wrote:
> I have also tried the "ant test".
> It seems that it is based unit test.

I don't use "ant test" and have no time to delve into what it is.  Use
the tester version.

> I find there are only three testing classes and a few testcases.

The tester contains a little more than 100 unit tests, as you can see
from its output when you run it.

> Need any configuration to make the unit test success?

None besides a proper configuration to start with.  Proper meaning
don't put anything in ANT_HOME/lib, on the CLASSPATH environment
variable (though it's ignored anyhow), in JRE_HOME/lib.  Proper
meaning edit build/build.properties.default as build/build.properties
to reflect your environment.  And that's it.

> And what's the difference between "ant run-tester" and "ant test"? Thanks
> again.

See first answer above.

> BTW, when i run "ant test", it will fail for package missing.
> So i add the revelant *jar files from binary into the "javac"'s classpath
> parameter.
> It works, but of course it is the the right way :) Pls correct me.

See first answer above.

Yoav

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org


Re: [build]fail message

Posted by Sean Qiu <se...@gmail.com>.
You are so nice.  :)

And i have tried "ant run-tester"
I find it just call java to run the class.And it's Ok.

I have also tried the "ant test".
It seems that it is based unit test.
But it fails and i then turn off the flag to make it  run regardless of
fail.
I find there are only three testing classes and a few testcases.
Need any configuration to make the unit test success?

And what's the difference between "ant run-tester" and "ant test"? Thanks
again.

BTW, when i run "ant test", it will fail for package missing.
So i add the revelant *jar files from binary into the "javac"'s classpath
parameter.
It works, but of course it is the the right way :) Pls correct me.
I guess maybe it results from the missing of some properties setting.



2006/10/24, Yoav Shapira <yo...@apache.org>:
>
> Hi,
>
> On 10/22/06, Sean Qiu <se...@gmail.com> wrote:
> > Required by my project, i have to put  ecj*.jar in ${ant_home}/lib, i
> just
> > rename it to avoid loading it.
>
> OK, but just so you know, that's a terrible requirement by your
> project that will cause you many headaches.  You should really try to
> get your project to correct this.
>
> > Is there any docs to indicate how to test the src???Thanks for your
> help.
>
> From the top-level build file (the one in build/build.xml), run "ant
> clean run-tester"
>
> Yoav
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
> For additional commands, e-mail: dev-help@tomcat.apache.org
>
>


-- 
Sean Qiu

Re: [build]fail message

Posted by Yoav Shapira <yo...@apache.org>.
Hi,

On 10/22/06, Sean Qiu <se...@gmail.com> wrote:
> Required by my project, i have to put  ecj*.jar in ${ant_home}/lib, i just
> rename it to avoid loading it.

OK, but just so you know, that's a terrible requirement by your
project that will cause you many headaches.  You should really try to
get your project to correct this.

> Is there any docs to indicate how to test the src???Thanks for your help.

>From the top-level build file (the one in build/build.xml), run "ant
clean run-tester"

Yoav

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org


Re: [build]fail message

Posted by Yoav Shapira <yo...@apache.org>.
Hi,
You shouldn't be invoking catalina/build.xml directly.  The top-level
build.xml, the one you want, is in build/build.xml. It will call
catalina/build.xml and others (there are at least 5 build.xml files
involved in a complete Tomcat build) as needed, setting up classpaths
and such.

If you want to see things like the classpath order, simply run Ant
with its debug and/or verbos flags.

Yoav

On 10/19/06, Sean Qiu <se...@gmail.com> wrote:
> For the sake of my unstable network status, i could not download the
> required components at first.
> So i had to download them by hand and rename them as required.So it failed.
> I set a proxy and it works well. :) Thanks you all.
>
> Now i am confused by the catalina/build.xml
> Do I have to add the build.properties by myself ?
>
> 2006/10/19, Remy Maucherat <re...@apache.org>:
> >
> > Yoav Shapira wrote:
> > > You have the wrong version of the Eclipse JDT jar on your classpath.
> >
> > It may be a good idea to package rename JDT as well (evil grin).
> >
> > Rémy
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
> > For additional commands, e-mail: dev-help@tomcat.apache.org
> >
> >
>
>
> --
> Sean Qiu
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org


Re: [build]fail message

Posted by Sean Qiu <se...@gmail.com>.
I find if run ant more than one time, it will represent "Build Success"
sometimes but failed in fact.
What is the classpath loading sequence?
Ant do have download org.apache.jdt.* in /usr/share/java/eclipse/plugins,
and in my ${eclipse_home}/plugins it contains higher version.
And the build.xml say, 3.1.2 or higher version is Ok.
So i think the seqence won't make any difference.

It is strange that it fails for java.lang.NoSuchMethodError.

Any suggestion?

2006/10/20, Sean Qiu <se...@gmail.com>:
>
> For the sake of my unstable network status, i could not download the
> required components at first.
> So i had to download them by hand and rename them as required.So it
> failed.
> I set a proxy and it works well. :) Thanks you all.
>
> Now i am confused by the catalina/build.xml
> Do I have to add the build.properties by myself ?
>
> 2006/10/19, Remy Maucherat <remm@apache.org >:
> >
> > Yoav Shapira wrote:
> > > You have the wrong version of the Eclipse JDT jar on your classpath.
> >
> > It may be a good idea to package rename JDT as well (evil grin).
> >
> > Rémy
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
> > For additional commands, e-mail: dev-help@tomcat.apache.org
> >
> >
>
>
> --
> Sean Qiu




-- 
Sean Qiu

Re: [build]fail message

Posted by Sean Qiu <se...@gmail.com>.
For the sake of my unstable network status, i could not download the
required components at first.
So i had to download them by hand and rename them as required.So it failed.
I set a proxy and it works well. :) Thanks you all.

Now i am confused by the catalina/build.xml
Do I have to add the build.properties by myself ?

2006/10/19, Remy Maucherat <re...@apache.org>:
>
> Yoav Shapira wrote:
> > You have the wrong version of the Eclipse JDT jar on your classpath.
>
> It may be a good idea to package rename JDT as well (evil grin).
>
> Rémy
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
> For additional commands, e-mail: dev-help@tomcat.apache.org
>
>


-- 
Sean Qiu

Re: [build]fail message

Posted by Remy Maucherat <re...@apache.org>.
Yoav Shapira wrote:
> You have the wrong version of the Eclipse JDT jar on your classpath.

It may be a good idea to package rename JDT as well (evil grin).

Rémy

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org


Re: [build]fail message

Posted by Yoav Shapira <yo...@apache.org>.
Hi,
You have the wrong version of the Eclipse JDT jar on your classpath.

Don't put jars in $ANT_HOME/lib, $JRE_HOME/lib, or similar locations.
(That's true for building nearly anything, not just Tomcat).  The
Tomcat build will download them and put them in its own lib directory
for the build, as specificed in build.properties.

Clean up anything you've added to the above directories, run "ant
download" and then "ant" and you should be all set.

Yoav

On 10/19/06, Sean Qiu <se...@gmail.com> wrote:
> Hi, everybody.
> I am going to build Tomcat by myself by following the step from
> http://tomcat.apache.org/tomcat-5.5-doc/building.html.
> But unfortunately i failed as the message listed below.
> At first i think maybe i miss the ecj*.jar, but after putting the newest one
> in the $ANT_HOME/lib, it still fails.
> And according the message, the java.lang.NoSuchMethodError, is this problem
> caused by different version of ecj???
>
> Thanks for your help.
>
> =====================
> init:
>
> build-webapps-precompile:
> [jasper2] java.lang.NoSuchMethodError:
> org.eclipse.jdt.internal.compiler.CompilationResult.getProblems
> ()[Lorg/eclipse/jdt/core/compiler/IProblem;
> [jasper2] at org.apache.jasper.compiler.JDTCompiler$2.acceptResult(
> JDTCompiler.java:345)
> [jasper2] at org.eclipse.jdt.internal.compiler.Compiler.compile(
> Compiler.java:417)
> [jasper2] at org.apache.jasper.compiler.JDTCompiler.generateClass(
> JDTCompiler.java:404)
> [jasper2] at org.apache.jasper.compiler.Compiler.compile(Compiler.java:297)
> [jasper2] at org.apache.jasper.compiler.Compiler.compile(Compiler.java:276)
> [jasper2] at org.apache.jasper.compiler.Compiler.compile(Compiler.java:264)
> [jasper2] at org.apache.jasper.JspCompilationContext.compile(
> JspCompilationContext.java:563)
> [jasper2] at org.apache.jasper.servlet.JspServletWrapper.loadTagFile(
> JspServletWrapper.java:210)
> [jasper2] at org.apache.jasper.compiler.TagFileProcessor.loadTagFile(
> TagFileProcessor.java:515)
> [jasper2] at org.apache.jasper.compiler.TagFileProcessor.access$000(
> TagFileProcessor.java:48)
> [jasper2] at
> org.apache.jasper.compiler.TagFileProcessor$TagFileLoaderVisitor.visit(
> TagFileProcessor.java:566)
> [jasper2] at org.apache.jasper.compiler.Node$CustomTag.accept(Node.java
> :1441)
> [jasper2] at org.apache.jasper.compiler.Node$Nodes.visit(Node.java:2163)
> [jasper2] at org.apache.jasper.compiler.Node$Visitor.visitBody(Node.java
> :2213)
> [jasper2] at org.apache.jasper.compiler.Node$Visitor.visit(Node.java:2219)
> [jasper2] at org.apache.jasper.compiler.Node$Root.accept(Node.java:456)
> [jasper2] at org.apache.jasper.compiler.Node$Nodes.visit(Node.java:2163)
> [jasper2] at org.apache.jasper.compiler.TagFileProcessor.loadTagFiles(
> TagFileProcessor.java:584)
> [jasper2] at org.apache.jasper.compiler.Compiler.generateJava(Compiler.java
> :178)
> [jasper2] at org.apache.jasper.compiler.Compiler.compile(Compiler.java:295)
> [jasper2] at org.apache.jasper.JspC.processFile(JspC.java:986)
> [jasper2] at org.apache.jasper.JspC.execute(JspC.java:1135)
> [jasper2] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> [jasper2] at sun.reflect.NativeMethodAccessorImpl.invoke(
> NativeMethodAccessorImpl.java:39)
> [jasper2] at sun.reflect.DelegatingMethodAccessorImpl.invoke(
> DelegatingMethodAccessorImpl.java:25)
> [jasper2] at java.lang.reflect.Method.invoke(Method.java:585)
> [jasper2] at org.apache.tools.ant.TaskAdapter.execute(TaskAdapter.java:123)
> [jasper2] at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java
> :275)
> [jasper2] at org.apache.tools.ant.Task.perform(Task.java:364)
> [jasper2] at org.apache.tools.ant.Target.execute(Target.java:341)
> [jasper2] at org.apache.tools.ant.Target.performTasks(Target.java:369)
> [jasper2] at org.apache.tools.ant.Project.executeSortedTargets(Project.java
> :1216)
> [jasper2] at org.apache.tools.ant.helper.SingleCheckExecutor.executeTargets(
> SingleCheckExecutor.java:37)
> [jasper2] at org.apache.tools.ant.Project.executeTargets(Project.java:1068)
> [jasper2] at org.apache.tools.ant.taskdefs.Ant.execute(Ant.java:382)
> [jasper2] at org.apache.tools.ant.taskdefs.CallTarget.execute(
> CallTarget.java:107)
> [jasper2] at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java
> :275)
> [jasper2] at org.apache.tools.ant.Task.perform(Task.java:364)
> [jasper2] at org.apache.tools.ant.Target.execute(Target.java:341)
> [jasper2] at org.apache.tools.ant.Target.performTasks(Target.java:369)
> [jasper2] at org.apache.tools.ant.Project.executeSortedTargets(Project.java
> :1216)
> [jasper2] at org.apache.tools.ant.helper.SingleCheckExecutor.executeTargets(
> SingleCheckExecutor.java:37)
> [jasper2] at org.apache.tools.ant.Project.executeTargets(Project.java:1068)
> [jasper2] at org.apache.tools.ant.taskdefs.Ant.execute(Ant.java:382)
> [jasper2] at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java
> :275)
> [jasper2] at org.apache.tools.ant.Task.perform(Task.java:364)
> [jasper2] at org.apache.tools.ant.Target.execute(Target.java:341)
> [jasper2] at org.apache.tools.ant.Target.performTasks(Target.java:369)
> [jasper2] at org.apache.tools.ant.Project.executeSortedTargets(Project.java
> :1216)
> [jasper2] at org.apache.tools.ant.Project.executeTarget(Project.java:1185)
> [jasper2] at org.apache.tools.ant.helper.DefaultExecutor.executeTargets(
> DefaultExecutor.java:40)
> [jasper2] at org.apache.tools.ant.Project.executeTargets(Project.java:1068)
> [jasper2] at org.apache.tools.ant.Main.runBuild(Main.java:668)
> [jasper2] at org.apache.tools.ant.Main.startAnt(Main.java:187)
> [jasper2] at org.apache.tools.ant.launch.Launcher.run(Launcher.java:246)
> [jasper2] at org.apache.tools.ant.launch.Launcher.main(Launcher.java:67)
>
> BUILD FAILED
> /home/qbit/harmony/workspace/tomcat2/build.xml:39: The following error
> occurred while executing this line:
> /home/qbit/harmony/workspace/tomcat2/build/build.xml:830: The following
> error occurred while executing this line:
> /home/qbit/harmony/workspace/tomcat2/build/build.xml:446:
> java.lang.NoSuchMethodError:
> org.eclipse.jdt.internal.compiler.CompilationResult.getProblems
> ()[Lorg/eclipse/jdt/core/compiler/IProblem;
>
>
> --
> Sean Qiu
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org