The Journey  
The Game

The Paper - Page 7 - Simplifying Common Tasks

The Workflow of C++ Game-Development on a Series 60 Platform device

Andreas Jakl, Revision 1.0, July 2004

3.2.3 Simplifying common tasks

Unfortunately Microsoft Visual Studio 6 does not have native support for Symbian OS development. While the SDK teaches the IDE how to do many of the tasks in the right way, not everything can be done from within the IDE, but rather from a command window. Examples are building the project for the device or building and distributing bitmap compilation files (see chapter 4.5). As having to type in the respective calls every time is a tedious task, it saves a lot of time to create batch files and integrate them into the VC6 IDE.


During development with Symbian OS, you might experience problems that can be solved by cleaning and rebuilding the whole project. This procedure is also beneficial when you develop on more than one PC and want to transfer the latest version, to make sure that everything is rebuilt using your new sources.

To automate this task, create a file called DoEverything.bat in the folder Q:\dev\Journey\group . It should have the following contents:

call abld.bat reallyclean all
cd ..\data
call dobitmaps.bat
cd ..\group
call bldmake bldfiles
call abld.bat makefile vc6
call abld.bat build wins udeb

The first line removes nearly all files that have been built. The next three lines distribute the bitmap compilation files, as explained later in chapter 4.5. The following line creates a file called abld.bat , which serves as an entry point for the creation of workspaces and the compilation. The following call to the just created abld.bat creates the workspace for Visual C++ 6. Finally, the project is built for the emulator, including debug information.


Building for the device and creating the installation package has to be done manually. The batch file below, which should be created in the same directory as DoEverything.bat , handles this task:

call bldmake bldfiles
call abld.bat build armi urel
makesis journey.pkg

First the batch file builds the project for the mobile phone as a release version (without debug information), then it changes to the install folder and calls the tool to create the .sis file, which can be transferred to your device to be installed.

IDE integration

As both tasks described in the previous two chapters are quite common, it is convenient to be able to call them directly from the Microsoft Visual Studio IDE . Go to Tools ® Customize... ® Tools to get to the dialog shown in Fig. 3.2. There you can define a shortcut to the BuildForArmi.bat file. As command, enter Q:\dev\Journey\group\BuildForArmi.bat and as the working directory Q:\dev\Journey\group\ . Activate the option Use Output Window to have the text output any possible error directly in the IDE.

Next, go to the Keyboard tab in the same window (See Fig. 3.3). For the category, choose Tools. Select the command UserTool1 and assign a shortcut like Ctrl+Alt+1.

Once this is done, to compile for the device, you just have to press the shortcut, wait until the .sis file is created and then copy it to the device.

Figure 3.2: Defining a custom tool in the Microsoft Visual Studio IDE .

Figure 3.3: Adding a keyboard shortcut for the new custom tool in the Microsoft Visual Studio IDE .

Leave Scan

It is convention in Symbian OS that all functions that might encounter a problem should have an L at the end of their name to indicate the possibility that they might leave. Symbian has released a little-known utility, called LeaveScan , that can check if your code follows this convention. It can automatically check if all function names in a source file are correct. The tool as well as installation and usage instructions can be found in the Symbian OS FAQ database [16]. It can also be integrated into the IDE.

< Importing the Project Contents Useful Tips >
© 2004 Andreas Jakl. All Rights Reserved.
Privacy Statement | Contact and Imprint
The Journey