compile: serialize: [jruby-serialize] Serializing 8 files to /var/tmp/portage/dev-java/jruby-0.9.8/work/jruby-0.9.8/build/classes/jruby generate-method-classes: [java] ACCESS DENIED mkdir: /root/.jruby [delete] Deleting: /var/tmp/portage/dev-java/jruby-0.9.8/work/jruby-0.9.8/build/__empty.rb jar-jruby: [jar] Building jar: /var/tmp/portage/dev-java/jruby-0.9.8/work/jruby-0.9.8/lib/jruby.jar jar: BUILD SUCCESSFUL Total time: 40 seconds >>> Source compiled. --------------------------- ACCESS VIOLATION SUMMARY --------------------------- LOG FILE = "/var/log/sandbox/sandbox-dev-java_-_jruby-0.9.8-23321.log" mkdir: /root/.jruby -------------------------------------------------------------------------------- Reproducible: Always Steps to Reproduce:
I'm not able to reproduce. Could you please emerge --debug jruby, and attach the log?
(In reply to comment #1) > I'm not able to reproduce. Could you please emerge --debug jruby, and attach > the log? > Turn off FEATURES="userpriv" and you should be able to reproduce.
(In reply to comment #2) > (In reply to comment #1) > > I'm not able to reproduce. Could you please emerge --debug jruby, and attach > > the log? > > > > Turn off FEATURES="userpriv" and you should be able to reproduce. > Another way to reproduce this is to remove the /root/.jruby directory. If you want the emerge to succeed, you can work around the privilege issue by creating the directory yourself (mkdir /root/.jruby).
Just add "addpredict /root/.jruby" in src_compile(). This will silence sandbox but still won't allow the mkdir (which doesn't seem fatal for the compilation anyway). if somebody has FEATURES="-sandbox -userpriv" it will be created but that's his fault :) and it doesn't hurt anyway. BTW there's java-pkg_filter-compiler called in global scope. That's not good, one should use EANT_FILTER_COMPILER variable. But since you will have to create own src_compile() anyway for the addpredict, you can just move the filter-compiler call there too :)
Doing the addpredict is a bit kludgy, since the build process still is trying to create that directory. The issue is that it checks for jruby.home property, and eventually creates it. The offending bit in the build.xml is: <target name="generate-method-classes" depends="serialize"> <touch file="${build.dir}/__empty.rb" verbose="false"/> <java classname="org.jruby.Main" fork="true"> <classpath refid="build.classpath"/> <classpath path="${jruby.classes.dir}"/> <sysproperty key="jruby.dump_invocations" value="${jruby.classes.dir}"/> <arg value="-rjava"/> <arg value="${build.dir}/__empty.rb"/> </java> <delete file="${build.dir}/__empty.rb" quiet="true"/> </target> If you look at other places where they invoke org.jruby.Main, they specify: <jvmarg value="-Djruby.home=${basedir}"/> but just not here. So, for now, I just added that. I'll look into making it more generalized, so you don't have worry about adding that when you invoke org.jruby.Main from the build.xml. Fixed in 0.9.8-r1.