Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

JDK 10 removed javah #51

Open
Leo428 opened this issue May 20, 2018 · 2 comments
Open

JDK 10 removed javah #51

Leo428 opened this issue May 20, 2018 · 2 comments

Comments

@Leo428
Copy link

Leo428 commented May 20, 2018

I tried to build the master with JDK 10 on Mac OS High Sierra. Error like this will occur:

Unable to locate an executable at "/Library/Java/JavaVirtualMachines/jdk-10.0.1.jdk/Contents/Home/bin/javah" (-1)

I resolved this issue by changing line 112 in jni.gradle to

executable org.gradle.internal.jvm.Jvm.current().getExecutable('javap')

This problem is caused by the removal of javah
I have not tested whether "javap" will work the same as "javah" in other JDK versions. Hope you can look into this.

@duane701
Copy link

duane701 commented May 20, 2018

I think Kotlin replacement for javah answers the problem in the question with what may be needed here. (I haven't looked specifically at the use for javah in this case.)

The recommendation is to use javac -h in place of javah. The primary difference is that javah operates on .class files where javac operates on java source files.

@Leo428
Copy link
Author

Leo428 commented May 20, 2018

I saw that solution too. I tried simply replacing "javah" to "javac -h" in that line. But since I have little knowledge about groovy and gradle, it did not work.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants