From: Artiste on t. W. <a1...@So...> - 2001-03-26 09:57:01
|
Hi, I experiment problem with GL4Java 2.6, too... under winME but Linux also. I wonder in witch order do you load the native libraries ? If we have 2 lib, lib1 and lib2, and if lib1 depend on lib2, if we call (in java) : System.loadLibrary("lib1"); I think Java will search lib1 in the java.library.path, but who will search lib2, required by lib1 ? Java or the OS ??? Probably the OS... and the OS will not search in the java.library.path. I've tried this : I take libGL4JavaJauGLJNI.so as lib1 and libGL4JavaJauGLjJNI.so as lib2 (according to "objdump -p", libGL4JavaJauGLJNI.so needs libGL4JavaJauGLjJNI.so). Both libraries are in the java.library.path, but NOT in the OS library path (/usr/lib, /usr/local/lib, ...). If i do : System.loadLibrary("libGL4JavaJauGLJNI.so"); // =lib1 It crashes and says libGL4JavaJauGLjJNI.so (=lib2) cannot be found. But i load lib2 first : System.loadLibrary("libGL4JavaJauGLjJNI.so"); // =lib2 System.loadLibrary("libGL4JavaJauGLJNI.so"); // =lib1 it's OK. So i think the problem is the order... In GLContext.loadNativeLibraries(), you need to load libGL4JavaJauGLjJNI.so before libGL4JavaJauGLJNI.so. Under Linux, just loading libGL4JavaJauGLjJNI.so before i call GLContext.loadNativeLibraries() is OK. A11W |