From ef87e5567cf3ac462a3f12aad4b5b530d9220223 Mon Sep 17 00:00:00 2001 From: "David M. Lloyd" Date: Tue, 16 Jul 2019 09:50:33 -0500 Subject: [PATCH] Java 11: Disable Graphics for JAXB --- .../runtime/graal/Java2DSubstitutions.java | 20 +++++++++++++++++++ 1 file changed, 20 insertions(+) create mode 100644 core/runtime/src/main/java/io/quarkus/runtime/graal/Java2DSubstitutions.java diff --git a/core/runtime/src/main/java/io/quarkus/runtime/graal/Java2DSubstitutions.java b/core/runtime/src/main/java/io/quarkus/runtime/graal/Java2DSubstitutions.java new file mode 100644 index 0000000000000..0ca2b30ab278e --- /dev/null +++ b/core/runtime/src/main/java/io/quarkus/runtime/graal/Java2DSubstitutions.java @@ -0,0 +1,20 @@ +package io.quarkus.runtime.graal; + +import java.awt.Graphics; +import java.awt.GraphicsEnvironment; + +import com.oracle.svm.core.annotate.AlwaysInline; +import com.oracle.svm.core.annotate.Substitute; +import com.oracle.svm.core.annotate.TargetClass; + +@TargetClass(GraphicsEnvironment.class) +final class Target_java_awt_GraphicsEnvironment { + @AlwaysInline("DCE for things using Java2D") + @Substitute + public static Graphics getLocalGraphicsEnvironment() { + throw new UnsupportedOperationException("Not implemented yet for GraalVM native images"); + } +} + +class Java2DSubstitutions { +}