summaryrefslogtreecommitdiff
path: root/bean/com
diff options
context:
space:
mode:
authorStephan Bergmann <sbergman@redhat.com>2014-02-13 23:20:28 +0100
committerStephan Bergmann <sbergman@redhat.com>2014-02-13 23:22:35 +0100
commit0d396800021684a8c0875e45ed1440011fd7f9b0 (patch)
treed7f792c59ad954edeafe58571e3c17efdb842114 /bean/com
parentf759239d7d4a7c9d9fc641f1873a34c5a4d6c31b (diff)
More java.lang.System.mapLibraryName dylib vs. jnilib confusion
...like a76261ac9e40eb57e942db2c7aea8b8a5e904ff2 Change-Id: I803dc81344efb5e8021d9ef4146c06ecf82ca63b
Diffstat (limited to 'bean/com')
-rw-r--r--bean/com/sun/star/beans/LocalOfficeConnection.java9
1 files changed, 9 insertions, 0 deletions
diff --git a/bean/com/sun/star/beans/LocalOfficeConnection.java b/bean/com/sun/star/beans/LocalOfficeConnection.java
index dd2ed076ae9d..d8e7b3baa654 100644
--- a/bean/com/sun/star/beans/LocalOfficeConnection.java
+++ b/bean/com/sun/star/beans/LocalOfficeConnection.java
@@ -78,6 +78,15 @@ public class LocalOfficeConnection
// load libofficebean.so/officebean.dll
String aSharedLibName = getProgramPath() + java.io.File.separator +
System.mapLibraryName(OFFICE_LIB_NAME);
+ // At least Oracle's 1.7.0_51 now maps to .dylib rather than .jnilib:
+ if (System.getProperty("os.name").startsWith("Mac")
+ && aSharedLibName.endsWith(".dylib"))
+ {
+ aSharedLibName
+ = aSharedLibName.substring(
+ 0, aSharedLibName.length() - "dylib".length())
+ + "jnilib";
+ }
System.load( aSharedLibName );
}