Symbian3/PDK/Source/GUID-1CBDCDE6-1FC6-59BE-BA4A-9EAD3D6627CD.dita
changeset 12 80ef3a206772
parent 11 5072524fcc79
child 13 48780e181b38
--- a/Symbian3/PDK/Source/GUID-1CBDCDE6-1FC6-59BE-BA4A-9EAD3D6627CD.dita	Fri Jul 02 12:51:36 2010 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,14 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
-<!-- This component and the accompanying materials are made available under the terms of the License 
-"Eclipse Public License v1.0" which accompanies this distribution, 
-and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
-<!-- Initial Contributors:
-    Nokia Corporation - initial contribution.
-Contributors: 
--->
-<!DOCTYPE concept
-  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
-<concept xml:lang="en" id="GUID-1CBDCDE6-1FC6-59BE-BA4A-9EAD3D6627CD"><title>Set capability test tool SETCAP</title><prolog><metadata><keywords/></metadata></prolog><conbody><p> <b>Version 9.0 and later</b> </p> <p>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. </p> <p>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 <filepath>.mmp</filepath> file for each capability combination, and the need to rebuild each copy of the executable after a change to the source code. </p> <p>Note: this is <i>not</i> a native PC utility. It is a command line tool that runs under Symbian platform. </p> <ul><li id="GUID-EAF39BDB-18DD-5231-BA30-7EA067ADF1FE"><p><xref href="GUID-1CBDCDE6-1FC6-59BE-BA4A-9EAD3D6627CD.dita#GUID-1CBDCDE6-1FC6-59BE-BA4A-9EAD3D6627CD/GUID-EF358C01-0430-52BF-BCE8-52D7AF3675A8">Command line syntax</xref> </p> </li> <li id="GUID-C918BF45-4EF4-5192-93A5-091C2CA8D4E5"><p><xref href="GUID-1CBDCDE6-1FC6-59BE-BA4A-9EAD3D6627CD.dita#GUID-1CBDCDE6-1FC6-59BE-BA4A-9EAD3D6627CD/GUID-D2B78A44-90D0-565C-920A-BD37C9EBC98D">Arguments</xref> </p> </li> <li id="GUID-85D4C38E-A692-55B8-A4C7-DA6635E982A6"><p><xref href="GUID-1CBDCDE6-1FC6-59BE-BA4A-9EAD3D6627CD.dita#GUID-1CBDCDE6-1FC6-59BE-BA4A-9EAD3D6627CD/GUID-ADFB53E8-7192-5EC1-9274-7990B6C1CDC4">Notes</xref> </p> </li> </ul> <section id="GUID-EF358C01-0430-52BF-BCE8-52D7AF3675A8"><title>Command line syntax</title> <p>This is the command line syntax: </p> <codeblock id="GUID-98C76729-784F-595F-AAFE-9797D393972C" xml:space="preserve">SETCAP source_exe capability [-SID secureId] [-VID vendorId] [destination_path]</codeblock> </section> <section id="GUID-D2B78A44-90D0-565C-920A-BD37C9EBC98D"><title>Arguments</title> <p>The following arguments are used. </p> <table id="GUID-E4AB5674-48C8-59B3-BB94-4CFB69D70BBE"><tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/><tbody><row><entry><p> <codeph>source_exe</codeph> </p> </entry> <entry><p>The name and the path of an executable file to be copied. If the path is not specified, a default path of <codeph>Z:\SYS\BIN\</codeph> is assumed. </p> </entry> </row> <row><entry><p> <codeph> capability </codeph> </p> </entry> <entry><p>The hexadecimal representation of the set of capabilities. </p> <p>This should be a simple string of hexadecimal characters (i.e. not preceded by <codeph>0x</codeph> characters, and not enclosed by quotation marks etc). </p> <p>For example, the three capabilities: LocalServices, ReadUserData and WriteUserData would be represented by the value of: </p> <codeblock id="GUID-2C3302A4-2DAC-56F4-A38E-974363C5C06E" xml:space="preserve">((1&lt;&lt;ECapabilityLocalServices) | (1&lt;&lt;ECapabilityReadUserData) | (1&lt;&lt;ECapabilityWriteUserData))</codeblock> <p>which in hexadecimal is <codeph>1c000</codeph>. </p> <p>If the value supplied includes capabilities that are not supported by the current version of Symbian platform, then these capabilities are ignored; they are not added to the file. </p> </entry> </row> <row><entry><p> <codeph>-SID secureId </codeph> </p> </entry> <entry><p>The hexadecimal value of the secure ID that is to be assigned. </p> <p>This should be a simple string of hexadecimal characters (i.e. not preceded by <codeph>0x</codeph> characters, and not enclosed by quotation marks etc). </p> <p> <i>This is optional.</i> </p> </entry> </row> <row><entry><p> <codeph>-VID vendorId</codeph> </p> </entry> <entry><p>The hexadecimal value of the vendor ID to be assigned. </p> <p>This should be a simple string of hexadecimal characters (i.e. not preceded by <codeph>0x</codeph> characters, and not enclosed by quotation marks etc). </p> <p> <i>This is optional.</i> </p> </entry> </row> <row><entry><p> <codeph>destination_path</codeph> </p> </entry> <entry><p>The name and path of the target executable to which the executable is copied. </p> <p> <i>This is optional</i>, and if not specified, defaults to <filepath>C:\SYS\BIN\source_executable_name</filepath>. </p> </entry> </row> </tbody> </tgroup> </table> </section> <section id="GUID-ADFB53E8-7192-5EC1-9274-7990B6C1CDC4"><title>Notes</title> <ul><li id="GUID-50EBD681-7E66-5BDA-9204-BA1872427A22"><p>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=". </p> <p>For OBY files generated automatically using <codeph>ABLD
-                ROMFILE</codeph>, this needs to be achieved by using lines similar to the following in the executable's <filepath>.mmp</filepath> file: </p> <codeblock id="GUID-4D14C0CC-A244-5D51-BD25-D49B89D941CC" xml:space="preserve">ROMTARGET    // Empty ROM path means don't include normal execute-in-place file
-RAMTARGET \sys\bin\    // Target path (in ROM) for RAM executable image</codeblock> </li> <li id="GUID-A9AE6B18-BDB5-5398-B8FC-52F79E798169"><p>Symbian platform only allows one binary file with a given name; the name does not include the file path or extension. This means that if <codeph>SETCAP</codeph> is used to make a copy of a binary which is already loaded, then the copy will not be loaded when used with <codeph>RProcess::Create()</codeph>; instead the already loaded version is used. To avoid this, use <codeph>SETCAP</codeph> to give the copy a different name. For example: </p> <p><userinput>SETCAP test.exe 1c000 test2.exe</userinput> </p> </li> </ul> </section> </conbody></concept>
\ No newline at end of file