Support for multiple mobile targets
When developing mobile applications for multiple platforms
and devices, Flash Builder lets you specify different build configurations
for each launch target.
For mobile projects, you can create a custom build target with
specific package contents such as native extensions, certificate
configurations, and different platform SDKs.
For more information on specifying project properties for a build
target, see Project properties for packaged mobile projects.
Create a custom build target
the Package Explorer, select the project.
Select Project > Properties from the main menu
or select Properties from the context menu.
In the Project Properties dialog box, select Flex Build Packaging,
and select the target platform for which you want to view or change
To create a custom target, click Create Custom, and specify
details for the new target. Then, click Create. The target that
you create appears in the list of available targets.
Specify the digital certificate that you want to use to sign
the mobile application, package contents, native extensions, and
permissions and entitlements (if applicable).
Select a custom target build in the launch configuration
you specify a launch configuration to run or debug an application,
Flash Builder picks up the applicable build target settings by default.
For example, say that you created a build target "d1" to run the
application on an iOS device. When you create a launch configuration
to debug the application on a simulator, the target build is selected
as "d1" by default. You can, however, change the default selection
and select a different build target.
Export the application to a custom target
can export a mobile application to supported custom targets besides
the standard supported platforms.
Important: You can
use the Export Release Build feature to launch a custom target only
on a device.
When you select Project > Export Release
Build, all the device-based targets configured for that project
If there is more than one build target for a "device",
the target names are displayed in platformname-targetname format.
For example, if you have two build targets configured to launch
the application on an iOS device, the target names are displayed
as AppleiOS-targetname1 and AppleiOS-targetname2.The
created application package name has the matching target name specified.
Example of packaging and exporting an application to multiple build targets
You are developing an application
for the Apple iOS platform and you have multiple ActionScript Native
Extension (ANE) files as follows:
native extension "n1" uses iOS4 SDK features and the native extension
"n2" uses iOS5 SDK features.
While packaging your mobile application,
you want to create different application packages for the device
and simulator selecting different ANEs in each package, as follows:
To do so, follow
In the Project Properties page, select Flex
Build Packaging > Apple iOS.
Click Create Custom to specify the first build configuration.
Specify the Build Target Name as "d1", select the Build Target
Base as "device", and click Create.
Again, click Create Custom to specify the second build configuration.
Specify the Build Target Name as "s1", select the Build Target
Base as "simulator", and click Create.
The custom targets that you created appear in the list of
To select the required native extensions while exporting
the application, follow these steps:
target as d1 [device], and the native extension "n1" from the Native
Extensions section. Click Apply.
Select the target as s1 [simulator], and the native extension
"n2" from the Native Extensions section. Click Apply.
You can export the application
to multiple build targets by following these steps:
Select Project > Export Release Build.
In the Export Release Build dialog box, the custom targets
that you created appear as "Apple iOS-d1" and "Apple iOS-s1". You
can select multiple targets to export your application to.
For each selected target platform, you can specify the native
extension to use, the digital certificate to sign the application,
and package contents.
Before exporting the application, you can add or edit the
launch parameter values like -target, -keystore, and such. Click
Customize Launch to customize the launch parameter values.