I can find java, javac and javadoc but there is no javah.exe in my jdk\\bin folder.
I tried to reinstall the JDK but it is still missing. How can I get it, why is it missing?
I found a similar question where the operating system was Linux but I can not find answers for Windows users.
My OS is Windows 10. The Java version is 10.0.1.
The tool javah.exe was removed in Java 10. The reason is simple, it is obsolete. From JEP 313: Remove the Native-header Generation Tool (javah):
Motivation
The tool has been superseded by superior functionality in
javac, added in JDK 8 (JDK-7150368). This functionality provides the ability to write native header files at the time that Java source code is compiled, thereby eliminating the need for a separate tool.Focusing on the support provided by
javaceliminates the need to upgradejavahto support recent new paradigms, such as API access via the Compiler API injavax.tools.*, or the newjava.util.spi.ToolProviderSPI added in JDK 9.
So you can just use javac.exe if you are on Java 8 or newer.
javah has been superseded by the -h option added to javac in JDK 8.
It is deprecated since Java 9.
See here for details.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With