Adobe AIR - .air文件转换为.exe/.dmg/.rpm

4
我需要从一个.air文件中获取Mac和Linux的本地安装程序。我使用的是Windows和AIR 2.5。
我发现了这个有趣的Windows应用程序,可以将.air文件转换为.exe/.dmg/.rpm,链接在此(http://chargedweb.com/labs/2010/02/20/airpackager-easy-air-to-exedmgrpm/)。但我无法使其工作,是否有其他人使用过它并能够证明其功能或者推荐类似的应用程序?
谢谢。 Uli
4个回答

2

您应该使用adt命令。

adt -package -target native myApp.dmg myApp.air for MAC

并且。
adt -package -target native myApp.exe myApp.air fr Windows

2

2
Air文档中得知:"您必须在与您要生成本机安装程序文件的操作系统相同的操作系统上使用ADT。"
我在Mac上开发并通过bootcamp运行Windows,在这个设置下,我已经能够为两种操作系统创建本机安装程序。此外,值得注意的是,自v2.6起,Adobe已停止对Linux的支持,因此这可能会影响您愿意付出多少努力来构建.rpm文件。

-2
不妨看一下关于NativeProcess功能的文章,它描述了创建本地安装程序的过程。以下是一些相关部分的引用:
To package the application, invoke the ADT application using syntax to package a native installer application version.

You must run ADT on the same operating system as the target installer application. To generate a DMG file, run ADT on Mac OS. To generate an EXE installer file, run ADT on Windows.

For example, the following command packages a DMG file on Mac OS:
adt -package -storetype pkcs12 -keystore myCert.p12 -target native NativeProcessTest.dmg NativeProcessTest-app.xml NativeProcessTest.swf NativeApps/Mac/bin/echoTestMac icons

Before running this command, open the Terminal application and navigate to the output directory for your Flex project. Adjust the following:

    The path to the ADT application in the Flex SDK
    The name and path of the signing certificate (given as myCert.p12 in this example)

For example, the following command packages an EXE installer file on Windows:
adt -package -storetype pkcs12 -keystore myCert.p12 -target native NativeProcessTest.exe NativeProcessTest-app.xml NativeProcessTest.swf NativeApps/Windows/bin/echoTestWindows icons

Before running this command, open a command line session and navigate to the output directory for your Flex project. Adjust the following:

    The path to the ADT application in the Flex SDK
    The name and path of the signing certificate (given as myCert.p12 in this example)

For more information on using ADT and on using signing certificates, refer to "Packaging an AIR application in a native installer" in Building Adobe AIR applications.

捆绑式运行时会做类似的事情,但需要AIR 3或更高版本。


2
NativeProcess 类用于启动本地进程(该文章讨论了在安装程序中打包本机的 mac/win 可执行文件并从 AIR 应用程序调用它的方法),这是 ANE 接口问世之前进行此类操作的一种暴力方式。Captive runtime 支持仅在 AIR 3 上可用,不支持 Linux,您需要在 Mac 上打包应用程序以构建本机 Mac 应用程序(Windows 同理)。 - J. Holmes
作为NativeProcess功能的一部分,您可以创建本地安装程序。关于Linux,您是正确的;我错过了问题的那一部分。 - JeffryHouser
2
NativeProcess功能与创建打包运行时应用程序或独立可执行安装程序的过程无关。我认为你把这个混淆了,因为NativeProcess函数明确依赖于将AIR应用程序打包为本地安装程序/可执行文件。 - user562566
@Ascension Systems,你说得对;我的帖子中没有明确区分。 - JeffryHouser

网页内容由stack overflow 提供, 点击上面的
可以查看英文原文,
原文链接