You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by Richard Herrell <he...@provide.net> on 2000/11/26 20:04:42 UTC

Sample Project Won't Build

Hi,

I've successfully installed JDK 1.2.2, and Tomcat, and Ant on Red Hat
6.2.  I can compile and run a HelloWorld class with javac, and all of
the samples included with the server work fine.  

However, the sample project won't compile for me.  I've read through the
documentation in doc/appdev/index.html, and I've tried modifying the
build file and project location in various ways, as well as changing my
CLASSPATH environment variable.  but the results are the same.  Below is
a capture of me simply trying to build the project as root in its
default directory (with no modifications).

Any help that can get my machine to build the sample application and
kick start me into a working development environment would be greatly
appreciated.  

Regards,

Richard Herrell


[root@localhost sample]# pwd
/usr/local/jakarta/build/tomcat/doc/appdev/sample
[root@localhost sample]# ./build
Buildfile: build.xml

prepare:

compile:
    [javac] Compiling 1 source files to
/usr/local/jakarta/build/tomcat/webapps/myapp/WEB-INF/classes

BUILD FAILED

java.lang.NoClassDefFoundError: sun/tools/javac/Main
        at
org.apache.tools.ant.taskdefs.Javac.doClassicCompile(Javac.java:525)
        at org.apache.tools.ant.taskdefs.Javac.execute(Javac.java:295)
        at org.apache.tools.ant.Target.execute(Target.java:132)
        at org.apache.tools.ant.Project.runTarget(Project.java:717)
        at org.apache.tools.ant.Project.executeTarget(Project.java:448)
        at org.apache.tools.ant.Project.executeTargets(Project.java:422)
        at org.apache.tools.ant.Main.runBuild(Main.java:279)
        at org.apache.tools.ant.Main.main(Main.java:107)

Total time: 1 seconds
[root@localhost sample]# 

[root@localhost sample]# set 
ANT_HOME=/usr/local/jakarta/jakarta-ant
BASH=/bin/bash
BASH_VERSION=1.14.7(1)
COLUMNS=80
DISPLAY=:0
ENV=/root/.bashrc
EUID=0
HISTFILE=/root/.bash_history
HISTFILESIZE=1000
HISTSIZE=1000
HOME=/root
HOSTNAME=localhost.localdomain
HOSTTYPE=i386
IFS=    

INPUTRC=/etc/inputrc
JAKARTA_HOME=/usr/local/jakarta
JAVA_HOME=/usr/local/jdk
LANG=en_US
LESSOPEN=|/usr/bin/lesspipe.sh %s
LINES=24
LOGNAME=root
LS_COLORS=no=00:fi=00:di=01;34:ln=01;36:pi=40;33:so=01;35:bd=40;33;01:cd=40;33;01:or=01;05;37;41:mi=01;05;37;41:ex=01;32:*.cmd=01;32:*.exe=01;32:*.com=01;32:*.btm=01;32:*.bat=01;32:*.sh=01;32:*.csh=01;32:*.tar=01;31:*.tgz=01;31:*.arj=01;31:*.taz=01;31:*.lzh=01;31:*.zip=01;31:*.z=01;31:*.Z=01;31:*.gz=01;31:*.bz2=01;31:*.bz=01;31:*.tz=01;31:*.rpm=01;31:*.cpio=01;31:*.jpg=01;35:*.gif=01;35:*.bmp=01;35:*.xbm=01;35:*.xpm=01;35:*.png=01;35:*.tif=01;35:
MAIL=/var/spool/mail/root
MAILCHECK=60
MOZILLA_HOME=/opt/netscape
OLDPWD=/usr/local/jakarta
OPTERR=1
OPTIND=1
OSTYPE=Linux
PATH=/bin:/sbin:/usr/bin:/usr/sbin:/usr/local/bin:/usr/local/sbin:/usr/bin/X11:/usr/X11R6/bin:/usr/local/Acrobat4/bin:/usr/local/jdk/bin:/usr/local/jakarta/jakarta-ant/bin:/root/bin
PPID=912
PROMPT_COMMAND=echo -ne "\033]0;${USER}@${HOSTNAME}: ${PWD}\007"
PS1=[\u@\h \W]\$ 
PS2=> 
PS4=+ 
PWD=/usr/local/jakarta/build/tomcat/doc/appdev/sample
SHELL=/bin/bash
SHLVL=1
TERM=xterm
TOMCAT_HOME=/usr/local/jakarta/build/tomcat
UID=0
USER=root
USERNAME=root
_=echo
mc=() 
{ 
    mkdir -p ~/.mc/tmp 2>/dev/null;
    chmod 700 ~/.mc/tmp;
    MC=~/.mc/tmp/mc-$$;
    /usr/bin/mc -P "$@" >"$MC";
    cd "`cat $MC`";
    rm "$MC";
    unset MC
}



-- 
Richard Herrell
http://www.provide.net/~herrell/index.html
e-mail: herrell@provide.net