Please note that as of October 24, 2014, the Nokia Developer Wiki will no longer be accepting user contributions, including new entries, edits and comments, as we begin transitioning to our new home, in the Windows Phone Development Wiki. We plan to move over the majority of the existing entries. Thanks for all your past and future contributions.

Checking Symbian platform version during installation or at run time

From Wiki
Jump to: navigation, search

Article Metadata
Platform(s): S60 1st Edition
S60 2nd Edition, all S60 2nd Edition FPs
S60 3rd Edition, S60 3rd Edition FP1
S60 3rd Edition FP1
S60 3rd Edition (initial release)
S60 2nd Edition (initial release)
S60 1st Edition
Created: User:Technical writer 2 (22 Nov 2006)
Last edited: hamishwillee (14 Jun 2012)


Checking S60 platform version during installation or at run time


All S60 application SIS packages contain a mandatory dependency to 'Series60ProductID' component. This dependency defines the minimum S60 platform version required in order to run the application, and prevents installation on older platforms. See the document "S60 Platform: Identification Codes" available at for more information about the use of Series60ProductID.
The Series60ProductID can be checked only during installation, and only for aborting the installation or warning about possible incompatibility. However, in some cases it would be useful to have a single SIS package that would select the installed files based on the S60 platform version. The following solution describes how to do this in a .pkg file. Similarly, a code snippet for checking the platform version at run time is provided.


Platform version in pkg condition blocks
Even though there is no dedicated attribute for the S60 platform version that could be used with IF condition blocks, it is still possible to resolve the version, based on the existence of specific files on the ROM drive.
Each Series60ProductID component is stored in a separate .sis file in z:\system\install\ directory. These files are named as follows:
z:\system\install\Series60v3.0.sis     | S60 3rd Edition
z:\system\install\Series60v2.8.sis     | S60 2nd Edition, Feature Pack 3
z:\system\install\Series60v2.6.sis     | S60 2nd Edition, Feature Pack 2
z:\system\install\Series60v2.1.sis     | S60 2nd Edition, Feature Pack 1
z:\system\install\Series60v2.0.sis     | S60 2nd Edition
z:\system\install\Series60v1.2.sis     | S60 1st Edition (1.2)
z:\system\install\Series60v1.1.sis     | (n/a)
z:\system\install\Series60v1.0.sis     | (n/a)
z:\system\install\Series60v0.9.sis     | S60 v0.9
In each device, there is a corresponding file for the platform version it represents, and also files for all previous versions that are supported. For example, the Nokia N70 (2nd Edition, FP3) contains all above files except Series60v3.0.sis, and the Nokia E70 (3rd Edition) only has Series60v3.0.sis.
These filenames can be utilized in pkg files:
; Lowest supported S60 platform version is 2nd Edition
(0x101F7960), 0, 0, 0, {" Series60ProductID"}
; install common files for all supported platforms
; ...
IF EXISTS("z:\system\install\Series60v2.8.sis")
; install 2nd Ed, FP3-specific files
ELSEIF EXISTS("z:\system\install\Series60v2.6.sis")
; install 2nd Ed, FP2-specific files
ELSEIF EXISTS("z:\system\install\Series60v2.1.sis")
; install 2nd Ed, FP1-specific files
; 2nd Edition-specific files

Checking the platform version at run time
The following function can be used to recover the S60 platform version at run time. On return, aMajor and aMinor contain the highest version number found from above file names. Note that while aMajor refers to the S60 Edition, aMinor cannot always be directly interpreted as a Feature Pack number (for example, 2.6 == 2nd Edition, FP2).
#include <f32file.h>    // link against efsrv.lib
_LIT(KS60ProductIDFile, "Series60v*.sis");
_LIT(KROMInstallDir, "z:\\system\\install\\");
void GetS60PlatformVersionL( RFs& aFs, TUint& aMajor, TUint& aMinor )
    TFindFile ff( aFs );
    CDir* result;
    User::LeaveIfError( ff.FindWildByDir( KS60ProductIDFile, KROMInstallDir, result ) );
    CleanupStack::PushL( result );
    User::LeaveIfError( result->Sort( ESortByName|EDescending ) );
    aMajor = (*result)[0].iName[9] - '0';
    aMinor = (*result)[0].iName[11] - '0';
    CleanupStack::PopAndDestroy(); // result


This page was last modified on 14 June 2012, at 07:10.
42 page views in the last 30 days.