From 51bb8b2259e8eae9f62ec7202e8b7eb934a44c85 Mon Sep 17 00:00:00 2001 From: Sven Gothel Date: Sat, 19 Oct 2013 07:11:01 +0200 Subject: CLDynamicLibraryBundleInfo: Add libPVROCL.so lookup if Android .. --- resources/android/AndroidManifest-jocl.xml | 3 ++- .../jogamp/opencl/llb/impl/CLDynamicLibraryBundleInfo.java | 14 +++++++++++--- 2 files changed, 13 insertions(+), 4 deletions(-) diff --git a/resources/android/AndroidManifest-jocl.xml b/resources/android/AndroidManifest-jocl.xml index e02ee3da..07fff315 100644 --- a/resources/android/AndroidManifest-jocl.xml +++ b/resources/android/AndroidManifest-jocl.xml @@ -3,10 +3,11 @@ sharedUserId="com.jogamp.Community" package="com.jogamp.opencl"> - + + glueLibNames; + static { AccessController.doPrivileged(new PrivilegedAction() { 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(); 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"); -- cgit v1.2.3