Bug 50582 - eclipse-sdk-3.0.0_pre8 crashes with java.lang.UnsatisfiedLinkError on sun-jdk
Bug#: 50582 Product:  Gentoo Linux Version: unspecified Platform: x86
OS/Version: Linux Status: RESOLVED Severity: normal Priority: P2
Resolution: FIXED Assigned To: karltk@gentoo.org Reported By: harmgeerts@home.nl
Component: Applications
URL: 
Summary: eclipse-sdk-3.0.0_pre8 crashes with java.lang.UnsatisfiedLinkError on sun-jdk
Keywords:  
Status Whiteboard: 
Opened: 2004-05-09 16:07 0000
Description:   Opened: 2004-05-09 16:07 0000
First: the ebuild doesn't symlink the eclipse executable to a location in my
path (/usr/lib/eclipse-3/eclipse-gtk)

Second: eclipse crashes with the following error
!SESSION May 10, 2004 00:58:53.133
---------------------------------------------
java.version=1.4.2_04
java.vendor=Sun Microsystems Inc.
BootLoader constants: OS=linux, ARCH=x86, WS=gtk, NL=en_IE
!ENTRY org.eclipse.osgi May 10, 2004 00:58:53.134
!MESSAGE Application error
!STACK 1
java.lang.UnsatisfiedLinkError:
/usr/lib/eclipse-3/plugins/org.eclipse.swt.gtk/os/linux/x86/libswt-pi-gtk-3044.so:
/usr/lib/eclipse-3/plugins/org.eclipse.swt.gtk/os/linux/x86/libswt-pi-gtk-3044.so:
undefined symbol: g_thread_init
        at java.lang.ClassLoader$NativeLibrary.load(Native Method)
        at java.lang.ClassLoader.loadLibrary0(ClassLoader.java:1560)
        at java.lang.ClassLoader.loadLibrary(ClassLoader.java:1469)
        at java.lang.Runtime.loadLibrary0(Runtime.java:788)
        at java.lang.System.loadLibrary(System.java:834)
        at org.eclipse.swt.internal.Library.loadLibrary(Library.java:100)
        at org.eclipse.swt.internal.gtk.OS.<clinit>(OS.java:19)
        at org.eclipse.swt.internal.Converter.wcsToMbcs(Converter.java:63)
        at org.eclipse.swt.internal.Converter.wcsToMbcs(Converter.java:54)
        at org.eclipse.swt.widgets.Display.<clinit>(Display.java:112)
        at org.eclipse.ui.internal.Workbench.createDisplay(Workbench.java:271)
        at org.eclipse.ui.PlatformUI.createDisplay(PlatformUI.java:151)
        at
org.eclipse.ui.internal.ide.IDEApplication.run(IDEApplication.java:66)
        at
org.eclipse.core.internal.runtime.PlatformActivator$1.run(PlatformActivator.java:277)
        at
org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:239)
        at
org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:117)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
        at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
        at java.lang.reflect.Method.invoke(Method.java:324)
        at org.eclipse.core.launcher.Main.basicRun(Main.java:267)
        at org.eclipse.core.launcher.Main.run(Main.java:692)
        at org.eclipse.core.launcher.Main.main(Main.java:676)


Reproducible: Always
Steps to Reproduce:
1.
2.
3.




x11-libs/gtk+-2.4.1
dev-java/sun-jdk-1.4.2.04

emerge info
Portage 2.0.50-r6 (default-x86-1.4, gcc-3.3.3, glibc-2.3.3_pre20040420-r0,
2.4.26)
=================================================================
System uname: 2.4.26 i686 AMD Athlon(tm) XP 2000+
Gentoo Base System version 1.4.11
distcc 2.14 i686-pc-linux-gnu (protocols 1 and 2) (default port 3632) [enabled]
ccache version 2.3 [enabled]
Autoconf: sys-devel/autoconf-2.59-r3
Automake: sys-devel/automake-1.8.3
ACCEPT_KEYWORDS="x86 ~x86"
ACCEPT_LICENSE=""
ALSA_CARDS="emu10k1"
ANT_HOME="/usr/share/ant"
ARCH="x86"
AUTOCLEAN="yes"
BASH_ENV="/etc/portage/bashrc"
CC="gcc"
CCACHE_SIZE="1G"
CFLAGS="-march=athlon-xp -O3 -pipe -fomit-frame-pointer"
CHOST="i686-pc-linux-gnu"
CLASSPATH="."
CLEAN_DELAY="5"
COLORTERM=""
COMPILER="gcc3"
CONFIG_PROTECT="/etc /usr/X11R6/lib/X11/xkb /usr/kde/2/share/config
/usr/kde/3.2/share/config /usr/kde/3/share/config /usr/share/config
/var/qmail/control"
CONFIG_PROTECT_MASK="/etc/gconf /etc/terminfo /etc/env.d"
CVS_RSH="ssh"
CXX="g++"
CXXFLAGS="-march=athlon-xp -O3 -pipe -fomit-frame-pointer"
DCCC_PATH="/usr/lib/distcc/bin"
DESKTOP_SESSION="kde-3.2.2"
DISPLAY=":0"
DISTCC_DIR="/var/tmp/portage/.distcc"
DISTCC_LOG=""
DISTCC_VERBOSE="0"
DISTDIR="/usr/portage/distfiles"
EDITOR="/bin/nano"
FEATURES="autoaddcvs ccache distcc fixpackages sandbox"
FETCHCOMMAND="/usr/bin/wget -t 5 --passive-ftp -P ${DISTDIR} ${URI}"
GDK_USE_XFT="1"
GENTOO_MIRRORS="ftp://ftp.snt.utwente.nl/pub/os/linux/gentoo
http://gentoo.oregonstate.edu
http://www.ibiblio.org/pub/Linux/distributions/gentoo"
GLIBC_SSP_CHECKED="1"
GRP_STAGE23_USE="ipv6 pam tcpd readline nls ssl gpm perl python berkdb acl
ncurses"
GS_LIB="/home/harm/.fonts"
GTK2_RC_FILES="/etc/gtk-2.0/gtkrc:/home/harm/.gtkrc-2.0:/home/harm/.kde3.2/share/config/gtkrc"
GTK_RC_FILES="/etc/gtk/gtkrc:/home/harm/.gtkrc:/home/harm/.kde3.2/share/config/gtkrc"
GUILE_LOAD_PATH="/usr/share/guile/1.6"
G_BROKEN_FILENAMES="1"
HISTCONTROL="ignoreboth"
HOME="/home/harm"
HOSTNAME="manuel"
INFODIR="/usr/share/info:/usr/X11R6/info"
INFOPATH="/usr/share/info:/usr/share/gcc-data/i686-pc-linux-gnu/3.3/info"
INPUTRC="/etc/inputrc"
JAVAC="/opt/sun-jdk-1.4.2.04/bin/javac"
JAVA_HOME="/opt/sun-jdk-1.4.2.04"
JDK_HOME="/opt/sun-jdk-1.4.2.04"
KDEDIR="/usr/kde/3.2"
KDEDIRS="/usr"
KDE_FULL_SESSION="true"
KDE_MULTIHEAD="false"
KONSOLE_DCOP="DCOPRef(konsole-18731,konsole)"
KONSOLE_DCOP_SESSION="DCOPRef(konsole-18731,session-3)"
LANG="en_IE@euro"
LC_ALL="en_IE@euro"
LESS="-R"
LESSOPEN="|lesspipe.sh %s"
LOGNAME="harm"
LS_COLORS="no=00:fi=00:di=01;34:ln=01;36:pi=40;33:so=01;35:do=01;35:bd=40;33;01:cd=40;33;01:or=40;31;01:ex=01;32:*.tar=01;31:*.tgz=01;31:*.arj=01;31:*.taz=01;31:*.lzh=01;31:*.zip=01;31:*.z=01;31:*.Z=01;31:*.gz=01;31:*.bz2=01;31:*.deb=01;31:*.rpm=01;31:*.jpg=01;35:*.gif=01;35:*.bmp=01;35:*.ppm=01;35:*.tga=01;35:*.xbm=01;35:*.xpm=01;35:*.tif=01;35:*.png=01;35:*.mpg=01;35:*.avi=01;35:*.fli=01;35:*.gl=01;35:*.dl=01;35:"
MAKEOPTS="-j3"
MANPATH="/usr/share/man:/usr/local/share/man:/usr/share/gcc-data/i686-pc-linux-gnu/3.3/man:/usr/X11R6/man::/opt/sun-jdk-1.4.2.04/man:/usr/qt/3/doc/man"
NOCOLOR="false"
OLDPWD="/home/harm"
PAGER="/usr/bin/less"
PATH="/bin:/usr/bin:/usr/local/bin:/opt/bin:/usr/i686-pc-linux-gnu/gcc-bin/3.3:/usr/X11R6/bin:/opt/sun-jdk-1.4.2.04/bin:/opt/sun-jdk-1.4.2.04/jre/bin:/opt/sun-jdk-1.4.2.04/jre/javaws:/usr/qt/3/bin:/usr/kde/3.2/bin:/usr/games/bin"
PKGDIR="/usr/portage/packages"
PORTAGE_BINHOST_CHUNKSIZE="3000"
PORTAGE_CACHEDIR="/var/cache/edb/dep/"
PORTAGE_CALLER="emerge"
PORTAGE_GID="250"
PORTAGE_MASTER_PID="17914"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY="/etc/portage/overlay"
PRELINK_PATH=""
PRELINK_PATH_MASK="/opt:/usr/lib/wine:/usr/lib/MozillaFirebird"
PS1="\[\e[01;32m\][\[\e[01;35m\]\t\[\e[01;32m\]] \u@\h
\[\e[01;34m\]\w\n\[\e[01;31m\]\$ \[\e[00m\]"
PWD="/home/harm/.eclipse/configuration"
PYTHONDOCS="/usr/share/doc/python-docs-2.3.3-r1/html"
QMAKESPEC="linux-g++"
QTDIR="/usr/qt/3"
RESUMECOMMAND="/usr/bin/wget -c -t 5 --passive-ftp -P ${DISTDIR} ${URI}"
RPMDIR="/usr/portage/rpm"
RSYNC_RETRIES="3"
RSYNC_TIMEOUT="180"
SANE_CONFIG_DIR="/etc/sane.d"
SESSION_MANAGER="local/manuel:/tmp/.ICE-unix/18699"
SHELL="/bin/bash"
SHLVL="3"
SYNC="rsync://rsync1.nl.gentoo.org/gentoo-portage"
TERM="xterm"
USE="3dnow X aalib acpi alsa apm arts avi berkdb cdr crypt cups dga dvd dvdr
encode faad fbcon flac foomaticdb gd gdbm gif gpm gtk gtk2 guile icc-pgo imap
imlib imlib2 innodb java jpeg kde libg++ libwww mad maildir matroska mikmod mmx
mpeg mysql ncurses nls offensive oggvorbis opengl oss pam pdflib perl png psyco
python qt quicktime readline samba scanner sdl slang spell sse ssl svga tcltk
tcpd tiff truetype usb x86 xinerama xml xml2 xmms xv xvid zlib"
USER="harm"
USERLAND="GNU"
USE_EXPAND="VIDEO_CARDS INPUT_DEVICES LINGUAS"
WINDOWID="37748741"
XARGS="xargs -r"
XCURSOR_SIZE=""
XCURSOR_THEME="default"
XDM_MANAGED="/var/run/xdmctl/xdmctl-:0,maysd,mayfn,sched,method=classic"
XINITRC="/etc/X11/xinit/xinitrc"
_="/usr/bin/emerge"

------- Comment #1 From Karl Trygve Kalleberg (RETIRED) 2004-05-10 04:23:10 0000 -------
It appears that, for some currently obscure reason, libgthread-2.0.so will not
be linked in when eclipse-sdk-3.0.0_pre8 is compiled with the sun-jdk.

Compiling it with the blackdown-jdk works, and it can even be run with the
sun-jdk afterwards. I will look into this further. Thanks for spotting this
one.

If you happen to have the IBM JDK lying around, please feel free to test with
that one also:)

------- Comment #2 From Karl Trygve Kalleberg (RETIRED) 2004-05-10 08:45:26 0000 -------
Even more interesting: Building with sun-jdk then running with blackdown-jdk
works, but running with sun-jdk after building with sun-jdk fails.

------- Comment #3 From Karl Trygve Kalleberg (RETIRED) 2004-05-10 08:50:52 0000 -------
Cannot seem to reproduce the symlink problem. Be advised that the 3.0 eclipse
series will have script file named /usr/bin/eclipse-3 not a symlink.

------- Comment #4 From Karl Trygve Kalleberg (RETIRED) 2004-05-10 09:30:43 0000 -------
Found it. Stupid typo on my part. 

Available for testing as dev-util/eclipse-3.0.0_pre8-r1