如何使红线转速图书馆工作与蚂蚁? [英] How to make Redline RPM Library work with Ant?

查看:211
本文介绍了如何使红线转速图书馆工作与蚂蚁?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我使用Ant作为构建工具,我把此行到我的Ant脚本在开始的时候:

I use Ant as a build tool, I put this line into my Ant script at the very beginning:

<taskdef name="pure-java-rpm" classname="org.redline_rpm.ant.RedlineTask" classpath="lib/ant/redline-1.1.16.jar" />

我再调用它:

<pure-java-rpm group="Games" name="${project-unix-name}" version="0" destination="${destdir}">
        <zipfileset prefix="/usr/share/games/${project-unix-name}" file="${destdir}/${game-jar-filename}"/>
        <depends name="java" version=">= 1.7"/>
    </pure-java-rpm>

我收到以下错误信息:
构建失败
/home/gouessej/Documents/programmation/java/workspace/tuer/build.xml:445:java.lang.NoClassDefFoundError的:组织/阿帕奇/共享/ COM preSS / COM pressors / bzip2的/ BZip2Com pressorInputStream

I get the following error message: BUILD FAILED /home/gouessej/Documents/programmation/java/workspace/tuer/build.xml:445: java.lang.NoClassDefFoundError: org/apache/commons/compress/compressors/bzip2/BZip2CompressorInputStream

然而,阿帕奇共享的COM preSS没有被提及,它似乎并没有被按的使用页面。难道我真的要添加的Apache下议院的COM preSS这个任务定义的类路径,使其工作?有另一种解决方案?

However, Apache Commons Compress isn't mentioned, it doesn't seem to be a dependency of this library according to the "usage" page. Do I really have to add Apache Commons Compress into the classpath of this task definition to make it work? Is there another solution?

推荐答案

的说明不提的依赖关系,你至少需要SLF4J,Bountycastle,XZ和Apache下议院的COM preSS使用红线RPM。我刚刚修改了我的任务定义:

The instructions don't mention the dependencies, you need at least SLF4J, Bountycastle, XZ and Apache Commons Compress to use Redline RPM. I've just modified my task definition:

<taskdef name="pure-java-rpm" classname="org.redline_rpm.ant.RedlineTask">
    <classpath>
        <pathelement path="bcpg-jdk15on-151.jar"/>
        <pathelement path="commons-compress-1.8.1.jar"/>
        <pathelement path="slf4j-api-1.7.7.jar"/>
        <pathelement path="slf4j-simple-1.7.7.jar"/>
        <pathelement path="xz-1.4.jar"/>
        <pathelement path="redline-1.1.16.jar"/>
    </classpath>
</taskdef>

您可以在这里找到这些JAR文件:

You can find those JARs here:

阿帕奇共享的COM preSS

BouncyCastle的

SLF4J

XZ

这篇关于如何使红线转速图书馆工作与蚂蚁?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆