Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
[pde-dev] org.apache.ant plugin dependency not working

I'm using Eclipse Version: 3.0.0 Build id: 200406251208 to build a plugin to be used in Version: 3.0.1 Build id: 200409161125.

I'm adding the org.apache.ant plugin as one of the required plugins for my plugin, however once my plugin is loaded, the org.apache.ant is not in the list of IPluginPrerequisite[]

 

Here is the snippet from my plugin.xml:

 

   <requires>

      <import plugin="org.apache.ant" version="1.6.2" match="greaterOrEqual" export="true" optional="true"/>

      <import plugin="org.eclipse.ui" export="true"/>

      <import plugin="org.eclipse.core.runtime" export="true"/>

      <import plugin="org.eclipse.ve" export="true"/>

      <import plugin="org.eclipse.ve.cde" export="true"/>

      <import plugin="org.eclipse.ve.jfc" export="true"/>

      <import plugin="org.eclipse.ve.propertysheet" export="true"/>

      <import plugin="org.eclipse.ve.java.core" export="true"/>

      <import plugin="org.eclipse.ant.core" export="true"/>

      <import plugin="org.eclipse.ant.ui" export="true"/>

   </requires>

  

The API that I'm using to the list of prerequisites:

 

            IPluginDescriptor descriptor = XTTPlugin.getDefault().getDescriptor();

            IPluginPrerequisite[] prerequisites = descriptor.getPluginPrerequisites();

            String p = "";

            for (int i = 0; i < prerequisites.length; ++i) {

                        try {

                                    p = p + prerequisites[i].getUniqueIdentifier() + "\n\r";

           

                                    } catch (Exception e) {

                                                e.printStackTrace();

                                    }

                        }          

            }

           

The output of p is:

 

            org.eclipse.ui

            org.eclipse.core.runtime

            org.eclipse.ve

            org.eclipse.ve.cde

            org.eclipse.ve.jfc

            org.eclipse.ve.propertysheet

            org.eclipse.ve.java.core

 

None of the ant plugins were loaded. I think that they should have been in this list.

The reason I need the ant plugin is because I need to use org.apache.tools.ant.Project in my own plugin.

When I do try to invoke the

 

            org.apache.tools.ant.Project proj = new org.apache.tools.ant.Project();

           

Eclipse throws the following Exception in the .log:

 

!ENTRY org.eclipse.ui 4 0 Oct 09, 2004 08:52:03.781

!MESSAGE org/apache/tools/ant/Project

!STACK 0

java.lang.NoClassDefFoundError: org/apache/tools/ant/Project

 

I believe that I'm doing everything correctly; it this a bug or have I missed something?

 

Thank you

 

Tek Wojenski


Back to the top