Linux: Make sure libjawt.so can be loaded
This commit is contained in:
parent
3085702a38
commit
f84e2ceb26
|
@ -40,6 +40,10 @@ import java.io.IOException;
|
|||
* @version $Revision$
|
||||
*/
|
||||
class LinuxSysImplementation extends J2SESysImplementation {
|
||||
static {
|
||||
java.awt.Toolkit.getDefaultToolkit(); // This will make sure libjawt.so is loaded
|
||||
}
|
||||
|
||||
public boolean openURL(String url) {
|
||||
// Linux may as well resort to pure Java hackery, as there's no Linux native way of doing it
|
||||
// right anyway.
|
||||
|
|
|
@ -63,8 +63,8 @@ public final class Sys {
|
|||
private final static SysImplementation implementation;
|
||||
|
||||
static {
|
||||
System.loadLibrary(LIBRARY_NAME);
|
||||
implementation = createImplementation();
|
||||
System.loadLibrary(LIBRARY_NAME);
|
||||
String native_version = implementation.getNativeLibraryVersion();
|
||||
if (!native_version.equals(VERSION))
|
||||
throw new LinkageError("Version mismatch: jar version is '" + VERSION +
|
||||
|
|
Loading…
Reference in New Issue