如何编译依赖于GRADLE-BUILT项目的ANT项目?

时间:2019-05-16 15:17:19

标签: java gradle ant

我有一个由几个项目组成的Web应用程序:后端是gradle编译的,并且依赖于一个实体(也就是gradle-build)的项目。但是,我的web服务项目是ant编译的,但也取决于gradle编译的entities-project。

目前,我无法从webservice ant编译中编译deEntitys-project。如何在我的scripts / build.xml中添加依赖项,以使用我的ant webservice项目中的gradle进行编译?

  • 这是我在 build-dependencies .xml中创建jar的方式:

        <!--  By default the dependant projects are compiled as a result of a Check Out   -->
    <target name="co.dependency" depends="tag.or.head" unless="use.local">
        <subant target="dist" 
                antfile="build.xml" 
                    buildpath="${tmp.dir}/${dependent.git.project.repo}.${dependent.git.project.tag}/scripts"/>
        <copy todir="${lib.dir}" file="${tmp.dir}/${dependent.git.project.repo}.${dependent.git.project.tag}/dist/${dependent.project.name}.jar" />
        <copy todir="${lib.dir}" file="${tmp.dir}/${dependent.git.project.repo}.${dependent.git.project.tag}/dist/license-loader.jar" />
    </target>
    
  • 这是我收到的错误消息

    dist:
         [copy] Copying 1 file to /home/myuser/projects/entities-project/dist
         [copy] Copying 1 file to /home/myuser/projects/entities-project/dist
     [trycatch] Caught exception: The following error occurred while executing this line:
     [trycatch] /home/myuser/projects/WebService/scripts/build-dependencies.xml:91: Warning: Could not find file /home/muyser/projects/entities-project/dist/entities-project.jar to copy.
    

    建立失败 /home/myuser/projects/WebService/scripts/build.xml:49:无消息

0 个答案:

没有答案