AJDT 无头 PDE 构建期间未设置 ajdt.pdebuild.scripts

发布于 2024-12-19 03:26:05 字数 2417 浏览 3 评论 0原文

我有一个在 eclipse 3.5 中开发的 eclipse rcp 应用程序。我能够通过以下目标条目在 ant 中成功执行 pde headless build(从 eclipse 外部的命令 shell):

<target name="compile">
    <java classname="org.eclipse.equinox.launcher.Main" fork="true" failonerror="true" dir="some-dir">
        <arg value="-application" />
        <arg value="org.eclipse.ant.core.antRunner" />
        <arg value="-buildfile" />
        <arg value="${eclipse.location}/plugins/org.eclipse.pde.build_${some-version}/scripts/productBuild/productBuild.xml" />
        <arg value="-Dtimestamp=${timestamp}" />
        <arg value="-propertyfile" />
        <arg value="${some-dir}/ant.properties" />
        <classpath>
            <pathelement
                 location="${eclipse.location}/plugins/org.eclipse.equinox.launcher_${some-version}.jar" />
        </classpath>
    </java>
</target>

但是一旦涉及 AspectJ (AJDT),我就修改了上面的目标,如下所示:

<target name="compile">
    <java classname="org.eclipse.equinox.launcher.Main" fork="true" failonerror="true" dir="${some-dir}">
        <arg value="-application" />
        <arg value="org.eclipse.ant.core.antRunner" />
        <arg value="-buildfile" />      
        **<arg value="${eclipse.location}/plugins/org.eclipse.ajdt.pde.build_2.0.2.e35x-release-20101021-0900/scripts/productBuild/productBuild.xml" />**
        <arg value="-Dtimestamp=${timestamp}" />
        <arg value="-propertyfile" />
        <arg value="${some-dir}/ant.properties" />
        **<jvmarg value="-Dajdt.pdebuild.home=${eclipse.location}/plugins/org.eclipse.ajdt.pde.build_2.0.2.e35x-release-20101021-0900" />**            
        <classpath>
            <pathelement
                          location="${eclipse.location}/plugins/org.eclipse.equinox.launcher_${some-version}.jar" />
        </classpath>
    </java>
</target>

不幸的是,我现在收到以下错误:

c:\eclipse-3.5\plugins\org.eclipse.ajdt.pde.build_2.0.2.e35x-release-20101021-0900\scripts\productBuild\productBuild.xml:8: 找不到 ${ajdt.pdebuild。脚本}/productBuild/allElements.xml 导入自c:\eclipse-3.5\plugins\org.eclipse.ajdt.pde.build_2.0.2.e35x-release-20101021-0900\scripts\productBuild\productBuild.xml

有没有人知道如何设置 ajdt.pdebuild。脚本值?谢谢你!!!

I have an eclipse rcp application being developed in eclipse 3.5. I am able to successfully execute pde headless build in ant (from command shell outside eclipse) via the following target entry:

<target name="compile">
    <java classname="org.eclipse.equinox.launcher.Main" fork="true" failonerror="true" dir="some-dir">
        <arg value="-application" />
        <arg value="org.eclipse.ant.core.antRunner" />
        <arg value="-buildfile" />
        <arg value="${eclipse.location}/plugins/org.eclipse.pde.build_${some-version}/scripts/productBuild/productBuild.xml" />
        <arg value="-Dtimestamp=${timestamp}" />
        <arg value="-propertyfile" />
        <arg value="${some-dir}/ant.properties" />
        <classpath>
            <pathelement
                 location="${eclipse.location}/plugins/org.eclipse.equinox.launcher_${some-version}.jar" />
        </classpath>
    </java>
</target>

But once AspectJ (AJDT) got involved, I modified the target above like so:

<target name="compile">
    <java classname="org.eclipse.equinox.launcher.Main" fork="true" failonerror="true" dir="${some-dir}">
        <arg value="-application" />
        <arg value="org.eclipse.ant.core.antRunner" />
        <arg value="-buildfile" />      
        **<arg value="${eclipse.location}/plugins/org.eclipse.ajdt.pde.build_2.0.2.e35x-release-20101021-0900/scripts/productBuild/productBuild.xml" />**
        <arg value="-Dtimestamp=${timestamp}" />
        <arg value="-propertyfile" />
        <arg value="${some-dir}/ant.properties" />
        **<jvmarg value="-Dajdt.pdebuild.home=${eclipse.location}/plugins/org.eclipse.ajdt.pde.build_2.0.2.e35x-release-20101021-0900" />**            
        <classpath>
            <pathelement
                          location="${eclipse.location}/plugins/org.eclipse.equinox.launcher_${some-version}.jar" />
        </classpath>
    </java>
</target>

Unfortunately, I am now getting the following error:

c:\eclipse-3.5\plugins\org.eclipse.ajdt.pde.build_2.0.2.e35x-release-20101021-0900\scripts\productBuild\productBuild.xml:8: Cannot find ${ajdt.pdebuild.scripts}/productBuild/allElements.xml imported from c:\eclipse-3.5\plugins\org.eclipse.ajdt.pde.build_2.0.2.e35x-release-20101021-0900\scripts\productBuild\productBuild.xml

does anyone have any idea on how to set the ajdt.pdebuild.scripts value? thank you!!!

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

拥醉 2024-12-26 03:26:05

请参阅此博客文章:

http://contraptionsforprogramming.blogspot.com/ 2010/03/ajdt-pde-builds-redux.html

您不应该使用 AJDT-PDE。这是旧的做事方式,不再受支持。相反,您应该对 build.properties 文件进行更改:

# required
compilerAdapter=org.eclipse.ajdt.core.ant.AJDT_AjcCompilerAdapter
sourceFileExtensions=*.java, *.aj

# optional
compilerArg=-aspectpath other.jar

阅读博客文章了解更多详细信息。

See this blog post:

http://contraptionsforprogramming.blogspot.com/2010/03/ajdt-pde-builds-redux.html

You should not be using AJDT-PDE. That is the old way of doing things and is no longer supported. Instead, you should be making changes to your build.properties file:

# required
compilerAdapter=org.eclipse.ajdt.core.ant.AJDT_AjcCompilerAdapter
sourceFileExtensions=*.java, *.aj

# optional
compilerArg=-aspectpath other.jar

Read the blog post for more details.

挥剑断情 2024-12-26 03:26:05

在 eclipse 3.5 中执行 ajdt-pde headless build 需要几个步骤:

1) 将 ajdt.pdebuild.scripts 参数及其各自的值作为“jvmarg”添加到上面显示的“java” “ 阻止。
2) 在 .../scripts/productBuild/productBuild.xml 中,将 property name="allElementsFile" value="productBuild/allElements.xml" 更改为此 属性名称 =“allElementsFile”值 =“${ajdt.pdebuild.scripts}/productBuild/allElements.xml”
3)在.../scripts/productBuild/productBuild.xml中,注释掉import file="${ajdt.pdebuild.scripts}/productBuild/allElements.xml"
4) 在 .../scripts/productBuild/productBuild.xml 中,粘贴以下导入语句: import file="${ajdt.pdebuild.scripts}/build.xml"

there are several steps needed to wrangle ajdt-pde headless build to execute in eclipse 3.5:

1) add ajdt.pdebuild.scripts param with its respective value as a "jvmarg" to the above-shown "java" block.
2) in .../scripts/productBuild/productBuild.xml, change property name="allElementsFile" value="productBuild/allElements.xml" to this property name="allElementsFile" value="${ajdt.pdebuild.scripts}/productBuild/allElements.xml"
3) in .../scripts/productBuild/productBuild.xml, comment out import file="${ajdt.pdebuild.scripts}/productBuild/allElements.xml"
4) in .../scripts/productBuild/productBuild.xml, paste the following import statement: import file="${ajdt.pdebuild.scripts}/build.xml"

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文