代码之家  ›  专栏  ›  技术社区  ›  mike

简单的ApacheAnt问题:包括库依赖项

  •  0
  • mike  · 技术社区  · 17 年前

    这就是我到目前为止所做的:

    <target name="create-metrics-client" depends="clean,build">
        <jar destfile="sd-metrics-client.jar" basedir="${build.home}">
            <manifest>
                <attribute name="Main-Class" value="com.mycompany.client.MetricsDaemon"/>
            </manifest>
            <include name="com/mycompany/client/*"/>
            <include name="com/mycompany/portable/util/*"/>
            <include name="com/mycompany/request/*"/>
            <include name="com/mycompany/model/*"/>
            <include name="com/mycompany/controller/*"/>
            <include name="lib/*"/>
        </jar>
    </target>
    

    提前非常感谢各位!

    1 回复  |  直到 17 年前
        1
  •  0
  •   skaffman    17 年前

    你不能像那样嵌套JAR文件。如果你想做这样的事情,你需要使用一个工具,比如 OneJar UberJar .

    推荐文章