diff options
author | Sven Gothel <[email protected]> | 2013-10-19 07:11:01 +0200 |
---|---|---|
committer | Sven Gothel <[email protected]> | 2013-10-19 07:11:01 +0200 |
commit | 51bb8b2259e8eae9f62ec7202e8b7eb934a44c85 (patch) | |
tree | c3bb944e229fdc33a328ff3f6c8e7596dc6f8830 /src/com/jogamp/opencl/llb/impl/CLDynamicLibraryBundleInfo.java | |
parent | 6be41a8e457ec2881f4ce351395ba84748a737b6 (diff) |
CLDynamicLibraryBundleInfo: Add libPVROCL.so lookup if Android ..v2.1.1
Diffstat (limited to 'src/com/jogamp/opencl/llb/impl/CLDynamicLibraryBundleInfo.java')
-rw-r--r-- | src/com/jogamp/opencl/llb/impl/CLDynamicLibraryBundleInfo.java | 14 |
1 files changed, 11 insertions, 3 deletions
diff --git a/src/com/jogamp/opencl/llb/impl/CLDynamicLibraryBundleInfo.java b/src/com/jogamp/opencl/llb/impl/CLDynamicLibraryBundleInfo.java index ff5a122a..36bc26f9 100644 --- a/src/com/jogamp/opencl/llb/impl/CLDynamicLibraryBundleInfo.java +++ b/src/com/jogamp/opencl/llb/impl/CLDynamicLibraryBundleInfo.java @@ -40,7 +40,9 @@ import java.security.PrivilegedAction; import java.util.*; public final class CLDynamicLibraryBundleInfo implements DynamicLibraryBundleInfo { + private static final boolean isAndroid; private static final List<String> glueLibNames; + static { AccessController.doPrivileged(new PrivilegedAction<Object>() { public Object run() { @@ -53,6 +55,7 @@ public final class CLDynamicLibraryBundleInfo implements DynamicLibraryBundleInf return null; } }); + isAndroid = Platform.OSType.ANDROID == Platform.OS_TYPE; glueLibNames = new ArrayList<String>(); glueLibNames.add("jocl"); @@ -77,7 +80,7 @@ public final class CLDynamicLibraryBundleInfo implements DynamicLibraryBundleInf */ @Override public final boolean shallLookupGlobal() { - if ( Platform.OSType.ANDROID == Platform.OS_TYPE ) { + if ( isAndroid ) { // Android requires global symbol lookup return true; } @@ -100,8 +103,13 @@ public final class CLDynamicLibraryBundleInfo implements DynamicLibraryBundleInf libCL.add("libOpenCL.so.1"); // unix libCL.add("OpenCL"); // windows, OSX - // try this one as well, if spec fails - libCL.add("libGL.so.1"); + if( isAndroid ) { + libCL.add("libPVROCL.so"); + libCL.add("/system/vendor/lib/libPVROCL.so"); + } else { + // try this one as well, if spec fails + libCL.add("libGL.so.1"); + } // ES2: This is the default lib name, according to the spec libCL.add("libGLESv2.so.2"); |