Maven 2.x JAR Plugin

Invalid jar manifest created

Details

  • Type: Bug Bug
  • Status: Closed Closed
  • Priority: Blocker Blocker
  • Resolution: Duplicate
  • Affects Version/s: None
  • Fix Version/s: 2.1
  • Component/s: None
  • Labels:
    None
  • Environment:
    distributed maven 2.0.2
  • Number of attachments :
    1

Description

I've found a bug I consider critical (probably because it took me many hours to track down) if a multiline description is added to the pom
the jar manifest will be broken, terrible things will happen from there.

Issue Links

Activity

Hide
Marvin King added a comment -

can you give more details? what sort of problems occur when multiline description is used?
concrete examples will be greatly appreciated, much better if you can attach your generated jar file.

so far the specification support multiline values. see the jar specification

— Specification snippet which applies to the Jar Manifest ----

newline : CR LF | LF | CR ( without LF )
value : SPACE *otherchar newline
*continuation
continuation : SPACE *otherchar newline
otherchar : any UTF-8 character except for NUL,CR & LF

Show
Marvin King added a comment - can you give more details? what sort of problems occur when multiline description is used? concrete examples will be greatly appreciated, much better if you can attach your generated jar file. so far the specification support multiline values. see the jar specification — Specification snippet which applies to the Jar Manifest ---- newline : CR LF | LF | CR ( without LF ) value : SPACE *otherchar newline *continuation continuation : SPACE *otherchar newline otherchar : any UTF-8 character except for NUL,CR & LF
Hide
Carlos Sanchez added a comment -

I think the problem is that the first space is not added.

Show
Carlos Sanchez added a comment - I think the problem is that the first space is not added.
Hide
Miguel Griffa added a comment -

actually I've lost interest in this issue and in contributing to maven in general, I am so, so much dissapointed with the community that have got back to ant, after being a maven user since 1.0 alpha, I just don't want to deal with it anymore

Show
Miguel Griffa added a comment - actually I've lost interest in this issue and in contributing to maven in general, I am so, so much dissapointed with the community that have got back to ant, after being a maven user since 1.0 alpha, I just don't want to deal with it anymore
Hide
Jerome Lacoste added a comment -

I started writing unit tests for the issue.

After talking with jdcasey we agree that it is best to fix this in plexus-archiver. The only notable downside is that Manifest instances will not contain stripped out fields. Will improve the javadoc.

Show
Jerome Lacoste added a comment - I started writing unit tests for the issue. After talking with jdcasey we agree that it is best to fix this in plexus-archiver. The only notable downside is that Manifest instances will not contain stripped out fields. Will improve the javadoc.
Hide
Jerome Lacoste added a comment -

Update the doc. The fix will go in plexus.

Show
Jerome Lacoste added a comment - Update the doc. The fix will go in plexus.
Hide
Jerome Lacoste added a comment -

I am not 100% sure the attached patch is correct anymore. See http://jira.codehaus.org/browse/PLX-185#action_63432

Adding a javadoc comment might still be interesting, but should be adapted to something like "some jar reader implementations might not like special characters, even though they are allowed by the spec".

Show
Jerome Lacoste added a comment - I am not 100% sure the attached patch is correct anymore. See http://jira.codehaus.org/browse/PLX-185#action_63432 Adding a javadoc comment might still be interesting, but should be adapted to something like "some jar reader implementations might not like special characters, even though they are allowed by the spec".

People

Vote (0)
Watch (1)

Dates

  • Created:
    Updated:
    Resolved: