using portage-2.0.38 (also 2.0.37) and ant-1.5, emerge ant (or jedit, I suppose any java app) using ibm-jdk-1.3.1 fails when calling javac: BuildPath: No such file or directory BuildPath: using /opt/ibm-jdk-1.3.1/bin/ex BuildPath: No such file or directory BuildPath: using /opt/ibm-jdk-1.3.1/bi Can't find libjvm.so ... Failed compiling Ant classes ! Running just 'SANDBOX_DISABLE=1 emerge ant' fails equal, while 'FEATURES="-sandbox" emerge ant' runs correctly. Running just 'LD_PRELOAD=/lib/libsandbox.so java' fails the same way, so the root problem seems to be some conflict between sandbox and IBM's java. There are some additional troubles however (and these are the real ones): - running emerge with SANDBOX_DISABLE will make the sandbox to be disabled but it still loads libsandbox.so. - there doesn't seem to be an easy way to disable the sandbox completely from an ebuild script (as SANDBOX_DISABLE is sometimes not enough) - that conflict descibed above is not mentioned anywhere on the gentoo site, in the ebuild scripts, or anywhere on the web. - the merge process just goes on after the crash, installing a half-made package, but apparently it's the fault of ant's build.sh exiting with just an exit on error from bootstrap.sh, so here's a patch to fix that (I suppose it doesn't belong here, but I don't know much about ant, it's just needed for JEdit at which I was about to make a first look): diff -urN jakarta-ant-1.5.orig/bootstrap.sh jakarta-ant-1.5/bootstrap.sh --- jakarta-ant-1.5.orig/bootstrap.sh Thu Oct 3 01:40:50 2002 +++ jakarta-ant-1.5/bootstrap.sh Thu Oct 3 01:45:28 2002 @@ -63,7 +63,7 @@ if [ ! -x "$JAVACMD" ] ; then echo "Error: JAVA_HOME is not defined correctly." echo " We cannot execute $JAVACMD" - exit + exit 1 fi ANT_HOME=. diff -urN jakarta-ant-1.5.orig/build.sh jakarta-ant-1.5/build.sh --- jakarta-ant-1.5.orig/build.sh Thu Oct 3 01:40:50 2002 +++ jakarta-ant-1.5/build.sh Thu Oct 3 01:45:44 2002 @@ -14,13 +14,13 @@ if test ! -f bootstrap/lib/ant.jar -o ! -x bootstrap/bin/ant -o ! -x bootstrap/bin/antRun ; then /bin/sh ./bootstrap.sh + ret=$? + if [ $ret != 0 ]; then + echo Bootstrap FAILED + exit $ret + fi fi -if test ! -f bootstrap/lib/ant.jar -o ! -x bootstrap/bin/ant -o ! -x bootstrap/bin/antRun ; then - echo Bootstrap FAILED - exit -fi - LOCALCLASSPATH=lib/xercesImpl.jar:lib/xml-apis.jar:bootstrap/lib/ant.jar # add in the dependency .jar files DIRLIBS=lib/optional/*.jar
The current sandbox is being replaced in the not-so-distant future. The replacement will fix this problem. In the interim, you'll have to turn off the sandbox totally, as you've discovered. Sorry about the inconvenience; we are working on it, but as the sandbox is such a vital part, it's not very likely the new version will be adequately tested for the 1.4 release, hence it won't make it in.
Fixing this will require more hackery that it's worth. I guess we should just put out an advisory telling people who use the IBM JDK not to enable the sandbox until it is fixed.