以下是构建输出,我已尝试过每一件事甚至从互联网下载CompiereSecureDefault.properties并粘贴在输出中提到的目录但它不起作用。有什么建议吗?
构建文件:C:\ Users \ Public \ Compiere \ Compiere \ utils_dev \ build.xml
init:
[echo] =========== Build Compiere - ${env.ENCODING}
[echo] java.home = D:\ProgramsandFiles\Java\jre6
[echo] Java Version = 1.6.0_45 Sun Microsystems Inc.
[exec] Execute failed: java.io.IOException: Cannot run program "svnversion" (in directory "C:\Users\Public\Compiere\Compiere"): CreateProcess error=2, The system cannot find the file specified
[echo] =========== SVN Revision Core = ${svnoutput}
build:
toolsInit:
[echo] =========== Build Tools ${env.COMPIERE_VERSION}
toolsCompile:
toolsServer:
toolsClient:
toolsAppsServer:
toolsDatabase:
toolsDistribution:
init:
[echo] =========== Build Common
makedir:
compile:
dist:
initAD:
[echo] =========== Build AD
compileAD:
distAD:
printInit:
[echo] =========== Build Print
printMakedir:
printCompile:
printDistribute:
init:
[echo] =========== Build Base
makedir:
compile:
[javac] Compiling 2 source files to C:\Users\Public\Compiere\Compiere\base\build
dist:
clientInit:
[echo] =========== Build Client
clientMakedir:
clientCompile:
clientDistribute:
[unjar] Expanding: C:\Users\Public\Compiere\Compiere\common\Common.jar into C:\Users\Public\Compiere\Compiere\client\build
[unjar] Expanding: C:\Users\Public\Compiere\Compiere\ad\AD.jar into C:\Users\Public\Compiere\Compiere\client\build
[unjar] Expanding: C:\Users\Public\Compiere\Compiere\base\Base.jar into C:\Users\Public\Compiere\Compiere\client\build
[unjar] Expanding: C:\Users\Public\Compiere\Compiere\print\Print.jar into C:\Users\Public\Compiere\Compiere\client\build
[unjar] Expanding: C:\Users\Public\Compiere\Compiere\interfaces\Interfaces.jar into C:\Users\Public\Compiere\Compiere\client\build
[delete] Deleting directory C:\Users\Public\Compiere\Compiere\client\build\META-INF
[jar] Building jar: C:\Users\Public\Compiere\Compiere\lib\Compiere.jar
[jar] Building jar: C:\Users\Public\Compiere\Compiere\lib\CompiereInstall.jar
compiereRootInit:
[echo] =========== Build Server Root
compiereRootXdoclet:
[echo] XDoclet=../tools
[echo] UpToDate=true
[ejbdoclet] Generating Home interface for 'org.compiere.session.ServerBean'.
[ejbdoclet] Generating Home interface for 'org.compiere.session.StatusBean'.
[ejbdoclet] Generating Local interface for 'org.compiere.session.ServerBean'.
[ejbdoclet] Generating Local interface for 'org.compiere.session.StatusBean'.
[ejbdoclet] Generating Local Home interface for 'org.compiere.session.ServerBean'.
[ejbdoclet] Generating Local Home interface for 'org.compiere.session.StatusBean'.
[ejbdoclet] Generating Remote interface for 'org.compiere.session.ServerBean'.
[ejbdoclet] Generating Remote interface for 'org.compiere.session.StatusBean'.
[ejbdoclet] Generating EJB deployment descriptor (ejb-jar.xml).
compiereRootCompile:
[javac] Compiling 8 source files to C:\Users\Public\Compiere\Compiere\serverRoot\build\classes
compiereRootJar:
[jar] Building jar: C:\Users\Public\Compiere\Compiere\serverRoot\build\deploy\compiereRoot.jar
compiereRootWar:
[copy] Copying 1 file to C:\Users\Public\Compiere\Compiere\serverRoot\src\web
[war] Building war: C:\Users\Public\Compiere\Compiere\serverRoot\build\deploy\compiereRootBase.war
[delete] Deleting: C:\Users\Public\Compiere\Compiere\serverRoot\src\web\compiere.jnlp
wasCompiereRootWar:
[copy] Copying 1 file to C:\Users\Public\Compiere\Compiere\serverRoot\src\web
[war] Building war: C:\Users\Public\Compiere\Compiere\serverRoot\build\deploy\compiereRootBase_was.war
[delete] Deleting: C:\Users\Public\Compiere\Compiere\serverRoot\src\web\compiere.jnlp
compiereRootInterfaces:
[javac] Compiling 8 source files to C:\Users\Public\Compiere\Compiere\interfaces\classes
[jar] Building jar: C:\Users\Public\Compiere\Compiere\interfaces\Interfaces.jar
compiereRootDeployServer:
[copy] Copying 3 files to C:\Users\Public\Compiere\Compiere\lib
main:
serverAppsInit:
[echo] =========== Build Server Application
serverAppsCompile:
serverAppsJar:
[jar] Building jar: C:\Users\Public\Compiere\Compiere\serverApps\build\jar\compiereApps.jar
serverAppsWar:
[war] Building war: C:\Users\Public\Compiere\Compiere\serverApps\build\deploy\compiereAppsBase.war
serverAppsDeployServer:
[copy] Copying 2 files to C:\Users\Public\Compiere\Compiere\lib
main:
init:
[echo] =========== Build Web Store
war:
[war] Building war: C:\Users\Public\Compiere\Compiere\webStore\build\deploy\compiereWebStoreBase.war
deploy-server:
[copy] Copying 1 file to C:\Users\Public\Compiere\Compiere\lib
main:
webCMinit:
[echo] =========== Build webCM
webCMcompile:
webCMwar:
[war] Building war: C:\Users\Public\Compiere\Compiere\webCM\deploy\compiereWebCMbase.war
webCMdeployServer:
[copy] Copying 1 file to C:\Users\Public\Compiere\Compiere\lib
main:
sqljInit:
[echo] =========== Build SQLJ
sqljCompile:
sqljDist:
[jar] Building jar: C:\Users\Public\Compiere\Compiere\sqlj\sqlj.jar
[jar] Building jar: C:\Users\Public\Compiere\Compiere\sqlj\sqljDB2.jar
init:
[echo] =========== Build Extend
makedir:
compile:
dist:
[jar] Building jar: C:\Users\Public\Compiere\Compiere\extend\Extend.jar
[unjar] Expanding: C:\Users\Public\Compiere\Compiere\lib\Compiere.jar into C:\Users\Public\Compiere\Compiere\extend\build
[jar] Building jar: C:\Users\Public\Compiere\Compiere\lib\Compiere.jar
[jar] Warning: selected jar files include a META-INF/INDEX.LIST which will be replaced by a newly generated one.
installInit:
[echo] =========== Build Install - ${env.ENCODING}
installCompile:
[unjar] Expanding: C:\Users\Public\Compiere\Compiere\tools\lib\ant.jar into C:\Users\Public\Compiere\Compiere\install\lib
[unjar] Expanding: C:\Users\Public\Compiere\Compiere\tools\lib\ant-launcher.jar into C:\Users\Public\Compiere\Compiere\install\lib
[unjar] Expanding: C:\Users\Public\Compiere\Compiere\tools\lib\ant-commons-net.jar into C:\Users\Public\Compiere\Compiere\install\lib
[unjar] Expanding: C:\Users\Public\Compiere\Compiere\tools\lib\commons-net-1.4.0.jar into C:\Users\Public\Compiere\Compiere\install\lib
[delete] Deleting: C:\Users\Public\Compiere\Compiere\install\lib\META-INF\MANIFEST.MF
[jar] Building jar: C:\Users\Public\Compiere\Compiere\install\CInstall.jar
installUpdate:
installDistribution:
[copy] Copying 9 files to C:\Users\Public\Compiere\Compiere\install\build\Compiere2\lib
[copy] Copying 1 file to C:\Users\Public\Compiere\Compiere\install\build\Compiere2\lib
[copy] Copying 1 file to C:\Users\Public\Compiere\Compiere\install\build\Compiere2\lib
[copy] Copying 1 file to C:\Users\Public\Compiere\Compiere\install\build\Compiere2\lib
[zip] Building zip: C:\Users\Public\Compiere\Compiere\install\build\Compiere_${env.COMPIERE_VERSION_FILE}.zip
[tar] Building tar: C:\Users\Public\Compiere\Compiere\install\build\Compiere_${env.COMPIERE_VERSION_FILE}.tar
[gzip] Building: C:\Users\Public\Compiere\Compiere\install\build\Compiere_${env.COMPIERE_VERSION_FILE}.tar.gz
[delete] Deleting: C:\Users\Public\Compiere\Compiere\install\build\Compiere_${env.COMPIERE_VERSION_FILE}.tar
install:
[echo] =========== Install Compiere
[copy] Copying 4 files to C:\Users\Public\Compiere\Compiere\${env.COMPIERE_INSTALL}
[unzip] Expanding: C:\Users\Public\Compiere\Compiere\install\build\Compiere_${env.COMPIERE_VERSION_FILE}.zip into C:\Users\Public\Compiere\Compiere\${env.COMPIERE_ROOT}
setupInit:
[echo] Compiere Server Setup ===================
[echo] COMPIERE_HOME = D:\ProgramsandFiles\Compiere2
[echo] Environment = CompiereEnv.properties
[echo] Java VM = sun
[echo] Database = oracleXE
[echo] Apps Server = jboss
[echo] AppsDeployment= D:\ProgramsandFiles\Compiere2\jboss\server\compiere\deploy
[echo] Ant Version = Apache Ant version 1.7.1 compiled on June 27 2008
[echo] Java Home = D:\ProgramsandFiles\Java\jre6
[echo] Java Version = 1.6.0_45 Sun Microsystems Inc.
[echo] Windows=true JBoss=true Tomcat=${isAppsTomcat} WAS=${isIBMWAS}
[echo] BaseJars=
[echo] lib/ext= ${lib.ext.jar.exists}
[echo] data/images= ${data.images.png.exists}
setupCompiere:
secureCopy:
BUILD FAILED
C:\Users\Public\Compiere\Compiere\utils_dev\build.xml:78: The following error occurred while executing this line:
D:\ProgramsandFiles\Compiere2\build.xml:127: Warning: Could not find file D:\ProgramsandFiles\Compiere2\lib\CompiereSecureDefault.properties to copy.
总时间:8分57秒
答案 0 :(得分:0)
不幸的是,你给了我们很多信息,但不是我们真正需要的信息。错误消息很好(我们不需要整个构建输出),但我们没有build.xml
的相关部分失败。
我看到了错误:
C:\Users\Public\Compiere\Compiere\utils_dev\build.xml:78: The following error occurred while executing this line:
D:\ProgramsandFiles\Compiere2\build.xml:127: Warning: Could not find file \
D:\ProgramsandFiles\Compiere2\lib\CompiereSecureDefault.properties to copy.
看起来你喜欢从另一个调用一个构建文件。该错误已报告给utils_dev
中的构建文件,该文件显然称为Compiere2
中的构建文件。在第二个build.xml
文件的第127行,您正在执行某种<copy/>
任务,并且您正在以某种方式指定要复制的文件lib/CompiereSecureDefault.properties
,但是这样的文件不存在。
您可以执行以下操作:
Compiere2\lib\CompiereSecureDefault.properties
是否存在或不存在。我认为你正在做这样的事情:
<copy todir="${basedir}/blah/blah"
file="${basedir}/lib/CompiereSecureDefault.properties"/>
您可以将此更改为以下内容:
<copy todir="${basedir}/blah/blah">
<fileset dir="${basedir}/lib">
<include name="CompiereSecureDefault.properties"/>
</fileset>
</copy>
如果找不到该特定文件,后一种设置不应该使构建失败。 (如果<fileset dir="...">
中的目录不存在,则会失败。)
正确的代码,其中包含.properties文件的副本。
<target name="secureCopy"
unless="secure.exists">
<copy file="lib/CompiereSecureDefault.properties"
tofile="lib/CompiereSecure.properties" overwrite="no" />
</target>
您可以添加:
<target name="secureCopy"
unless="secure.exists">
<copy file="lib/CompiereSecureDefault.properties"
failonerror="false"
tofile="lib/CompiereSecure.properties" overwrite="no" />
</target>
然而,还有一些问题。什么是属性secure.exists
,为什么没有设置?仅当此属性未设置时才会执行此任务。
此外,该文件是否存在?这是它失败的原因吗?它应该存在吗?在添加failonerror
参数之前,您需要弄清楚这一点。