Supports DL4J Java 10

Deeplearning4j: Error creating native binaries with Quarkus and GraalVM

Error Description

A microservice using Quarkus cannot build the native binary with the following error (and many others):

~Trigger: java.lang.IllegalArgumentException: Invalid structure field in class com.sun.jna.platform.win32.Variant $ VARIANT $ _VARIANT $ __ VARIANT, field name 'ullVal' (class com.sun.jna.platform.win32.WinDef $ ULONGLONG): The type "com.sun.jna.platform.win32.WinDef $ ULONGLONG" is not supported: Unsupported size: 16at com.sun.jna.Structure.validateField (Structure.java:1153)at com.sun.jna.Structure.validateFields (Structure.java:1162)at com.sun.jna.Structure.

And also:

~Original exception that caused the problem: java.lang.UnsatisfiedLinkError: Unable to load library 'Advapi32': Native library (linux-x86-64 / libAdvapi32.so) not found in resource path~

Version information

Please provide relevant versions including, if relevant:

  • Deeplearning4j version -> 1.0.0-beta3
  • Platform information (operating system, etc.)

RHEL 7

Java version:

$ java -version
Java version "1.8.0_201"
Java (TM) SE runtime environment (Build 1.8.0_201-b09)
Java HotSpot (TM) 64-bit Server VM (Build 25.201-b09, mixed mode)

Graal: Version: Community Edition 1.0.0-rc13.

Contribute

You can reproduce the problem with the following project: https://github.com/jesuino/java-ml-projects/tree/master/integration/microservices/image-classifier-microservice

Steps:

1) Download the GRAAL VM and set the GRAALVM_HOME environment variable accordingly
2) Run: mvn clean install -Pnative