user3750474
user3750474

Reputation: 259

javah is not a recognized as an internal or external command

I tried to fix this by executing in my cmd: "path=C:\Program Files\Java\jdk1.8.0_65\bin"

I'm working on windows. Is this wrong? I've been stuck for awhile so any help would much appreciated.

Upvotes: 2

Views: 5802

Answers (2)

Suhas Gumma
Suhas Gumma

Reputation: 91

javah is removed in the latest JDK.

Before JDK 8, you need to compile the Java program using javac and generate C/C++ header using a dedicated javah utility. The javah utility is no longer available in JDK 10.

For those who are using the latest JDK, the javac -h command will compile and create a header file.

Upvotes: 5

Francisco Hernandez
Francisco Hernandez

Reputation: 2468

javah is under <JAVA_HOME>/bin folder, you have to ensure that you have that folder on your path

you can do something like (on unix system)

export PATH=<JAVA_HOME>/bin:$PATH

or follow this for windows

http://www.computerhope.com/issues/ch000549.htm

Upvotes: 2

Related Questions