Skip to content

Conversation

@matthiasblaesing
Copy link
Member

Closes: #1665

This enables running JNA from the module path like this:

java -p <path_to_jna> -m com.sun.jna

That is the modular equivalent to:

java -jar <path_to_jna>
Copy link

@basil basil left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you very much! Now I can ensure Jenkins complies in a way that is officially approved and will match how other users adapt to this change.

@dbwiddis
Copy link
Contributor

dbwiddis commented Apr 25, 2025

Should downstream repos document something similar?

@basil
Copy link

basil commented Apr 25, 2025

I don't feel strongly one way or another. The JVM warning was directly emanating from com.sun.jna.Native.loadNativeDispatchLibraryFromClasspath, so I feel that documentation in this repository is sufficient.

@matthiasblaesing
Copy link
Member Author

@basil thanks for the suggested changes. I added them in place.
@dbwiddis a heads up might be helpful for users. They might not be aware, that $library uses JNA.

@matthiasblaesing matthiasblaesing merged commit 45c4476 into java-native-access:master Apr 26, 2025
12 checks passed
@matthiasblaesing matthiasblaesing deleted the document-jdk24 branch September 30, 2025 18:00
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

Successfully merging this pull request may close these issues.

Warning about use of JNI in JDK 24

3 participants