Chris Marusich <cmmarus...@gmail.com> writes:

>>       o How to make the maven-build-system to never ever include other
>>         jar? Perhaps we need to post-process the generated jars.
>
> Speaking of JAR files, shouldn't we try to avoid them entirely?  My
> understanding is that they are compressed files, which means the Guix
> daemon won't be able to scan them for references.  I don't know if it's
> easy to use Maven to build a project without putting the build output
> into a JAR file, though.

For the record, I looked into this a little more.  I was mistaken: JAR
files are not necessarily compressed.  In fact, it seems [1][2] that it
should always be possible to make un-compressed JARs.  So, perhaps the
Guix daemon will not have trouble scanning JARs for references, after
all.  (Whether or not any references will actually be retained in the
JARs produced by Maven is another question; I don't know the answer.)

[1] "The special value 0 instructs the packer to copy through the
original JAR file directly, with no compression. The JSR 200 standard
requires any unpacker to understand this special case as a pass-through
of the entire archive."
https://docs.oracle.com/javase/8/docs/api/java/util/jar/Pack200.Packer.html#EFFORT

[2] "(Zero) Creates (c) or updates (u) the JAR file without using ZIP
compression.":
https://docs.oracle.com/javase/8/docs/technotes/tools/windows/jar.html

-- 
Chris

Attachment: signature.asc
Description: PGP signature

Reply via email to