You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@maven.apache.org by "Fredrik Vraalsen (JIRA)" <ji...@codehaus.org> on 2006/05/09 12:35:41 UTC
[jira] Created: (MJAR-41) Cannot specify additional classpath
entries in jar manifest when using addClasspath
Cannot specify additional classpath entries in jar manifest when using addClasspath
-----------------------------------------------------------------------------------
Key: MJAR-41
URL: http://jira.codehaus.org/browse/MJAR-41
Project: Maven 2.x Jar Plugin
Type: Bug
Versions: 2.1, 2.0
Environment: Maven 2.0.4, maven-jar-plugin 2.0 and 2.1-SNAPSHOT, JDK 1.5.0_06, Windows XP
Reporter: Fredrik Vraalsen
The plugin configuration snippet below leads to the generation of an illegal jar manifest file, as it contains two Class-Path entries. This works in Maven 1.1b2 by adding the following to project.properties:
maven.jar.manifest.classpath.add=true
maven.jar.classpath=help/ resources/
For more information, please see http://www.nabble.com/classpath-in-jar-manifest-t1582724.html
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-jar-plugin</artifactId>
<configuration>
<archive>
<manifest>
<addClasspath>true</addClasspath>
</manifest>
<manifestEntries>
<Class-Path>help/ resources/</Class-Path>
</manifestEntries>
</archive>
</configuration>
</plugin>
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira
[jira] Commented: (MJAR-41) Cannot specify additional classpath
entries in jar manifest when using addClasspath
Posted by "Fredrik Vraalsen (JIRA)" <ji...@codehaus.org>.
[ http://jira.codehaus.org/browse/MJAR-41?page=comments#action_65018 ]
Fredrik Vraalsen commented on MJAR-41:
--------------------------------------
See http://jira.codehaus.org/browse/MNG-2284 for a simple patch that solved the issue for me.
> Cannot specify additional classpath entries in jar manifest when using addClasspath
> -----------------------------------------------------------------------------------
>
> Key: MJAR-41
> URL: http://jira.codehaus.org/browse/MJAR-41
> Project: Maven 2.x Jar Plugin
> Type: Bug
> Versions: 2.1, 2.0
> Environment: Maven 2.0.4, maven-jar-plugin 2.0 and 2.1-SNAPSHOT, JDK 1.5.0_06, Windows XP
> Reporter: Fredrik Vraalsen
>
>
> The plugin configuration snippet below leads to the generation of an illegal jar manifest file, as it contains two Class-Path entries. This works in Maven 1.1b2 by adding the following to project.properties:
> maven.jar.manifest.classpath.add=true
> maven.jar.classpath=help/ resources/
> For more information, please see http://www.nabble.com/classpath-in-jar-manifest-t1582724.html
> <plugin>
> <groupId>org.apache.maven.plugins</groupId>
> <artifactId>maven-jar-plugin</artifactId>
> <configuration>
> <archive>
> <manifest>
> <addClasspath>true</addClasspath>
> </manifest>
> <manifestEntries>
> <Class-Path>help/ resources/</Class-Path>
> </manifestEntries>
> </archive>
> </configuration>
> </plugin>
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira
[jira] Commented: (MJAR-41) Cannot specify additional classpath
entries in jar manifest when using addClasspath
Posted by "Tim Kettler (JIRA)" <ji...@codehaus.org>.
[ http://jira.codehaus.org/browse/MJAR-41?page=comments#action_66450 ]
Tim Kettler commented on MJAR-41:
---------------------------------
Is it really illegal to have more than one Class-Path entry in a manifest?
See http://java.sun.com/j2se/1.5.0/docs/guide/extensions/spec.html. Especially the line 'Multiple Class-Path headers may be specified, and are combined sequentially.'.
The document is for Java 1.5. I haven't checked if this beaviour is also true for earlier java versions.
> Cannot specify additional classpath entries in jar manifest when using addClasspath
> -----------------------------------------------------------------------------------
>
> Key: MJAR-41
> URL: http://jira.codehaus.org/browse/MJAR-41
> Project: Maven 2.x Jar Plugin
> Type: Bug
> Versions: 2.1, 2.0
> Environment: Maven 2.0.4, maven-jar-plugin 2.0 and 2.1-SNAPSHOT, JDK 1.5.0_06, Windows XP
> Reporter: Fredrik Vraalsen
>
>
> The plugin configuration snippet below leads to the generation of an illegal jar manifest file, as it contains two Class-Path entries. This works in Maven 1.1b2 by adding the following to project.properties:
> maven.jar.manifest.classpath.add=true
> maven.jar.classpath=help/ resources/
> For more information, please see http://www.nabble.com/classpath-in-jar-manifest-t1582724.html
> <plugin>
> <groupId>org.apache.maven.plugins</groupId>
> <artifactId>maven-jar-plugin</artifactId>
> <configuration>
> <archive>
> <manifest>
> <addClasspath>true</addClasspath>
> </manifest>
> <manifestEntries>
> <Class-Path>help/ resources/</Class-Path>
> </manifestEntries>
> </archive>
> </configuration>
> </plugin>
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira
[jira] Updated: (MJAR-41) Cannot specify additional classpath
entries in jar manifest when using addClasspath
Posted by "Fredrik Vraalsen (JIRA)" <ji...@codehaus.org>.
[ http://jira.codehaus.org/browse/MJAR-41?page=all ]
Fredrik Vraalsen updated MJAR-41:
---------------------------------
Attachment: MJAR-41.patch
patch to update maven-archiver dependency to 2.2-SNAPSHOT
> Cannot specify additional classpath entries in jar manifest when using addClasspath
> -----------------------------------------------------------------------------------
>
> Key: MJAR-41
> URL: http://jira.codehaus.org/browse/MJAR-41
> Project: Maven 2.x Jar Plugin
> Issue Type: Bug
> Affects Versions: 2.0, 2.1
> Environment: Maven 2.0.4, maven-jar-plugin 2.0 and 2.1-SNAPSHOT, JDK 1.5.0_06, Windows XP
> Reporter: Fredrik Vraalsen
> Attachments: MJAR-41.patch
>
>
> The plugin configuration snippet below leads to the generation of an illegal jar manifest file, as it contains two Class-Path entries. This works in Maven 1.1b2 by adding the following to project.properties:
> maven.jar.manifest.classpath.add=true
> maven.jar.classpath=help/ resources/
> For more information, please see http://www.nabble.com/classpath-in-jar-manifest-t1582724.html
> <plugin>
> <groupId>org.apache.maven.plugins</groupId>
> <artifactId>maven-jar-plugin</artifactId>
> <configuration>
> <archive>
> <manifest>
> <addClasspath>true</addClasspath>
> </manifest>
> <manifestEntries>
> <Class-Path>help/ resources/</Class-Path>
> </manifestEntries>
> </archive>
> </configuration>
> </plugin>
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] Commented: (MJAR-41) Cannot specify additional classpath
entries in jar manifest when using addClasspath
Posted by "Fredrik Vraalsen (JIRA)" <ji...@codehaus.org>.
[ http://jira.codehaus.org/browse/MJAR-41?page=comments#action_67156 ]
Fredrik Vraalsen commented on MJAR-41:
--------------------------------------
It seems the spec and the implementation are not quite in agreement, unfortunately.
I've tested with multiple Class-Path entries in the manifest file, and this does not seem to work with JDK 1.5.0 update 6 on Windows XP at least. It gives the following output:
$ java -jar test.jar
12.jun.2006 11:48:10 java.util.jar.Attributes read
WARNING: Duplicate name in Manifest: Class-Path
12.jun.2006 11:48:10 java.util.jar.Attributes read
WARNING: Duplicate name in Manifest: Class-Path
and then I get a NoClassDefFoundError on one of the classes from the first Class-Path entry.
$ java -version
java version "1.5.0_06"
Java(TM) 2 Runtime Environment, Standard Edition (build 1.5.0_06-b05)
Java HotSpot(TM) Client VM (build 1.5.0_06-b05, mixed mode)
> Cannot specify additional classpath entries in jar manifest when using addClasspath
> -----------------------------------------------------------------------------------
>
> Key: MJAR-41
> URL: http://jira.codehaus.org/browse/MJAR-41
> Project: Maven 2.x Jar Plugin
> Type: Bug
> Versions: 2.1, 2.0
> Environment: Maven 2.0.4, maven-jar-plugin 2.0 and 2.1-SNAPSHOT, JDK 1.5.0_06, Windows XP
> Reporter: Fredrik Vraalsen
>
>
> The plugin configuration snippet below leads to the generation of an illegal jar manifest file, as it contains two Class-Path entries. This works in Maven 1.1b2 by adding the following to project.properties:
> maven.jar.manifest.classpath.add=true
> maven.jar.classpath=help/ resources/
> For more information, please see http://www.nabble.com/classpath-in-jar-manifest-t1582724.html
> <plugin>
> <groupId>org.apache.maven.plugins</groupId>
> <artifactId>maven-jar-plugin</artifactId>
> <configuration>
> <archive>
> <manifest>
> <addClasspath>true</addClasspath>
> </manifest>
> <manifestEntries>
> <Class-Path>help/ resources/</Class-Path>
> </manifestEntries>
> </archive>
> </configuration>
> </plugin>
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira
[jira] Closed: (MJAR-41) Cannot specify additional classpath
entries in jar manifest when using addClasspath
Posted by "Emmanuel Venisse (JIRA)" <ji...@codehaus.org>.
[ http://jira.codehaus.org/browse/MJAR-41?page=all ]
Emmanuel Venisse closed MJAR-41.
--------------------------------
Assignee: Emmanuel Venisse
Resolution: Fixed
Fix Version/s: 2.1
Applied. Thanks
> Cannot specify additional classpath entries in jar manifest when using addClasspath
> -----------------------------------------------------------------------------------
>
> Key: MJAR-41
> URL: http://jira.codehaus.org/browse/MJAR-41
> Project: Maven 2.x Jar Plugin
> Issue Type: Bug
> Affects Versions: 2.0, 2.1
> Environment: Maven 2.0.4, maven-jar-plugin 2.0 and 2.1-SNAPSHOT, JDK 1.5.0_06, Windows XP
> Reporter: Fredrik Vraalsen
> Assigned To: Emmanuel Venisse
> Fix For: 2.1
>
> Attachments: MJAR-41.patch
>
>
> The plugin configuration snippet below leads to the generation of an illegal jar manifest file, as it contains two Class-Path entries. This works in Maven 1.1b2 by adding the following to project.properties:
> maven.jar.manifest.classpath.add=true
> maven.jar.classpath=help/ resources/
> For more information, please see http://www.nabble.com/classpath-in-jar-manifest-t1582724.html
> <plugin>
> <groupId>org.apache.maven.plugins</groupId>
> <artifactId>maven-jar-plugin</artifactId>
> <configuration>
> <archive>
> <manifest>
> <addClasspath>true</addClasspath>
> </manifest>
> <manifestEntries>
> <Class-Path>help/ resources/</Class-Path>
> </manifestEntries>
> </archive>
> </configuration>
> </plugin>
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] Commented: (MJAR-41) Cannot specify additional classpath
entries in jar manifest when using addClasspath
Posted by "Fredrik Vraalsen (JIRA)" <ji...@codehaus.org>.
[ http://jira.codehaus.org/browse/MJAR-41?page=comments#action_71897 ]
Fredrik Vraalsen commented on MJAR-41:
--------------------------------------
This has now been fixed in maven-archiver 2.2-SNAPSHOT, so the dependencies in maven-jar-plugin should be updated accordingly.
> Cannot specify additional classpath entries in jar manifest when using addClasspath
> -----------------------------------------------------------------------------------
>
> Key: MJAR-41
> URL: http://jira.codehaus.org/browse/MJAR-41
> Project: Maven 2.x Jar Plugin
> Issue Type: Bug
> Affects Versions: 2.0, 2.1
> Environment: Maven 2.0.4, maven-jar-plugin 2.0 and 2.1-SNAPSHOT, JDK 1.5.0_06, Windows XP
> Reporter: Fredrik Vraalsen
>
> The plugin configuration snippet below leads to the generation of an illegal jar manifest file, as it contains two Class-Path entries. This works in Maven 1.1b2 by adding the following to project.properties:
> maven.jar.manifest.classpath.add=true
> maven.jar.classpath=help/ resources/
> For more information, please see http://www.nabble.com/classpath-in-jar-manifest-t1582724.html
> <plugin>
> <groupId>org.apache.maven.plugins</groupId>
> <artifactId>maven-jar-plugin</artifactId>
> <configuration>
> <archive>
> <manifest>
> <addClasspath>true</addClasspath>
> </manifest>
> <manifestEntries>
> <Class-Path>help/ resources/</Class-Path>
> </manifestEntries>
> </archive>
> </configuration>
> </plugin>
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira