Upayavira wrote:
Wouldn't it be better if build.sh just backed up ANT_HOME, unsets it, does it's thing and restores it ? Or am I missing something?


I always thought it did. Don't know why this should prevent it from working. Fancy taking a look?


From build.sh : # ----- Ignore system CLASSPATH variable OLD_CLASSPATH="$CLASSPATH" unset CLASSPATH CLASSPATH="`echo lib/endorsed/*.jar | tr ' ' $S`" export CLASSPATH

# ----- Use Ant shipped with Cocoon. Ignore installed in the system Ant
OLD_ANT_HOME="$ANT_HOME"
ANT_HOME=tools
OLD_ANT_OPTS="$ANT_OPTS"
ANT_OPTS="-Xms32M -Xmx512M -Djava.endorsed.dirs=lib/endorsed"
export ANT_HOME ANT_OPTS

"$ANT_HOME/bin/ant" -logger org.apache.tools.ant.NoBannerLogger -emacs  $@
ERR=$?

# ----- Restore ANT_HOME and ANT_OPTS
ANT_HOME="$OLD_ANT_HOME"
ANT_OPTS="$OLD_ANT_OPTS"
export ANT_HOME ANT_OPTS
unset OLD_ANT_HOME
unset OLD_ANT_OPTS

It does seem to do what i thought it should do.

The Ant website [1] seems to indicate that these problems occur when another ant is somewhere in the classpath. Maybe the call to unset CLASSPATH fails somehow, can someone try checking $? after the unset call?

I don't have a RH system to test this on so i'm just guessing here.

Regards
Jorg

[1] http://ant.apache.org/faq.html#NoClassDefFoundError


--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]



Reply via email to