Eclipse RCP:如何从目标定义文件中的软件站点下载增量包?

发布于 2024-10-04 01:45:47 字数 387 浏览 2 评论 0原文

我正在使用这种技术为我的 Eclipse RCP 项目创建目标平台: http://www.modumind.com/2009/09/01/creating-an-eclipse-rcp-target-platform/

RCP SDK 是直接使用软件站点下载的。至于Delta Pack,我是从网站手动下载的,并将目录添加到目标定义文件中,在我看来,当我下次想升级Delta Pack版本时,这很繁琐。

是否也可以使用软件网站下载增量包?或者至少以更少的手动和更易于维护的方法来完成?

谢谢。

I'm using this technique to create a target platform for my Eclipse RCP projects: http://www.modumind.com/2009/09/01/creating-an-eclipse-rcp-target-platform/

The RCP SDK is downloaded directly using the software site. As for the delta pack, I manually downloaded it from website, and added the directory in the target definition file, which in my opinion is tedious when I want to upgrade the delta pack version next time.

Is it possible to download the delta pack using the software site too? Or at least do it in less manual and more maintainable approach?

Thanks.

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

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

发布评论

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

评论(3

温柔戏命师 2024-10-11 01:45:47

将主 Eclipse 更新站点添加到目标。注意版本。
然后从此站点选择 RCP 目标和 Equinox 目标功能。确保选中“包括所有环境”。

更新站点示例:http://download.eclipse.org/eclipse/updates/4.2


添加

这是这个问题的完整答案。

使用“DeltaPack”的首选方式

DeltaPack 用于获取特定于平台的工件,以便您可以为多个平台导出 RCP 产品。有关 DeltaPack 的更多信息,请参阅下一节

添加特定于平台的工件

获取特定于平台的工件的首选方法是将它们添加到目标平台。如果您遵循这些说明,则无需查找和下载“DeltaPack”。

  • 打开窗口/首选项。
  • 查找 PDE/目标平台
  • 选择您的(活动)目标平台
  • 单击编辑
  • 单击添加
  • 选择“软件站点”
  • 单击下一步
  • 在“使用”中输入: http://download.eclipse.org/eclipse/updates/4.3(将 4.3 替换为您当前的版本)
  • 选中“Eclipse RCP Target Components”
  • 选中“Equinox Target Components”
  • 取消选中“Ininclude”所需的软件
  • ” 选中“包括所有环境”
  • 按完成
  • 按完成
  • 按确定

打开您的产品文件并选择“导出”选项。您将看到“导出到多个平台”复选框可用。

使用“DeltaPack”的旧方法

什么是 DeltaPack

DeltaPack 是 Eclipse 的一个发行版,其中包含所有受支持平台和小部件集的平台特定文件。它包含:

  • SWT 平台层
    用于处理与本机操作系统小部件的连接的各种插件。

  • 各种启动器(exe、cmd 等)
    从命令行启动 Eclipse 的文件

  • 其他特定于平台的插件
    挂钩安全存储、本机网络和本机 Eclipse 文件系统挂钩

总共有大约 70 个插件来支持所有受支持的操作系统(大约十几个)。

什么时候需要它

如果您想将 RCP 应用程序导出到多个目标(OS/ARCH/WIDGETSET 的组合:例如 linux/ppc64/gtk ),则需要它。这通常是通过产品配置文件完成的。

如何获取它

您可以从以下位置获取它: http://download.eclipse.org/eclipse/downloads/

单击任意版本并查找 DeltaPack。请注意,有关于删除 DeltaPack 的讨论并使其成为首选方式。

如何将其添加到您的目标平台

  • 如上所述下载 DeltaPack
  • 将其解压缩到某个位置,例如“C:\eclipse-4.4M7-delta-pack”
  • 打开窗口/首选项。
  • 选择 PDE/目标平台
  • 选择您的(活动)目标平台
  • 单击编辑
  • 单击添加
  • 选择“目录”
  • 单击下一步
  • 在“位置”中输入:“C:\eclipse-4.4M7-delta-pack\eclipse”
  • 按下一步
  • 按完成
  • 按完成
  • 按确定

打开您的产品文件并选择“导出”选项。您将看到“导出到多个平台”复选框可用。

Add a main eclipse update site to the target. Take care of the version.
Then from this site choose the RCP target and Equinox target features. Make sure to check "Include all environments".

Example of update site: http://download.eclipse.org/eclipse/updates/4.2


Addition

Here is the full answer to this question.

Preferred way of using the "DeltaPack"

The DeltaPack is used to get platform specific artifacts so that you can export your RCP product for multiple platforms. See the next section for more information on the DeltaPack

Adding platform specific artifacts

The preferred way of getting the platform specific artifacts is to just add them to the target platform. There is no need to look-up and download the "DeltaPack" if you follow these instructions.

  • Open Window/Preferences.
  • Find PDE/Target Platform
  • Select your (active) target platform
  • Click Edit
  • Click Add
  • Select "Software Site"
  • Click Next
  • In "Work With" type: http://download.eclipse.org/eclipse/updates/4.3 (replace 4.3 with your current version)
  • Check "Eclipse RCP Target Components"
  • Check "Equinox Target Components"
  • Uncheck "Include required software"
  • Check "Include all environments"
  • Press Finish
  • Press Finish
  • Press OK

Open your product file and select the "Export" option. You will see that the "Export for multiple platforms" checkbox is available.

Old way of using the "DeltaPack"

What is the DeltaPack

The DeltaPack is a distribution from Eclipse that contains platform specific files for all supported platforms and widget sets. It contains:

  • SWT Platform Layers
    Various plugins to handle connection to the native OS widgets.

  • Various launchers (exe, cmd, etc..)
    Files to launch Eclipse from the command line

  • Other platform specific plugins
    Hooks into secure storage, native networking and native Eclipse filesystem hooks

In total there are some 70 plugins to support the complete range of supported operating systems (around a dozen).

When do you need it

You need it if you want to export your RCP application to multiple targets (a combination of OS/ARCH/WIDGETSET: e.g. linux/ppc64/gtk ). This is typically done from the product configuration file.

How to get it

You can get it from: http://download.eclipse.org/eclipse/downloads/

Click on any of the builds and look for DeltaPack. Please note that there are discussions on removing the DeltaPack and getting it the preferred way.

How to add it to your target platform

  • Download the DeltaPack as described above
  • Unzip it to a location .e.g. "C:\eclipse-4.4M7-delta-pack"
  • Open Window/Preferences.
  • Select PDE/Target Platform
  • Select your (active) target platform
  • Click Edit
  • Click Add
  • Select "Directory"
  • Click Next
  • In "Location" type: "C:\eclipse-4.4M7-delta-pack\eclipse"
  • Press Next
  • Press Finish
  • Press Finish
  • Press OK

Open your product file and select the "Export" option. You will see that the "Export for multiple platforms" checkbox is available.

随风而去 2024-10-11 01:45:47

在为您的目标设置软件站点期间,您可以选择“包括所有环境”(在取消选择“包括所需软件”之后),这样就无需维护增量包了。

During setting up a software site for your target, you can select 'Include all environments' (after unselecting 'Include required software'), which should make maintaining a delta pack unnecessary.

北音执念 2024-10-11 01:45:47

我共享 delta-pack 的解决方案:

  1. 下载官方 delta-pack
  2. 将其转换为更新站点(或您所说的软件站点)
  3. 将更新站点放置到我自己的服务器(例如 http://example.com/my-delta-pack)
  4. 将更新站点添加到我的目标定义

广告 2)
我使用名为 Publisher 的命令行工具。它是 Eclipse IDE 的一部分。

用法示例:

${eclipse.home}/eclipse.exe
   -application org.eclipse.equinox.p2.publisher.FeaturesAndBundlesPublisher
   -metadataRepository file:/${basedir}/${target.delta}
   -artifactRepository file:/${basedir}/${target.delta}" />
   -source ${source.delta}
   -publishArtifacts
   -compress

My solution for sharing delta-pack:

  1. Download the official delta-pack
  2. Convert it to update-site (or software-site as you call it)
  3. Place the update-site to my own server (e.g. http://example.com/my-delta-pack)
  4. Add the update-site to my target definition

ad 2)
I use a command-line tool called Publisher. It's a part of Eclipse IDE.

Example usage:

${eclipse.home}/eclipse.exe
   -application org.eclipse.equinox.p2.publisher.FeaturesAndBundlesPublisher
   -metadataRepository file:/${basedir}/${target.delta}
   -artifactRepository file:/${basedir}/${target.delta}" />
   -source ${source.delta}
   -publishArtifacts
   -compress
~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文