Creating an application for Built for BlackBerry using the BlackBerry WebWorks Apache Ant build script

by Retired on ‎11-16-2012 03:44 PM - edited on ‎11-16-2012 03:47 PM by Retired (3,742 Views)

The Built for BlackBerry® apps program requires developers building HTML5 BlackBerry® WebWorks™ apps to submit both a signed production version to the BlackBerry App World™ storefront, and a signed version with Web Inspector™ turned on so that our testing team can test the performance and quality.


It's recommended that you build these versions at the same time so they are essentially identical - the only difference being that one build has Web Inspector turned on.


One way to make this very easy is to use the BlackBerry WebWorks Apache Ant build script. Once you've got this script set up and you've added the build.xml file to your project directory, you can build both versions of your application at once by creating both a "prod" and "beta" version. By default, the "prod" version will appear in the <project folder>/bin/<platform> directory. This version will be the signed version with no Web Inspector, so you can submit it to BlackBerry App World. The "beta" version will be signed with Web Inspector enabled, so you can send it to the Built for BlackBerry testing team. By default, the "beta" version appears in the <project folder>/bin/<platform>-beta.


For example, to build both "prod" and "beta" builds for BlackBerry 10, set the build target to: 



<target name="build" depends="build.native.beta,"></target>


Then inside the project's bin folder, you will have two directories: bb10, and bb10-beta. Submit the app in the bb10 folder to BlackBerry App World, and the one in bb10-beta to the testing team.