Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
[platform-ant-dev] How do I run the org.eclipse.ant.core plugin in a runtime-workbench?

I'm trying to hack the org.eclipse.ant.core plugin to get it working with 
ant 1.5.  Unfortunately I must be doing something wrong because I can't 
seem to run my local version (unedited even) in a runtime-workbench 
instance.  I use CVS to checkout org.eclipse.ant.core as a project, add 
ECLIPSE_HOME/plugins/org.apache.ant_1.4.1/ant.jar as a build library, 
rebuild the project, "Create Plug-In JARs" from plugin.xml (neccessary?), 
set the Plugin dev preferences for the target platform to have all plugins 
but org.eclipse.ant.core, then Run->Debug As->Runtime-workbench.  The 
workbench instance starts up ok, but when I run a simple build.xml inside 
it, AntRunner fails to instantiate InternalAntRunner - a java.lang.Error 
gets thrown due to the use of the ant classes like Project, etc - I 
printed the stack trace below.   There must be something simple I'm doing 
wrong - probably to do with pointing the running plugin to ant.jar (I _do_ 
do so in the Ant preferences page in the runtime-workbench instance - in 
the debugger I can access the Project class in the display pane no 
problem).  Any help appreciated, 

Matt

java.lang.Error: Unresolved compilation problems: 
        Project cannot be resolved
        BuildException cannot be resolved or is not a type
        Project cannot be resolved (or is not a valid type) for the 
argument project of the method addBuildListeners
        The method createLogger() is undefined for the type 
org.eclipse.ant.internal.core.ant.InternalAntRunner
        BuildListener cannot be resolved or is not a type
        BuildException cannot be resolved or is not a type
        Project cannot be resolved (or is not a valid type) for the 
argument project of the method setProperties
        Project cannot be resolved (or is not a valid type) for the 
argument project of the method setTasks
        BuildException cannot be resolved or is not a type
        Project cannot be resolved (or is not a valid type) for the 
argument project of the method setTypes
        BuildException cannot be resolved or is not a type
        Project cannot be resolved (or is not a valid type) for the 
argument project of the method parseScript
        ProjectHelper cannot be resolved
        Project cannot be resolved or is not a type
        Project cannot be resolved or is not a type
        DemuxOutputStream cannot be resolved or is not a type
        DemuxOutputStream cannot be resolved or is not a type
        Project cannot be resolved (or is not a valid type) for the 
argument project of the method createMonitorBuildListener
        Project cannot be resolved (or is not a valid type) for the 
argument project of the method printTargets
        Target cannot be resolved or is not a type
        Target cannot be resolved or is not a type
        Project cannot be resolved (or is not a valid type) for the 
argument project of the method printTargets
        Project cannot be resolved
        Project cannot be resolved
        BuildLogger cannot be resolved (or is not a valid return type) for 
the method createLogger
        BuildLogger cannot be resolved or is not a type
        BuildLogger cannot be resolved or is not a type
        Project cannot be resolved
        BuildException cannot be resolved or is not a type
        DefaultLogger cannot be resolved or is not a type
        Project cannot be resolved (or is not a valid type) for the 
argument project of the method fireBuildStarted
        BuildEvent cannot be resolved or is not a type
        BuildEvent cannot be resolved or is not a type
        BuildListener cannot be resolved or is not a type
        BuildListener cannot be resolved or is not a type
        Project cannot be resolved (or is not a valid type) for the 
argument project of the method fireBuildFinished
        Project cannot be resolved (or is not a valid type) for the 
argument project of the method logMessage
        Project cannot be resolved or is not a type
        BuildEvent cannot be resolved or is not a type
        BuildEvent cannot be resolved or is not a type
        BuildListener cannot be resolved or is not a type
        BuildListener cannot be resolved or is not a type
        BuildException cannot be resolved (or is not an exception type) 
for the method getAntVersion
        Main cannot be resolved or is not a type
        BuildException cannot be resolved or is not a type
        BuildException cannot be resolved or is not a type
        Project cannot be resolved
        Project cannot be resolved
        Project cannot be resolved
        Project cannot be resolved
        Project cannot be resolved (or is not a valid type) for the 
argument project of the method printHelp
        Project cannot be resolved
        Project cannot be resolved
        Project cannot be resolved

        at java.lang.reflect.Constructor.newInstance(Native Method)
        at 
org.eclipse.ant.internal.core.ant.InternalAntRunner.<init>(InternalAntRunner.java:111)
        at java.lang.Class.newInstance0(Native Method)
        at java.lang.Class.newInstance(Class.java:237)
        at org.eclipse.ant.core.AntRunner.run(AntRunner.java:120)
        at 
org.eclipse.ui.externaltools.internal.core.AntFileRunner.execute(AntFileRunner.java:54)
        at 
org.eclipse.ui.externaltools.internal.core.DefaultRunnerContext.executeRunner(DefaultRunnerContext.java:320)
        at 
org.eclipse.ui.externaltools.internal.core.DefaultRunnerContext.run(DefaultRunnerContext.java:370)
        at 
org.eclipse.ui.externaltools.internal.ui.AntLaunchWizard$1.run(AntLaunchWizard.java:116)
        at 
org.eclipse.jface.operation.ModalContext$ModalContextThread.run(ModalContext.java:98)




Back to the top