... checking whether to build shared libraries... yes checking whether to build static libraries... yes checking whether -lc should be explicitly linked in... no creating libtool checking SOSUFFIX from libtool... so checking for javac... no checking for gcj... gcj -C checking if gcj -C works... yes checking for jar... no configure: error: no acceptable jar program found in $PATH !!! ERROR: sys-libs/db-4.0.14 failed. !!! Function src_compile, Line 45, Exitcode 1 !!! (no error message) ------------------------------------------------------------- Portage 2.0.48-r7 (default-x86-1.4, gcc-3.2.3, glibc-2.3.2-r1) ================================================================= System uname: 2.4.20-gaming-r5 i686 AMD Athlon(tm) Processor GENTOO_MIRRORS="http://gentoo.linux.no/" CONFIG_PROTECT="/etc /var/qmail/control /usr/share/config /usr/kde/2/share/config /usr/kde/3/share/config /usr/X11R6/lib/X11/xkb /usr/share/texmf/tex/generic/config/ /usr/share/texmf/tex/platex/config/" CONFIG_PROTECT_MASK="/etc/ethereal /etc/gnome-vfs-2.0 /etc/gtk-2.0 /etc/init.d /etc/pam.d /etc/postfix/sample /etc/sound /etc/X11/app-defaults /etc/X11/gdm /etc/X11/rstart /etc/X11/serverconfig /etc/X11/Sessions /etc/X11/starthere /etc/X11/sysconfig /etc/X11/xdm /etc/X11/xinit /etc/X11/xkb /etc/gconf /etc/env.d" PORTDIR="/usr/local/home/agriffis/portage" DISTDIR="/usr/distfiles" PKGDIR="/usr/portage/packages" PORTAGE_TMPDIR="/var/tmp" PORTDIR_OVERLAY="" USE="x86 oss 3dnow apm avi crypt cups encode foomaticdb gif jpeg mad mikmod mmx mpeg ncurses nls pdflib png quicktime spell truetype xml2 xmms xv zlib gtkhtml alsa gdbm berkdb readline tetex bonobo tcltk java guile X sdl tcpd pam libwww ssl imlib oggvorbis gnome gtk qt opengl mozilla cdr scanner -arts -esd -gpm -kde -motif -slang -svga cscope decss dvd gtk2 imap lcms libg++ mozcalendar ofx pda perl python ruby tiff wmf" COMPILER="gcc3" CHOST="i686-pc-linux-gnu" CFLAGS="-mcpu=athlon-xp -O3 -pipe" CXXFLAGS="-mcpu=athlon-xp -O3 -pipe" ACCEPT_KEYWORDS="x86 ~x86" MAKEOPTS="-j4" AUTOCLEAN="yes" SYNC="rsync://rsync.gentoo.org/gentoo-portage" FEATURES="sandbox ccache distcc cvs keepwork userpriv usersandbox"
Can you give us an output of java-config --list-available-vms ??
Your useflags specify java support, but apparently it is not available. Please specify the right jdk with java-config and then run rc-update
I have same problem: $ java-config --list-available-vms [blackdown-jdk-1.4.1] Blackdown JDK 1.4.1 (/etc/env.d/java/20blackdown-jdk-1.4.1) () $ cat /etc/env.d/java/20blackdown-jdk-1.4.1 # Copyright 1999-2002 Gentoo Technologies, Inc. # Distributed under the terms of the GNU General Public License, v2 or later # Author: Karl Trygve Kalleberg # Maintainer: Tools Team <tools@gentoo.org> # $Header: /home/cvsroot/gentoo-x86/dev-java/blackdown-jdk/files/blackdown-jdk-1.4.1,v 1.1 2003/02/18 10:05:00 cretin Exp $ VERSION="Blackdown JDK 1.4.1" JAVA_HOME=/opt/blackdown-jdk-1.4.1 CLASSPATH=/opt/blackdown-jdk-1.4.1/jre/lib/rt.jar:. JDK_HOME=/opt/blackdown-jdk-1.4.1 JAVAC=${JAVA_HOME}/bin/javac ADDPATH="${JAVA_HOME}/bin:${JAVA_HOME}/jre/bin" ADDLDPATH="/opt/blackdown-jdk-1.4.1/jre/lib/i386/:/opt/blackdown-jdk-1.4.1/jre/lib/i386/native_threads/" MANPATH=/opt/blackdown-jdk-1.4.1/man ENV_VARS="JAVA_HOME CLASSPATH JDK_HOME JAVAC ADDPATH ADDLDPATH MANPATH"
As root: - Run java-config --set-system-vm=blackdown-jdk-1.4.1. - Do source /etc/profile - emerge db
It used to be the case that emerging the first jdk or jre automatically set the necessary java settings for that jdk/jre. Did that go away by design, and should it have?
Theres a problem with setting the java VM, im still lokking at it, but i dont have enought time to work on it, and also finish the new java-config that should fix some bugs that the old version has. If anyone its interested in helping out on that issue, should be great, then contact me and i can guide you through some of the issues of this.
FYI, I have USE=java but I've never intentionally emerged anything java related. My assumption is that things should "just work" in that case, not requiring any additional commands from me. I'm willing to enter some extra java-config commands to repair my own installation, but IMHO it shouldn't be considered a resolution to this bug. # java-config --list-available-vms [blackdown-jre-1.4.1] Blackdown JRE 1.4.1 (/etc/env.d/java/20blackdown-jre-1.4.1) (*) [blackdown-jdk-1.4.1] Blackdown JDK 1.4.1 (/etc/env.d/java/20blackdown-jdk-1.4.1) () # java-config --set-system-vm=blackdown-jdk-1.4.1 At this point emerging db-4.0.14 works correctly. Thanks! Why didn't it work when set to the JRE?
Its because you need a JDK to compile JRE doesnt have javac (Java Compiler) so maybe thats the problem. Also i think its caused cause your default VM its a JRE and not JDK. I dont know how we can solve this if the user by default has a JRE. Remove JRE's from portage and use JDK for everyone, in the end the difference is that one has javac and the other no. Suggestions ???
*** Bug 27884 has been marked as a duplicate of this bug. ***
I'm having the exact same problem. The JRE was previously installed as some dependency, and was thus selected as my VM. The work-around worked for me.
For what it's worth: Comment #7 got me through the problem. Thank you very much! Ever since I got Gentoo1.4 I've never emerged anything Java-related but still somehow I had Blackdown's JDK and JRE without my SPECIFIC knowledge (I had to look around to find out. If I we're a novice maybe I'd never find out.)
I've run into the same problem myself. On my personal machines, the system-vm was set = blackdown-jdk-1.4.1. However, on my mother's machine, the system-vm was set = blackdown-jre-1.4.1. This is strange to me because I built all these systems and there should be no significant differences. And of course, any ebuild requiring the use of the java compiler (JAVAC) would not run on her machine. I fixed it by using java-config to set/reset from jre to jdk. What I don't understand is 1} Why her machine was using jre to begin with. 2} The error message is about not being able to find a valid 'jar' file. CLASSPATH is identical between the jre and jdk environment settings. The message should refer to a lack of JAVAC. 3} If you're a java developer {I'm not} and you set user-vm to java-jdk, shouldn't the JAVAC environmental variable be added to your environment? It wasn't during my testing of java-config. :-)
*** Bug 30560 has been marked as a duplicate of this bug. ***
*** Bug 31443 has been marked as a duplicate of this bug. ***
I've just noticed the same problem, and was able to compile and emerge db by selecting a JDK rather than a JRE as my vm. The problem that remains, however, seems to be that the db ebuild should not depend on the user's currently selected vm; it should be able to find the path to a JDK so it can use javac, jar, etc. Just because a user has a certain JRE selected as their preferred vm doesn't mean the programs that the db ebuild wants to use aren't available to it, right? So a proposed solution involves looking in /etc/env.d/java/ for a JDK and grabbing its JDK_HOME to use in the ebuild's PATH. It would then find 'jar' and happily build. An alternative would be to exit with a message asking the user to select a JDK and re-try the emerge.
Created attachment 19508 [details] Updated ebuild to build properly when a JRE is selected as the user's current Java VM. (db-4.0.14-r2) This updated ebuild (db-4.0.14-r2) checks /etc/env.d/java/ for an installed JDK to use for building if USE=java is defined. Previously, the build would die in ./configure if the user's JDK wasn't in the $PATH. Hopefully this functionality will eventually be available in java-config, see Bug <a href="http://bugs.gentoo.org/show_bug.cgi?id=30562">30562</a>.
Created attachment 19509 [details] Updated ebuild to build properly when a JRE is selected as the user's Java VM (db-4.1.25) Same as last comment, except this ebuild is for db-4.1.25.
Created attachment 19510 [details] Updated ebuild to build properly when a JRE is selected as the user's Java VM (db-4.1.25_p1-r1) This is a newer ebuild than db-4.1.25. Didn't catch that at first.
*** Bug 28529 has been marked as a duplicate of this bug. ***
*** Bug 31779 has been marked as a duplicate of this bug. ***
The steps provided here do not clear up the issue I have building db. On a machine which I have attempted to have a non-X box because it is a firewall I get an error about db.jar: gcc -c -I. -I../dist/../include -I../dist/../include_auto -D_GNU_SOURCE -D_REENTRANT -I/opt/blackdown-jdk-1.4.1/include -I/opt/blackdown-jdk-1.4.1/include/linux -march=pentium2 -O3 -pipe ../dist/../common/util_sig.c -fPIC -DPIC -o .libs/util_sig.lo cd ./classes && jar cf ../db.jar com/sleepycat/db make: *** [db.jar] Error 137 make: *** Waiting for unfinished jobs.... I only have one jdk installed: storri@firewall storri $ java-config --list-available-vms [blackdown-jdk-1.4.1] "Blackdown JDK 1.4.1" (/etc/env.d/java/20blackdown-jdk-1.4.1) * The USE flags are: storri@firewall storri $ sudo emerge info Portage 2.0.49-r15 (default-x86-1.4, gcc-3.2.3, glibc-2.3.2-r3, 2.4.20-gentoo-r9) ================================================================= System uname: 2.4.20-gentoo-r9 i686 Pentium II (Deschutes) Gentoo Base System version 1.4.3.10p1 distcc 2.11.1 i586-pc-linux-gnu (protocols 1 and 2) (default port 3632) [disabled] ccache version 2.3 [enabled] ACCEPT_KEYWORDS="x86" AUTOCLEAN="yes" CFLAGS="-march=pentium2 -O3 -pipe" CHOST="i586-pc-linux-gnu" COMPILER="gcc3" CONFIG_PROTECT="/etc /var/qmail/control /usr/share/config /usr/kde/2/share/config /usr/kde/3/share/config /var/bind" CONFIG_PROTECT_MASK="/etc/gconf /etc/env.d" CXXFLAGS="-march=pentium2 -O3 -pipe" DISTDIR="/usr/portage/distfiles" FEATURES="sandbox ccache autoaddcvs" GENTOO_MIRRORS="http://gentoo.oregonstate.edu http://distro.ibiblio.org/pub/Linux/distributions/gentoo" MAKEOPTS="-j2" PKGDIR="/usr/portage/packages" PORTAGE_TMPDIR="/var/tmp" PORTDIR="/usr/portage" PORTDIR_OVERLAY="" SYNC="rsync://rsync.namerica.gentoo.org/gentoo-portage" USE="x86 apm arts crypt encode foomaticdb gif jpeg libg++ libwww mad mikmod mmx ncurses nls pdflib png spell svga xml2 zlib gdbm berkdb slang readline mysql gpm tcpd pam ssl sasl perl python ldap kerberos java"
stephen, some more output would be helpfull here. I have not really any idea what error 137 is, so without any more elaborate error messages I can't do much
My present status is: Blackdown-jdk-1.4.1 installed. firewall root # java-config -L [blackdown-jdk-1.4.1] "Blackdown JDK 1.4.1" (/etc/env.d/java/20blackdown-jdk-1.4.1) * Error message that gives Error 137: gcc -c -I. -I../dist/../include -I../dist/../include_auto -D_GNU_SOURCE -D_REENTRANT -I/opt/blackdown-jdk-1.4.1/include -I/opt/blackdown-jdk-1.4.1/include/linux -march=pentium2 -O3 -pipe ../dist/../db_checkpoint/db_checkpoint.c -fPIC -DPIC -o .libs/db_checkpoint.lo cd ./classes && jar cf ../db.jar com/sleepycat/db make: *** [db.jar] Error 137 make: *** Waiting for unfinished jobs.... This was reported at the end of the emerge messages: !!! ERROR: sys-libs/db-4.0.14-r2 failed. !!! Function src_compile, Line 74, Exitcode 2 !!! (no error message) In reference to the why make reported the value: These errors are not really `make' errors at all. They mean that a program that `make' invoked as part of a command script returned a non-0 error code (`Error NN'), which `make' interprets as failure, or it exited in some other abnormal fashion (with a signal of some type). *Note Errors in Commands: Errors. The last command executed was 'jar'. There is no 'db.jar' in the build_unix/classes directory. Running the command as stated above results in the message "Killed" being reported to the command line.
I know that it are not make errors, but I can't really determine what they are. As the original bug should be fixed by now I'll close the bug