ssleay32.dll depends on libeay32.dll

This commit is contained in:
Doug MacEachern 2006-12-05 16:46:56 +00:00
parent 57b9747bfe
commit 19565d776d
1 changed files with 18 additions and 11 deletions

View File

@ -49,20 +49,27 @@ abstract class VMwareObject {
} }
if (SigarLoader.IS_WIN32) { if (SigarLoader.IS_WIN32) {
File libssl = File root = new File(lib).getParentFile();
new File(new File(lib).getParent(), String[] libs = {
"ssleay32.dll"); "libeay32.dll",
if (!libssl.exists()) { "ssleay32.dll"
};
for (int i=0; i<libs.length; i++) {
File ssllib =
new File(root, libs[i]);
if (!ssllib.exists()) {
return false; return false;
} }
try { try {
System.load(libssl.getPath()); System.load(ssllib.getPath());
} catch (UnsatisfiedLinkError e) { } catch (UnsatisfiedLinkError e) {
//e.printStackTrace(); e.printStackTrace();
return false; return false;
} }
} }
}
return init(lib); return init(lib);
} catch (Exception e) { } catch (Exception e) {