[Java] `onnxruntime-genai-cuda.dll` missing from Java JAR and extraction logic in CUDA builds
ep:CUDAapi:java
When building the Java bindings with CUDA support enabled, the resulting `onnxruntime-genai-[version].jar` is incomplete for GPU execution.
Specifically, the POST_BUILD commands in [`src/java/CMakeLists.txt`](https://github.com/microsoft/onnxruntime-genai/blob/639dcc06fbffff14c06612b64d3f7773a7b98a2f/src/java/CMakeLists.txt) explicitly copy `onnxruntime-genai.dll` and `onnxruntime-genai-jni.dll` to the `native-lib` staging directory, but there is no corresponding instruction to include `onnxruntime-genai-cuda.dll`.
Additionally, even if the library were present in the JAR, the [`GenAI.java`](https://github.com/microsoft/onnxruntime-genai/blob/639dcc06fbffff14c06612b64d3f7773a7b98a2f/src/java/src/main/java/ai/onnxruntime/genai/GenAI.java) source lacks the necessary logic to identify and extract the CUDA-specific binary to the temporary runtime directory, preventing the library from being loaded by the JVM.
0 条评论