SETCAP
Version 9.0 and later
This is a tool that allows you to make a copy of an executable file and to assign a set of capabilities to it. It can also modify the Secure or Vendor IDs.
The purpose of the tool is to allow you to test the executable with
different capability combinations. It avoids the overhead of maintaining
multiple copies of the executable's .mmp
file for each capability
combination, and the need to rebuild each copy of the executable after a change
to the source code.
Note: this is not a native PC utility. It is a command line tool that runs under Symbian OS.
This is the command line syntax:
SETCAP source_exe capability [-SID secureId] [-VID vendorId] [destination_path]
The following arguments are used.
|
If the source executable is in ROM, then it must be a RAM executable image, not an execute-in-place (XIP) image. In other words, its entry in an OBY file must start with "data=" and not "file=".
For OBY files generated automatically using ABLD
ROMFILE
, this needs to be achieved by using lines similar to the
following in the executable's .mmp
file:
ROMTARGET // Empty ROM path means don't include normal execute-in-place file
RAMTARGET \sys\bin\ // Target path (in ROM) for RAM executable image
Symbian OS only allows one binary file with a given name; the
name does not include the file path or extension. This means that if
SETCAP
is used to make a copy of a binary which is already loaded,
then the copy will not be loaded when used with
RProcess::Create()
; instead the already loaded version is used. To
avoid this, use SETCAP
to give the copy a different name. For
example:
> SETCAP test.exe 1c000 test2.exe