Tuesday, May 22, 2007

Six hurdles a symbian developer need to cross

To build a symbian c++ program we use bldmake bldfiles [Commnad Line] and we get a abld.bat batch file. To actually build the application we run this batch file

abld build

What happens when we run this file is something worth investigating. On close examining this file [\\epocroot\S60_2nd_FP3\Epoc32\tools\abld.pl] reveals some interesting insight of the build command.

BUILD=>{
build=>1,
program=>1,
what=>1,
function=>'Combines commands
EXPORT,MAKEFILE,LIBRARY,RESOURCE,TARGET,FINAL',
subcommands=>['EXPORT','MAKEFILE', 'LIBRARY', 'RESOURCE', 'TARGET', 'FINAL'],

Build in fact has six phases:

  • EXPORT
  • MAKEFILE
  • LIBRARY
  • RESOURCE
  • TARGET
  • FINAL
The EXPORT phase copies exported files to their destinations viz. public header files into the \epoc32\includedirectory. For many applications this stage will need to do nothing.

The MAKEFILE phase creates the necessary makefiles or different IDE’s

The LIBRARY phase creates import libraries.

The RESOURCE phase creates the application's resources files i.e. from the application .rss file it generates .rsg [resource for headers] and .rsc files [compiled resource files] , bitmaps and application information files (aifs).

The TARGET phase, this is the most important part of the process. It creates the application's main executables. For this previous task must be executed in advance

The FINAL phase is present to perform any final actions that need to be done after the
main executables have been created. For most applications, this phase will do nothing.

No comments: