Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Is it possible to specify the module path when creating a custom image via jlink? #110

Open
jaygazula27 opened this issue Oct 16, 2020 · 0 comments

Comments

@jaygazula27
Copy link

I'm currently using the Moditect plugin to add module descriptors to my dependencies. This is because some of the dependencies I would like to use have not included the module-info.java file.

As part of this plugin, the modified dependency JARs (which now contain the module descriptors) are placed in the ${project.build.directory}/modules directory. In order to compile properly, I simply add the --upgrade-module-path flag (via the compilerArgs configuration) to the maven-compiler-plugin plugin. This ensures that the ${project.build.directory}/modules directory is part of the module path during compilation.

However, I run into errors when the jlink custom image is being created since the javafx-maven-plugin does not know about this new directory path. It complains that the required modules are not found. I believe #104 would fix this (if I'm understanding it correctly), but I'm curious if there's already existing functionality that I'm simply missing.

In case it is helpful, I've attached the pom.txt file of my sample project. This shows how I'm using moditect-maven-plugin and the javafx-maven-plugin. Essentially, I'm converting dagger and javax.inject into modular dependencies and trying to add them to the module path.

Please let me know if you need any other information. Thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant