Building for a Target Series 60 Device

Building for a Series 60 device with the Visual C++ IDE must be performed at the command prompt using the abld command, as described next . However, CodeWarrior and C++Builder allow building for a target device from within the IDE.

Building for a Series 60 device based on an ARM processor on a PC requires the use of a suitable PC-hosted cross compiler (for example, the GNU gcc C++ Compiler, as supplied with the Series 60 SDK) to build the executables in a suitable ARM binary format.

When building the project for a Series 60 device you would typically use a release build, since that is what you would do to create a final, deliverable application.

To build for target hardware, open a command prompt window and navigate to the group directory for the GUI HelloWorld project, then enter the following commands:

bldmake bldfiles

 

abld build armi urel

”For Visual C++ and CodeWarrior


or

abld build armib urel

”For Borland C++


This will cause abld to invoke the build (cross-compilation and linking) system to produce an armi (ARM Interworking) release ( urel ”Unicode release) build of the application for execution on a target device using the gcc tool chain.

There are currently three build variants for ARM based devices ” ARMI, ARM4 and Thumb . ARMI executables will work with the other two build variants. Typically you should build the ARMI binary executable variant for compatibility with the maximum number of real devices. ARM4 builds give maximum performance at the expense of increased code size . Thumb builds will reduce the code size at the expense of a slight reduction in execution speed.

The build steps actually include C++ compilation, linking, resource compilation, and production of the application information ( .aif ) file ”the file that contains the application icon and other specific details.

When building for a target device a Symbian OS-specific tool called petran is automatically invoked behind the scenes. Petran translates HelloWorld.app into a form suitable for loading at runtime by the Symbian OS executable loader.

If you are using the CodeWarrior IDE to build for a Series 60 device, use ProjectSet Default Target either to select the required target (for example, ARMI UREL ) or to choose Build All , and then build with ProjectMake .

With C++Builder X, you need to select the ProjectProperties menu item and then select the Symbian settings tab. From this dialog you can change the Platform and Build options to ARMI and UREL , respectively. Note: At the time of writing ARMI was the only target Platform option available.

Pressing Ctrl+F9 will make the project, creating the installation package ( .sis ) as part of the project; installation packages are described in the next section.

The executable and data files ( HelloWorld.app , HelloWorld.rsc and HelloWorld.aif ) will now be located in a folder such as \Epoc32\Release\Armi\Urel .

For testing on a Series 60 device, all of these files have to be transferred to a device and located in a folder called \System\Apps\HelloWorld\ .

File transfer to a device can be performed by copying to a memory card, or via a USB cable, if the Series 60 device manufacturer has included appropriate support in their product. Typically though, the file transfer is performed by packaging all the application files into a special installation file. The next section describes how this is achieved.



Developing Series 60 Applications. A Guide for Symbian OS C++ Developers
Developing Series 60 Applications: A Guide for Symbian OS C++ Developers: A Guide for Symbian OS C++ Developers
ISBN: 0321227220
EAN: 2147483647
Year: 2003
Pages: 139

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net