This is the mail archive of the java@gcc.gnu.org mailing list for the Java project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

ld core dumps on -export-dynamic


I'm working on gcj version 3.3 20030306 (prerelease) on RH8.0.
"ld" is version 2.13.90.0.2 20020802. (does anybody know if it is compatible
with the version of gcj above?)

When I invoke gcj with "-export-dynamic", "ld" dumps core. The core dump
says: "ld terminated with signal 11 [Segmentation fault], core dumped"

When linked with "-export-dynamic -s", it doesn't dump core, but then ltdl
fails to find the jni symbols in the executable:
exception in thread "main" java.lang.UnsatisfiedLinkError: gtk_set_locale
	at _Jv_LookupJNIMethod(/usr/lib/libgcj.so.4.0.0)
	at gnu.gcj.runtime.FirstThread.call_main() ...

"gtk_set_locale" is indeed one the the native methods defined in
org.eclipse.swt.internal.gtk.OS.java, that should be found by ltdl. Does
anybody know how I should compile/link on linux for ltdl to find the jni
symbols in the executable itself?

If I compile without "-export-dynamic" it still dumps core. Only "-s" seems
to save the day :)

By the way, I can see that swt-xxx.so is built with "-ldl" and "-lm". Does
anybody know the meaning of it? Is it needed, when I put the jni objects in
the executable? It doesn't seem to change anything when I leave it out/leave
it in?


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]