@novastera-oss/llamarn 0.4.6 → 0.5.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -102,11 +102,13 @@ endif()
102
102
 
103
103
  # Check if OpenCL backend library is available
104
104
  set(OPENCL_BACKEND_AVAILABLE FALSE)
105
- if(EXISTS ${JNI_LIBS_DIR}/${ANDROID_ABI}/libggml-opencl.so AND EXISTS ${JNI_LIBS_DIR}/${ANDROID_ABI}/libOpenCL.so)
105
+ # Check only for libggml-opencl.so - libOpenCL.so is a system library (not shipped)
106
+ if(EXISTS ${JNI_LIBS_DIR}/${ANDROID_ABI}/libggml-opencl.so)
106
107
  set(OPENCL_BACKEND_AVAILABLE TRUE)
107
- message(STATUS "OpenCL backend libraries found for ${ANDROID_ABI}")
108
+ message(STATUS "OpenCL backend library found for ${ANDROID_ABI}")
109
+ message(STATUS "Note: libOpenCL.so will be provided by the system at runtime")
108
110
  else()
109
- message(STATUS "OpenCL backend libraries not found for ${ANDROID_ABI}")
111
+ message(STATUS "OpenCL backend library not found for ${ANDROID_ABI}")
110
112
  endif()
111
113
 
112
114
  # Hybrid backend approach: CPU static (built into main libraries), GPU dynamic
@@ -241,14 +243,10 @@ if(EXISTS ${JNI_LIBS_DIR}/${ANDROID_ABI}/libggml-opencl.so)
241
243
  )
242
244
  endif()
243
245
 
244
- if(EXISTS ${JNI_LIBS_DIR}/${ANDROID_ABI}/libOpenCL.so)
245
- add_custom_command(TARGET RNLlamaCpp POST_BUILD
246
- COMMAND ${CMAKE_COMMAND} -E copy_if_different
247
- ${JNI_LIBS_DIR}/${ANDROID_ABI}/libOpenCL.so
248
- $<TARGET_FILE_DIR:RNLlamaCpp>/libOpenCL.so
249
- COMMENT "Copying OpenCL loader library to build output directory"
250
- )
251
- endif()
246
+ # NOTE: We do NOT copy libOpenCL.so or libvulkan.so - these are system libraries
247
+ # The ICD loader is built and installed to NDK sysroot for BUILD-TIME linking only.
248
+ # At runtime, the system will provide libOpenCL.so and libvulkan.so if the device supports them.
249
+ # We only ship libggml-opencl.so and libggml-vulkan.so (our GGML backend wrappers).
252
250
 
253
251
  # Expose our headers to consuming targets (for autolinking)
254
252
  target_include_directories(RNLlamaCpp INTERFACE
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@novastera-oss/llamarn",
3
- "version": "0.4.6",
3
+ "version": "0.5.0",
4
4
  "description": "An attempt at a pure cpp turbo module library",
5
5
  "source": "./src/index.tsx",
6
6
  "main": "./lib/module/index.js",