Basic familiarity of ActionScript and building of apps with flash content
Adobe Flash Builder
With the release of AIR 29, a combined AIR SDK for packaging 32-bit and 64-bit captive applications is available for Windows platform. The combined SDK provides developers with the ability to create 32-bit or 64-bit captive AIR applications using the same AIRSDK. However, this new functionality only impacts captive applications. Native and shared applications will continue to only be supported as 32-bit applications on Windows.
Deciding the architecture of AIR applications
The workflow for building 32-bit vs. 64-bit using the combined AIRSDK is different for Adobe Flash Builder and Adobe Animate/adt.
- Packaging using Adobe Animate and adt:
With Adobe Animate and adt the desired application architecture is selected by adding the <architecture> tag to the application descriptor file. The value of this tag can be either “32” for packaging 32-bit captive AIR applications or “64” for packaging 64-bit captive AIR applications.
The <architecture> tag should be added under the <application> tag. If the <architecture> tag is omitted from the descriptor file the application will default to 32-bit. Here is a sample app-xml:
<?xml version="1.0" encoding="utf-8" standalone="no"?>
- Packaging using Adobe Flash Builder:
With Adobe Flash Builder the desired application architecture is set by adding the Windows environment variable AIR_WIN_ARCH before launching the Adobe Flash Builder. To build a 64-bit application set the variable to 64. To build a 32-bit application set the variable to 32. If the AIR_WIN_ARCH environment variable is not set the application will default to 32-bit. Setting the tag will have no impact on applications packaged by Adobe Flash Builder.
Packaging of shared and native AIR application will not beaffected by the any of the above-mentioned methods. They will continue to be supported as 32-bit applications on Windows.
Support for 64-bit native extensions
To create a 64-bit captive AIR application with native extension, a 64-bit ANE needs to be created.
To support creation of 64-bit native extensions you need to add the following files to the native framework in the Microsoft Visual Studio:
FlashRuntimeExtensions.lib, inside the AIRSDK_Compiler >lib >win64 folder.
FlashRuntimeExtensions.h, inside the AIRSDK_Compiler >includes folder.
- Packaging the native Extension.
To package the 64-bit native extension, the platform value to be passed inside the extension descriptor file and in the command used to create the ANE should be ‘Windows-x86-64’. The structure for extensions descriptor will be as follows:
And the packaging command would be:
adt -package -target ane path/where/you/want/YourANE.ane YourExtensionDescriptor.xml -swc YourAIRLibrary.swc -platform Windows-x86-64 library.swf YourNativeWindowsFramework
Linking ANE using Flash Builder 4.7
Upon linking the AIR application with the 64-bit ANE, a false error will be reported by Flash Builder 4.7. The error will appear as a red ‘X’ next to the ANE file entry in the Build Paths dialog box (see
figure below). The error reads “This ANE does not support air-native-win32 platform”. Please ignore this error as it is due to a bug in Flash Builder 4.7. You can verify that the ANE supports the desired Windows-x86-64 platform by clicking the triangle next to Targets.
The red ‘X’ issue is observed again when ANE is packaged by including the ANE in ActionScript Build Packaging. Ignore the error and click OK.
On exporting the native application using the Project->Export Release Build, Flash Builder displays a packaging error. To continue with app creation, check select ‘Ignore Errors’ in Native Extensions tab and click Finish. Your application will be created successfully.