home ~ # java -version Picked up _JAVA_OPTIONS: -Djava.nio.use_epoll=true java version "1.4.2-01" Java(TM) 2 Runtime Environment, Standard Edition (build Blackdown-1.4.2-01) Java HotSpot(TM) Client VM (build Blackdown-1.4.2-01, mixed mode) home ~ # emerge servletapi Calculating dependencies ...done! >>> emerge (1 of 1) dev-java/servletapi-2.4-r1 to / >>> md5 src_uri ;-) jakarta-tomcat-5.0.19-src.tar.gz >>> Unpacking source... >>> Unpacking jakarta-tomcat-5.0.19-src.tar.gz to /var/tmp/portage/servletapi-2.4-r1/work tar: A lone zero block at 44682 * Applying gentoo-servletapi-2.4-patch ... [ ok ] >>> Source unpacked. Picked up _JAVA_OPTIONS: -Djava.nio.use_epoll=true Buildfile: jsr154/build.xml prepare: [mkdir] Created dir: /var/tmp/portage/servletapi-2.4-r1/work/jakarta-tomcat-5.0.19-src/jakarta-servletapi-5/jsr154/build [mkdir] Created dir: /var/tmp/portage/servletapi-2.4-r1/work/jakarta-tomcat-5.0.19-src/jakarta-servletapi-5/jsr154/build/classes [mkdir] Created dir: /var/tmp/portage/servletapi-2.4-r1/work/jakarta-tomcat-5.0.19-src/jakarta-servletapi-5/jsr154/build/docs [mkdir] Created dir: /var/tmp/portage/servletapi-2.4-r1/work/jakarta-tomcat-5.0.19-src/jakarta-servletapi-5/jsr154/build/docs/api [mkdir] Created dir: /var/tmp/portage/servletapi-2.4-r1/work/jakarta-tomcat-5.0.19-src/jakarta-servletapi-5/jsr154/build/examples [mkdir] Created dir: /var/tmp/portage/servletapi-2.4-r1/work/jakarta-tomcat-5.0.19-src/jakarta-servletapi-5/jsr154/dist [mkdir] Created dir: /var/tmp/portage/servletapi-2.4-r1/work/jakarta-tomcat-5.0.19-src/jakarta-servletapi-5/jsr154/dist/docs [mkdir] Created dir: /var/tmp/portage/servletapi-2.4-r1/work/jakarta-tomcat-5.0.19-src/jakarta-servletapi-5/jsr154/dist/docs/api [mkdir] Created dir: /var/tmp/portage/servletapi-2.4-r1/work/jakarta-tomcat-5.0.19-src/jakarta-servletapi-5/jsr154/dist/lib [mkdir] Created dir: /var/tmp/portage/servletapi-2.4-r1/work/jakarta-tomcat-5.0.19-src/jakarta-servletapi-5/jsr154/dist/src [mkdir] Created dir: /var/tmp/portage/servletapi-2.4-r1/work/jakarta-tomcat-5.0.19-src/jakarta-servletapi-5/jsr154/dist/examples static: BUILD FAILED java.lang.UnsupportedClassVersionError: jdepend/xmlui/JDepend (Unsupported major.minor version 49.0) Total time: 0 seconds !!! ERROR: dev-java/servletapi-2.4-r1 failed. !!! Function src_compile, Line 31, Exitcode 1 !!! compilation problem !!! If you need support, post the topmost build error, NOT this status message. Reproducible: Always Steps to Reproduce: 1.emerge servletapi Portage 2.0.51.19 (default-linux/x86/2004.2, gcc-3.4.3, glibc-2.3.4.20050125-r0, 2.6.11-gentoo-r3 i686) ================================================================= System uname: 2.6.11-gentoo-r3 i686 Intel(R) Pentium(R) 4 CPU 3.20GHz Gentoo Base System version 1.6.10 Python: dev-lang/python-2.3.5 [2.3.5 (#1, Feb 18 2005, 10:59:12)] dev-lang/python: 2.3.5 sys-devel/autoconf: 2.59-r6, 2.13 sys-devel/automake: 1.7.9-r1, 1.8.5-r3, 1.5, 1.4_p6, 1.6.3, 1.9.5 sys-devel/binutils: 2.15.92.0.2-r6 sys-devel/libtool: 1.5.14 virtual/os-headers: 2.6.8.1-r2 ACCEPT_KEYWORDS="x86" AUTOCLEAN="yes" CFLAGS="-O3 -march=pentium4 -fomit-frame-pointer -pipe -fprefetch-loop-arrays -fforce-addr -falign-functions=4 -funit-at-a-time " CHOST="i686-pc-linux-gnu" CONFIG_PROTECT="/etc /usr/kde/2/share/config /usr/kde/3.3/env /usr/kde/3.3/share/config /usr/kde/3.3/shutdown /usr/kde/3/share/config /usr/lib/X11/xkb /usr/lib/mozilla/defaults/pref /usr/share/config /usr/share/texmf/dvipdfm/config/ /usr/share/texmf/dvips/config/ /usr/share/texmf/tex/generic/config/ /usr/share/texmf/tex/platex/config/ /usr/share/texmf/xdvi/ /var/qmail/control" CONFIG_PROTECT_MASK="/etc/gconf /etc/terminfo /etc/env.d" CXXFLAGS="-O3 -march=pentium4 -fomit-frame-pointer -pipe -fprefetch-loop-arrays -fforce-addr -falign-functions=4 -funit-at-a-time " DISTDIR="/usr/portage/distfiles" FEATURES="autoaddcvs autoconfig ccache distlocks sandbox sfperms" GENTOO_MIRRORS="http://gentoo.ITDNet.net/gentoo" LANG="en_US.utf8" LC_ALL="en_US.utf8" MAKEOPTS="-j3" PKGDIR="/usr/portage/packages" PORTAGE_TMPDIR="/var/tmp" PORTDIR="/usr/portage" PORTDIR_OVERLAY="/usr/local/portage" SYNC="rsync://rsync.gentoo.org/gentoo-portage" USE="x86 X aac aalib acl acpi alsa apache2 arts avi bash-completion berkdb bitmap-fonts cdr crypt cups curl dba doc dvd dvdr emboss encode esd flac font-server foomaticdb fortran gd gdbm gif gnome gpm gstreamer gtk gtk2 guile hal howl imagemagick imlib ipv6 ithreads java jpeg junit kde ldap libg++ libwww mad mikmod mmap mmx motif mozilla mp3 mpeg mysql ncurses nls nptl nvidia oggvorbis opengl pam pdflib perl pic plotutils png postgres pthreads python qt quicktime readline sdl session sharedmem slang spell sse ssl svga tcltk tcpd tetex threads tiff truetype truetype-fonts type1-fonts unicode usb vhosts xml xml2 xv zlib linguas_en" Unset: ASFLAGS, CBUILD, CTARGET, LDFLAGS
Looks like you've build jdepend with java 1.5, which is not good (compiled class files are not downward compatible). Re-emerge with the 1.4 compiler, and do NOT set the system compiler to 1.5.
I am not sure this is the case. AFAIK , java 1.5 outputs java 1.2 compatible class files , by default , although it passes -source=1.5 by default too ( I will look up the docs link ) . I have run Eclipse on 1.4 , while build on 1.5, which seems like a good test-case. Anyway , emerge-ing jdepend ( on 1.4 ) gives me : home ~ # emerge jdepend Calculating dependencies ...done! >>> emerge (1 of 1) dev-java/jdepend-2.8.1 to / >>> md5 src_uri ;-) jdepend-2.8.1.zip >>> Unpacking source... >>> Unpacking jdepend-2.8.1.zip to /var/tmp/portage/jdepend-2.8.1/work >>> Source unpacked. Picked up _JAVA_OPTIONS: -Djava.nio.use_epoll=true Buildfile: build.xml prepare: [mkdir] Created dir: /var/tmp/portage/jdepend-2.8.1/work/jdepend-2.8.1/build compile-src: BUILD FAILED java.lang.UnsupportedClassVersionError: jdepend/xmlui/JDepend (Unsupported major.minor version 49.0) Total time: 0 seconds !!! ERROR: dev-java/jdepend-2.8.1 failed. !!! Function src_compile, Line 30, Exitcode 1 !!! Failed Compiling !!! If you need support, post the topmost build error, NOT this status message.
http://java.sun.com/j2se/1.5.0/docs/tooldocs/solaris/javac.html "the default is to generate class files to be compatible with the JDK 5 VM" Ok , I was wrong about the default output. Any ideas why "emerge jdepend" fails ?
you've compiled certain dependencies with the jdk1.5, that is one of the reasons why it's masked. you can't simply change back now. recompile all packages you've compiled with the jdk1.5 first, afterwards compile servletapi-2.4-r1
Ok. And how do I obtain a list of packages to recompile ?