javac package not found or does not exist

I have a project written in Java 12 (fairly new to java9+ and using modules) and I want to use jlink to create a custom runtime image. I also want to use apache.commons.cli as a 3rd party library for my project. How can I make use of automatic modules and compile in order to create a jlink image?

I am getting errors like so: error: package is empty or does not exist: org.apache.commons.cli
exports org.apache.commons.cli;
1 error

My structure is as follows:

│ └───com
│ └───ngdesk
│ ├───com
│ │ └───ngdesk
│ └───out
│ ├───com
│ │ └───ngdesk
│ ├───META-INF
│ │ └───maven
│ │ └───ngDesk-ControlApp
│ │ └───ngDesk-ControlApp
│ └───out

Leave a Reply

Notify of