什么是失败的原因

什么是失败的原因

本文介绍了什么是失败的原因:"的jarsigner:尝试重命名文件{}到{}文件失败.org的"签署与蚂蚁罐的时候?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我收到错误:

[signjar]的jarsigner:尝试重新命名
  C:\\工作区\\ line_editor \\ LIB \\ icon.jar
  至
  C:\\工作区\\ line_editor \\ LIB \\ icon.jar.orig
  失败

签订一组在Eclipse蚂蚁罐子。 Ant构建在这个项目和类似code在其他项目上工作得很好。我做了一些小的改动code,并试图重建并保持收到此错误。

when attempting to self sign a set of jars with ant inside Eclipse. The ant build has worked fine in this project and similar code in other projects. I made some small changes to code and tried to rebuild and keep getting this error.

下面是相关的Ant目标:

Here is the related ant target:

<target name="sign" depends="jar" description="Signs Jars">

        <genkey keystore="myKeystore1" alias="something" storepass="somethingpass"
          dname="CN=Classification, OU=NAPA, O=GPC, C=US"/>


        <signjar keystore="myKeystore1" alias="something" storepass="somethingpass">
            <fileset file="${web.dir}/${jar.name}" />
            <fileset dir="${lib.dir}">
                <include name="*.jar"/>
            </fileset>
        </signjar>
    </target>

我删除了项目,并从我们的代码库再拉下来。因此,它具有相同的默认项目设置,这一部分并没有失败等项目。我看了看问题的.jar和它不是只读的。我改了名字和一个字母.jar文件也失败了。有没有正在访问此文件夹中的.jar文件程序运行。

I deleted the project and pulled it down again from our repository. So it has the same default project settings as other projects that this part does not fail. I looked at the .jar in question and it was not read-only. I changed the name and the next alphabetical .jar file also failed. There is no program running that is accessing the .jars in this folder.

作为任何建议,以引起?

Any suggestions as to cause?

推荐答案

一种可能性是,罐子 - 这是在一个'库'目录 - 是您的构建过程中使用的类路径。是否包括在构建文件中使用的类路径 $ {lib.dir}

One possibility is that the jar - which is in a 'lib' directory - is on a classpath in use during your build. Is ${lib.dir} included on a classpath used in the buildfile?

您可以创建一个单独的目录存放签署的jar,并使用 DESTDIR 属性。

You could create a separate directory to deposit signed jars to, and specify that to the 'signjar' task using the destdir attribute.

这篇关于什么是失败的原因:&QUOT;的jarsigner:尝试重命名文件{}到{}文件失败.org的&QUOT;签署与蚂蚁罐的时候?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

08-21 02:18