RFR: 8345259: When linking from the run-time image ALL-MODULE-PATH is not accepted
Severin Gehwolf
sgehwolf at openjdk.org
Tue Dec 3 19:07:42 UTC 2024
On Tue, 3 Dec 2024 18:01:18 GMT, Mandy Chung <mchung at openjdk.org> wrote:
> > ALL-MODULE-PATH means all observable modules on the module path but here, it's all observable modules minus jdk.jlink or any module that directly requires jdk.jlink. This is hard to reason about, and not exactly right either because any filtering should be any module that transitively requires jdk.jlink.
>
> I have the same comment. ALL-MODULE-PATH means all observable modules on the module path that includes `jdk.jlink`. It would be confusing if the resulting image linked from the run-time image is different than the image linked from packaged modules. I think it may just be another restriction that `--add-modules ALL-MODULE-PATH` can't be used when linking from the run-time image for now and removed together when the other restriction is removed.
That makes sense. As long as we handle it, I'm fine. So my thinking then is:
- Abort the link with an appropriate error when `ALL-MODULE-PATH` is being used and a link from the run-time image is used but no module path given (`--module-path` arg missing).
- Continue as is now when linking from the run-time image, `--add-modules ALL-MODULE-PATH` is given, and `--module-path` arg is given as well (there is no difference to a run with packaged modules).
Does that sound OK to you?
-------------
PR Comment: https://git.openjdk.org/jdk/pull/22494#issuecomment-2515339531
More information about the core-libs-dev
mailing list