On 23 Aug, 00:14, Lew <l...@lewscanon.com> wrote:
> muttley wrote:
> > first I installed java_app_platform_sdk-5_02-linux.bin
>
> That isn't Core Java. That's a Sun JEE container.
>
> You want jdk_6u2_linux_i586.bin instead.
>
> > this shows (after I set alternatives to point to the /opt/SDK/jdk
> > direcrtory)
>
> > [root@squirrel ~]# javac -version
> > javac 1.6.0
> > java shows the same.
>
> Clearly you haven't uninstalled Java, since the install you cite isn't the JDK.
>
> > I have set the following in profile
>
> > CLASSPATH=$JDKHOME:$JDKHOME/lib/tools.jar
>
> Uh, no. Since you set
>
> > JAVA_HOME="/opt/SDK/jdk"
> > JDKHOME=$JAVA_HOME
>
> then $JDKHOME is the root of the installation, not the root of a classpath.
>
> You also don't need to include Java itself in its own classpath.
>
> > JREHOME=$JAVA_HOME/jre
> > JFCHOME=$JAVA_HOME/jfc
> > JRECP=$JREHOME/lib/rt.jar
>
> > CATALINA_HOME=/usr/share/tomcat6
>
> > export JAVA_HOME JDKHOME JREHOME JFCHOME JRECP CLASSPATH CATALINA_HOME
>
> > tomcat6.conf: -
> > JAVA_HOME="/opt/SDK/jdk"
>
> Why declare this both places?
>
> > # Where your tomcat installation lives
> > CATALINA_BASE="/usr/share/tomcat6"
> > CATALINA_HOME="/usr/share/tomcat6"
>
> Again, why declare it both places?
>
> > JASPER_HOME="/usr/share/tomcat6"
> > CATALINA_TMPDIR="/var/tmp/tomcat6"
>
> > The logs give no indication why it fails it just keeps saying that it
> > can't find a compiler.
>
> Probably because you haven't set up /usr/bin/java or else included
> $JAVA_HOME/bin in your PATH.
>
> In my Linux I've run:
>
> alternatives --install \
> /usr/java/java jdk /opt/java/jdk1.6.0_02 1600 \
> --slave /usr/java/jre jre /opt/java/jdk1.6.0_02/jre \
> --slave /usr/bin/java java /opt/java/jdk1.6.0_02/bin/java \
> --slave /usr/bin/rmiregistry rmiregistry \
> /opt/java/jdk1.6.0_02/bin/rmiregistry
>
> That ensures that "java" is in my path. You could extend that to include "javac".
>
> --
> Lew
Thank you all for your constructive comments.
It turns out after I tried all this and more, that there is a file in
the tomcat6 directory
/lib called jasper-jdt.jar that tells it to use the [standard] eclipse
jdt compiler,
This was *missing* from the rpm based installation I loaded. I loaded
the binary distro from apache and hey presto the sample jps compile,
and so does my (ha, ha) simple five minute jsp to test file upload
speeds.
I did r the fm, (
http://tomcat.apache.org/tomcat-6.0-doc/jasper-
howto.html) but the relevant clue was on using alternative compilers
as there is NO default one. If this jar is missing, and there is no
ant jar, the tomcat install is simply unable to compile, and won't
tell you why.
I'll forward this message to the RPM packager.
Kevin.