从最新的java版本(7u45)开始,我在我的webstart应用程序使用的第三部分jar库上收到了大量的错误,因为新需要的清单属性丢失了:
Missing Application-Name: manifest attribute for: http://site/lib/jh.jar
Missing Permissions manifest attribute for: http://site/lib/jh.jar
Missing Codebase manifest attribute for: http://lib/jh.jar因此,我需要运行一个批处理ant任务来更新所需的大约30个库中的每个库中的清单文件,然后才能使用它们进行分发。
我如何在ant中做到这一点?(最好不要使用ant-contrib)
PS:我已经修复了所有其他的7u45更新垃圾(代码签名,JNLP属性,等等)。
发布于 2013-12-17 21:06:04
试试这样的东西。
<for param="jarFile">
<fileset dir="${webapp.dir}">
<include name="*.jar"/>
</fileset>
<sequential>
<jar update="true" file="@{jarFile}">
<manifest>
<attribute name="Application-Name" value="ABCDEF"/>
<attribute name="Codebase" value="*"/>
<attribute name="Permissions" value="all-permissions"/>
</manifest>
</jar>
</sequential>
</for>https://stackoverflow.com/questions/20108199
复制相似问题