I am trying to install SOLR and running "ant example" The build gets pretty far but then gives an error:
/root/apache-solr-3.2.0/solr/common-build.xml:250: The following error occurred while executing this line:
/root/apache-solr-3.2.0/lucene/contrib/contrib-build.xml:58: The following error occurred while executing this line:
/root/apache-solr-3.2.0/lucene/common-build.xml:298: The following error occurred while executing this line:
/root/apache-solr-3.2.0/lucene/common-build.xml:733: 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 "/usr/lib/jvm/java-1.6.0-openjdk-1.6.0.0.x86_64/jre"
I have explicity set JAVA_HOME (see below)
# echo $JAVA_HOME
/usr/lib/jvm/java-1.6.0-openjdk-1.6.0.0.x86_64/
However the JAVA_HOME when I run ant is showing as /usr/lib/jvm/java-1.6.0-openjdk-1.6.0.0.x86_64/jre instead of # echo $JAVA_HOME /usr/lib/jvm/java-1.6.0-openjdk-1.6.0.0.x86_64/ . I cannot figure out where this is being set. I also set ANT_HOME as it was stated in some other posts that this might fix the issue.
# echo $ANT_HOME
/usr/share/ant/
That does not fix it either.