views:

98

answers:

2

I just downloaded a FOSS (Java) project that I am attempting to build on my machine. I imported the project into Eclipse (it did not have its own .project or .classpath file) and let it build. It built almost all the way. However, I am receiving a number of errors where the compiler is "Unable to resolve [X]" where [X] is any number of org.eclipse.* packages.

So, I browse my filesystem and attempt to bring in the packages that make sense to complete the build (if the error is for org.eclipse.core.runtime.FileLocator, I attempt to bring in org.eclipse.core.runtime_3.5.0v20090525), yet I am still receiving the same errors.

I searched on Google but I am not any farther than I was when I started. Anybody have any suggestions?

Edit: The project is UMLet.

Edit 2: There is a plugin.xml file. Looks as follows:

<?xml version="1.0" encoding="UTF-8"?>
<plugin>
   <extension point="org.eclipse.ui.newWizards">
      <wizard
            name="UMLet diagram"
            icon="icons/umlet_eclipse.gif"
            category="com.umlet.plugin"
            class="com.umlet.plugin.wizards.UMLetNewWizard"
            id="com.umlet.plugin.wizards.UMLetNewWizard">
      </wizard>
   </extension>
   <extension
         point="org.eclipse.ui.editors">
      <editor
            class="com.umlet.plugin.editors.UMLetEditor"
            contributorClass="com.umlet.plugin.editors.UMLetContributor"
            default="false"
            extensions="uxf"
            icon="icons/umlet_eclipse.gif"
            id="com.umlet.plugin.UMLetEditor"
            name="UMLet Editor"/>
   </extension>

</plugin>
+1  A: 

Since UMLet is an Eclipse plug-in/standalone RCP app the most likely cause is that the target platform (Windows -> Preferences -> Plug-in Development -> Target Platform) doesn't have all the required plug-ins that the project expects. The default target is the Eclipse you are running. The missing plug-ins need to be added to the target (i.e. find the missing plug-ins, add them to your Eclipse install, and refresh the target).

Jeremy Raymond
It may be also that your _version_ of Eclipse is different from the one they used, so the version of the plug-ins isn't right for it.
Jeremy Raymond
+1 for a good answer. And, I thought this might be it. However, it seems short-sighted to have plug-in development depend on the installation of your IDE. Would there be any way to find out what versions of the libraries were used (short of me e-mailing the developers, of course)?
JasCav
The list of dependent plug-ins is stored in the manifest file plugin.xml. Did the project have this file? See: http://wiki.eclipse.org/FAQ_What_is_the_plug-in_manifest_file_(plugin.xml)%3F
Jeremy Raymond
A: 
  1. Make sure you use Eclipse PDE (plugin development environment), this will make your life easier with Eclipse-based projects.

  2. Make sure you are using the correct version of Eclipse. Seems that you need 3.5.1. If you are using an older version of Eclipse, download a new one from Eclipse.org (get the PDT edition).

zvikico
While this wasn't the exact answer, it did jog my brain to get me to the right answer. Thanks!
JasCav