885Re: AIMA files for JAVA
- Dec 30, 2010Hi Andrew,
It appears your JAVA_HOME is pointing to a Java Runtime Environment (JRE) and not a Java Development Kit (JDK), which is required to compile Java source files. You can download the latest JDK from:
However, as you are using Eclipse the AIMA-Java download includes default eclipse projects that you can import into your own workspace. You can do this in the following manner:
1. Select 'File->Import...'
2. Select 'General' then 'Existing Projects into Eclipse'.
3. Hit the 'Next >' button.
4. Populate the 'Select root directory:' with the location of the project you want to import, for e.g:
Note: The projects need to be imported in the following order - aima-core, aima-gui, and aimax-osm (you do not require the aima-all project as that is used for creating releases).
5. Hit the 'Finish' button.
6. You may have to clean and rebuild the project in order to remove any warnings etc... you may get on the initial import.
For this to work as with using Ant ensure Eclipse is pointing to a JDK as well. On windows you can check this by opening the menu 'Window->Preferences' and selected 'Java' followed by 'Installed JREs' and ensure a 1.6 JDK is registered and selected.
I hope this helps.
--- In email@example.com, "en9apr" <en9apr@...> wrote:
> I am using eclipse with the JAVA code downloaded from:
> I created a new project in eclipse, loaded the file "build.xml" and then ran ant build.
> I got the following message:
> BUILD FAILED
> C:\Users\Owner\Documents\Downloads\aima-java-1.4.0-OSM-Redesign\aima-core\build.xml:43: Unable to find a javac compiler;
> com.sun.tools.javac.Main is not on the classpath.
> Perhaps JAVA_HOME does not point to the JDK.
> It is currently set to "C:\Program Files\Java\jre6"
> Does anyone know what I should do?
- << Previous post in topic Next post in topic >>