-
Notifications
You must be signed in to change notification settings - Fork 3k
Description
Describe the bug
when compiling a quarkus app with the extension vaadin-quarkus-extension (vaadin flow) it fails with errors
Expected behavior
It should compile in native mode
Actual behavior
it fails with the following error:
ERROR [osh.sof.os.lin.LinuxOperatingSystem] Did not JNA classes. Investigate incompatible version or missing native dll.
[2/8] Performing analysis... [] (9,4s @ 1,63GB)
13.264 reachable types (84,4% of 15.718 total)
17.772 reachable fields (56,3% of 31.547 total)
63.884 reachable methods (53,3% of 119.964 total)
4.114 types, 110 fields, and 3.349 methods registered for reflection
Error: Class initialization of oshi.software.os.unix.freebsd.FreeBsdOperatingSystem failed. This error is reported at image build time because class oshi.software.os.unix.freebsd.FreeBsdOperatingSystem is registered for linking at image build time by command line and command line. Use the option
--initialize-at-run-time=oshi.software.os.unix.freebsd.FreeBsdOperatingSystem
to explicitly request initialization of this class at run time.
com.oracle.svm.core.util.UserError$UserException: Class initialization of oshi.software.os.unix.freebsd.FreeBsdOperatingSystem failed. This error is reported at image build time because class oshi.software.os.unix.freebsd.FreeBsdOperatingSystem is registered for linking at image build time by command line and command line. Use the option
--initialize-at-run-time=oshi.software.os.unix.freebsd.FreeBsdOperatingSystem
When i got this right, it fails with all implementations of the abstract class oshi.software.common.AbstractOperatingSystem
The dependency (oshi-core) comes with
[INFO] +- com.vaadin:vaadin-quarkus-extension:jar:24.6.0:compile
[INFO] | +- com.vaadin:vaadin-core:jar:24.6.0:compile
[INFO] | | +- com.vaadin:vaadin-core-internal:jar:24.6.0:compile
[INFO] | | \- com.vaadin:vaadin-dev:jar:24.6.0:compile
[INFO] | | +- com.vaadin:vaadin-dev-server:jar:24.6.0:compile
[INFO] | | | +- com.vaadin:license-checker:jar:1.13.3:compile
[INFO] | | | | +- com.github.oshi:oshi-core:jar:6.6.5:compile
the quarkus build uses the following native image builder
quay.io/quarkus/ubi-quarkus-mandrel-builder-image:jdk-21
How to Reproduce?
Steps to reproduce:
- Goto https://code.quarkus.io/ and select vaadin Flow
- Generate,Download and extract the Application
- Build it with native mode: ./mvnw clean package -Pproduction,native
Output of uname -a
or ver
Linux arch 6.12.6-arch1-1 #1 SMP PREEMPT_DYNAMIC Thu, 19 Dec 2024 21:29:01 +0000 x86_64 GNU/Linux
Output of java -version
openjdk version "21.0.5" 2024-10-15 OpenJDK Runtime Environment (build 21.0.5+11) OpenJDK 64-Bit Server VM (build 21.0.5+11, mixed mode, sharing)
Mandrel or GraalVM version (if different from Java)
No response
Quarkus version or git rev
3.17.5
Build tool (ie. output of mvnw --version
or gradlew --version
)
apache-maven-3.9.9
Additional information
No response