Install an app repackaging tool

You can install any one of the tools shown below to repackage your app as a .bar file that you can submit for distribution through the BlackBerry World storefront.

Repackaging tool

Description

The BlackBerry Plug-in for Android Studio

The Android Studio plug-in allows you to:

  • Create a BlackBerry ID token and developer certificate.
  • Use the BlackBerry ADB Proxy Manager to run and debug your Android app on a BlackBerry device.
  • Verify that your Android app is compatible with the BlackBerry Runtime.
  • Repackage your Android app as a BlackBerry .bar file.
  • Use Android Studio to sign your Android app.

Get the BlackBerry Plug-in for Android Studio.

The BlackBerry Command-line tools

The command-line tools are a set of command-line utilities that can do everything that the above plug-ins do, but from a command-line prompt. You can also use the command-line tools from a point and click UI.

Get started with the BlackBerry Command-line tools.

Create a BlackBerry ID Signing token

A BlackBerry ID Signing token and Developer certificate are used to sign your repackaged BlackBerry 10 apps. An app must be signed before it can be distributed through the BlackBerry World storefront. You must have a BlackBerry ID account to create a BlackBerry ID Signing token and Developer certificate.

To register for a BlackBerry ID account and create a BlackBerry ID Signing token:

  1. Go to the BlackBerry ID portal and do one of the following:
    • Click the Don't have a BlackBerry ID? Create one link.
    • Enter your BlackBerry ID account credentials and click Sign In.
  2. Enter and confirm the password that you want to use to secure your BlackBerry ID Signing token. This password can also be used when you create your Developer certificate.

    Many developers use their BlackBerry ID account password for their BlackBerry ID Signing token and Developer certificate. This can make those passwords easier to remember. If you forget the password for your BlackBerry ID Signing token, it cannot be retrieved or reset for you. You must create another BlackBerry ID Signing token.

  3. Accept the license agreement and click Get Token.
  4. Download and save the BlackBerry ID keystore file.

    The BlackBerry ID Signing token is included in a keystore file, called bbidtoken.csk, that's saved in your Downloads folder.

The BlackBerry Signing Authority service uses your BlackBerry ID Signing token for authentication when you sign your app using the associated Developer certificate. Signing your app helps verify its integrity and authenticity to users and to the BlackBerry 10 OS.

The BlackBerry APK Packager and the BlackBerry Signing Configuration wizard

After you follow these instructions, an author.p12 file is created in the following folder:

  • Windows XP: %HOMEPATH%\Local Settings\Application Data\Research In Motion
  • Windows Vista, Windows 7, and Windows 8: %HOMEPATH%\AppData\Local\Research In Motion
  • Mac OS: ~/Library/Research In Motion
  • UNIX, Linux: ~/.rim

You should protect your author.p12 file and its password.

The BlackBerry APK Packager has a wizard, called the BlackBerry Signing Configuration, that you can use to create a BlackBerry ID Signing Token and a Developer certificate. To start the BlackBerry Signing Configuration wizard, shown to the right, click the Package button in the BlackBerry APK Packager dialog.

The BlackBerry Signing Configuration wizard.

When the BlackBerry APK Packager does not find a BlackBerry ID Signing Token on your computer, the Confirmation dialog box shown to the right is displayed. Click Yes to start the BlackBerry Signing Configuration wizard to create a new BlackBerry ID Signing token and Developer certificate.

The Confirmation dialog box to start the BlackBerry Signing Configuration wizard.

Your BlackBerry ID Signing token and Developer certificate are valid for one year. When they expire, you must create new ones.

Set up your test environment

You can use either a BlackBerry 10 device or a BlackBerry 10 Device Simulator to test your app. Either choice allows you to see how your app functions. The following sections discuss how to set up and configure each testing environment.

Configure your BlackBerry 10 device

Ensure that the BlackBerry 10 device that you're using to test your app has the latest version of the BlackBerry 10 OS installed.

For more information on updating your BlackBerry 10 device, see BlackBerry Software Updates.

After you've installed the latest BlackBerry 10 OS, you must enable Development Mode on your BlackBerry 10 device.

To enable Development Mode on your device:

  1. On the home screen, swipe down from the top of the screen and select Settings, or find the Settings app on your home screen.
  2. Navigate to Security and Privacy > Development Mode.
  3. Set the User Development Mode toggle button to On.
  4. If you're prompted, enter the password for your device, and click OK.

Open your Android project in your IDE, connect your BlackBerry 10 device to your computer with a USB cable, and you're ready to begin developing and repackaging your Android app for the BlackBerry Runtime.

Install and configure a BlackBerry 10 Device Simulator

When you don't have a BlackBerry 10 device to test your apps, you can use the BlackBerry 10 Device Simulator. The BlackBerry 10 Device Simulator is hosted inside of a virtual machine, which supports accelerated graphics, audio, and peripheral simulation. The BlackBerry 10 Device Simulator lets you test your BlackBerry 10 app and simulate the touch interface using your mouse.

Download the BlackBerry 10 Device Simulator.

For more information on how to install and configure the simulator, see BlackBerry 10 Device Simulator.

When your BlackBerry 10 Device Simulator has been installed and configured, open your Android project in your IDE, start the BlackBerry 10 Device Simulator, and you're ready to begin developing and repackaging your Android app for the BlackBerry Runtime.



Got questions about leaving a comment? Get answers from our Disqus FAQ.

comments powered by Disqus