libzt icon indicating copy to clipboard operation
libzt copied to clipboard

Java: Could NOT find JNI

Open 3305325552 opened this issue 3 years ago • 1 comments

-- Looking for JNI CMake Error at /usr/share/cmake-3.22/Modules/FindPackageHandleStandardArgs.cmake:230 (message): Could NOT find JNI (missing: JAVA_INCLUDE_PATH) Call Stack (most recent call first): /usr/share/cmake-3.22/Modules/FindPackageHandleStandardArgs.cmake:594 (_FPHSA_FAILURE_MESSAGE) /usr/share/cmake-3.22/Modules/FindJNI.cmake:382 (FIND_PACKAGE_HANDLE_STANDARD_ARGS) CMakeLists.txt:475 (find_package)

When I try ./build.sh host-jar, it reports this exception, how can I fix it ? I've searched a lot of workarounds but to no avail.

3305325552 avatar Jan 29 '22 02:01 3305325552

You'll need to install the JDK to build against. For instance on my Linux machine I have to apt install openjdk-11-jdk. Perhaps I should add this to the documentation. Thanks.

joseph-henry avatar Jun 01 '22 22:06 joseph-henry