How to find JDK directory in Ubuntu for JNI C/C++ library
37,880
Assuming you've got a JDK installed the directory should be something like: /usr/lib/jvm/java-7-openjdk-amd64
(assuming OpenJDK 7 here). You might also need to a JAVA_HOME
environment variable pointing at the same directory depending on your build process.
If you haven't got a JDK installed you can install the OpenJDK with something like the following in a terminal windows:
sudo apt-get install openjdk-7-jdk
Author by
Habibullah Araphat Konok
Updated on May 02, 2020Comments
-
Habibullah Araphat Konok almost 4 years
I am trying to use JNI for my recent project. MY IDE is NetBeans. After creating C/C++ project , I am trying to add JDK directory from project properties->C compiler->include directory. I could not find any include or include/linux directory in /usr/lib/jvm/ directory.
Where should i look for "include" or "include/linux" directory?
-
Dielson Sales about 10 yearsFor 32 bits it's /usr/lib/jvm/java-7-openjdk-i386.
-
user1893354 over 4 yearsI am confused, is this where the "include" directory is supposed to be?