modules without classes
Mandy Chung
mandy.chung at oracle.com
Wed Nov 30 09:05:53 PST 2011
On 11/30/2011 6:42 AM, Alan Bateman wrote:
>
> I was chatting with Peter Jensen about a problem he's seeing trying to
> install some of our current jdk* modules that that only has a
> module-info. It turns out the recent refactoring of the module
> reader/writer code breaks this case as the index creation assumes that
> the there are classes in the module directory. This is no longer the
> case when installing a jmod file that doesn't have a CLASSES section.
What is broken? jmod reindex?
Before the refactoring, jpkg creates a jmod file with a CLASSES section
even if there is no class in the module (I think it has the
module-info.class in it). I fixed that bug to create the CLASSES
section only if there is at least one class file in the module.
> I'll sort this out and add a test so that we catch this scenario but
> it begs the question as to whether it make sense to have an empty
> classes in the module directory or not? I think it should be okay to
> not require it (if for no other reason that many zip tools don't
> tolerate empty zip files anyway).
I think so too.
Mandy
More information about the jigsaw-dev
mailing list