Skip to content

Conversation

dmitry-timofeev
Copy link
Contributor

@dmitry-timofeev dmitry-timofeev commented Apr 7, 2020

On Mac with Java 14, JNA appears to not search
in /usr/local/lib, where sodium is installed.

See java-native-access/jna#1175

On Mac with Java 14, JNA appears to not search
in /usr/local/lib, where sodium is installed.

See java-native-access/jna#1175
The publicLookup surprisingly causes a loader constraint violation
on Java 14 (but works on 11 through 13). The error appears on the
second lookup (e.g., when a second testkit instance is created):

```
java.lang.LinkageError: loader constraint violation: when resolving method
'com.exonum.binding.fakeservice.Transactions$PutTransactionArgs com.exonum.binding.fakeservice.Transactions$PutTransactionArgs.parseFrom(byte[])'
the class loader 'bootstrap' of the current class, java/lang/Object, and
the class loader org.pf4j.PluginClassLoader @1d96d872 for the method's defining class,
com/exonum/binding/fakeservice/Transactions$PutTransactionArgs,
have different Class objects for the type com/exonum/binding/fakeservice/Transactions$PutTransactionArgs
used in the signature (java.lang.Object is in module java.base of loader 'bootstrap';
com.exonum.binding.fakeservice.Transactions$PutTransactionArgs is in unnamed module
of loader org.pf4j.PluginClassLoader @1d96d872, parent loader 'app')
```
@dmitry-timofeev dmitry-timofeev force-pushed the try-explicit-jna-path branch from c324a51 to 6f2dc8e Compare April 7, 2020 14:51
@dmitry-timofeev dmitry-timofeev mentioned this pull request Apr 8, 2020
7 tasks
@dmitry-timofeev dmitry-timofeev changed the title Specify a JNA library path: Add Java 14 support Apr 8, 2020
@dmitry-timofeev dmitry-timofeev merged commit f3f599b into master Apr 8, 2020
@dmitry-timofeev dmitry-timofeev deleted the try-explicit-jna-path branch April 8, 2020 12:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

2 participants