Symbian3/SDK/Source/GUID-0C02D927-0B06-49BD-8738-149DCDDB23FC.dita
author Graeme Price <GRAEME.PRICE@NOKIA.COM>
Fri, 15 Oct 2010 14:32:18 +0100
changeset 15 307f4279f433
parent 0 89d6a7a84779
permissions -rw-r--r--
Initial contribution of the Adaptation Documentation.

<?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 id="GUID-0C02D927-0B06-49BD-8738-149DCDDB23FC" xml:lang="en"><title>Preparation
of the MMP and <filepath>bld.inf</filepath> Files</title><shortdesc>At the end of this phase, Symbian port should have the <filepath>bld.inf</filepath> and
MMP files.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
<section id="GUID-8FAD2820-D96D-4AA8-8653-B5A947713788">       <title>MMP
file</title>       <p>An <filepath>.mmp</filepath> project definition file
specifies the properties of a project in a platform and compiler-independent
way. The MMP file is very similar to ‘Makefile’ of Linux. MMP file exists
per <filepath>.SO</filepath>, <filepath>.A</filepath>, or <filepath>.EXE</filepath>.</p><p>The
contents of a sample MMP file created for <codeph>libjpeg</codeph> are shown
below: </p><codeblock xml:space="preserve">TARGET	libjpeg.dll
TARGETTYPE	DLL
UID             	0x1000008d 0x0xE0000100 
CAPABILITY All -Tcb
EpocAllowDllData

USERINCLUDE	.

SYSTEMINCLUDE	\epoc32\include\stdapis
SYSTEMINCLUDE	\epoc32\include

SOURCEPATH	.
// LIBSOURCES
SOURCE	jcapimin.c jcapistd.c jccoefct.c jccolor.c jcdctmgr.c jchuff.c
SOURCE	jcinit.c jcmainct.c jcmarker.c jcmaster.c jcomapi.c jcparam.c
SOURCE	jcphuff.c jcprepct.c jcsample.c jctrans.c jdapimin.c jdapistd.c
SOURCE	jdatadst.c jdatasrc.c jdcoefct.c jdcolor.c jddctmgr.c jdhuff.c
SOURCE	jdinput.c jdmainct.c jdmarker.c jdmaster.c jdmerge.c jdphuff.c
SOURCE	jdpostct.c jdsample.c jdtrans.c jerror.c jfdctflt.c jfdctfst.c
SOURCE	jfdctint.c jidctflt.c jidctfst.c jidctint.c jidctred.c jquant1.c
SOURCE	jquant2.c jutils.c jmemmgr.c
// SYSDEPSOURCES
SOURCE	jmemansi.c
LIBRARY	euser.lib

LIBRARY	libc.lib
MACRO	HAVE_CONFIG_H
MACRO 	__SYMBIAN32__ </codeblock><p>The following table gives a brief introduction
to the MMP file keywords found in above file.</p><table id="GUID-367FB69E-EE9B-4100-8E44-6B102430297A">
<tgroup cols="2"><colspec colname="col1"/><colspec colname="col2"/>
<tbody>
<row>
<entry><p><b>Keyword</b></p></entry>
<entry><p><b>Description</b></p></entry>
</row>
<row>
<entry><codeph>TARGETTYPE</codeph></entry>
<entry><p>Target type.Can be DLL, EXE, or LIB. Other types are also supported.</p></entry>
</row>
<row>
<entry><codeph>TARGET</codeph></entry>
<entry><p>Name of the target.</p></entry>
</row>
<row>
<entry><codeph>UID</codeph></entry>
<entry><p>Unique identifier of the target. It is recommended to use test UIDs
from the range <codeph>0xE0000000-0xEFFFFFFF</codeph> which is targeted for
development use only. For production quality code, UIDs must be requested
from Symbian (<xref href="https://www.symbiansigned.com/app/page" scope="external">https://www.symbiansigned.com/app/page</xref>)
before the application can be sent for signing. </p></entry>
</row>
<row>
<entry><codeph>CAPABILITY</codeph></entry>
<entry><p>Capability requirement of the target. </p><note>Even if the example
uses All-TCB capabilities, it is strongly recommended to use a more narrow
set of capabilities to have the application successfully signed.</note></entry>
</row>
<row>
<entry><codeph>EpocAllowDllData</codeph></entry>
<entry><p>Allow global static data in the target</p></entry>
</row>
<row>
<entry><codeph>USERINCLUDE</codeph></entry>
<entry><p>Local file include path. The compiler will look in this path for
the files included with “ ”. For example, <codeph>#include "config.h"</codeph></p></entry>
</row>
<row>
<entry><codeph>SYSTEMINCLUDE</codeph></entry>
<entry><p>System file include path. The compiler will look in this path for
the files included with<codeph> &lt; &gt;</codeph>. For example, <codeph>#include
&lt;stdio.h&gt;</codeph></p></entry>
</row>
<row>
<entry><codeph>SOURCEPATH</codeph></entry>
<entry><p>Source path for the source files.</p></entry>
</row>
<row>
<entry><codeph>SOURCE</codeph></entry>
<entry><p>Source file listing.</p></entry>
</row>
<row>
<entry><codeph>LIBRARY</codeph></entry>
<entry><p>Dependent DLL library file list.</p></entry>
</row>
<row>
<entry><codeph>STATICLIBRARY</codeph></entry>
<entry><p>Dependent static library file list.</p></entry>
</row>
<row>
<entry><codeph>MACRO</codeph></entry>
<entry><p>Preprocessor declarations. Makefile declares these preprocessor
declarations using <codeph>–D</codeph> flag. </p></entry>
</row>
</tbody>
</tgroup>
</table> </section>
<section id="GUID-C55666DD-4B7F-4913-9D5D-7A5992406422"><title>bld.inf</title><p><filepath>bld.inf</filepath> is
a component definition file, used by <codeph>bldmake</codeph> to define the <filepath>abld.bat</filepath> file
and <codeph>makefiles</codeph> to be created. <filepath>bld.inf</filepath> can
be loosely compared to configure script of Linux. There is one <filepath>bld.inf</filepath> for
entire the OSS. If the project is divided into more than one module, each
module can have an individual <filepath>bld.inf</filepath> file. Have a look
at the contents of the sample MMP file below created for <codeph>libjpeg</codeph>. </p><codeblock xml:space="preserve">PRJ_PLATFORMS
default

PRJ_MMPFILES
jpeg.mmp

PRJ_EXPORTS
jpeglib.h   \epoc32\include\jpeg-6b\jpeglib.h
jconfig.h   \epoc32\include\jpeg-6b\jconfig.h
jmorecfg.h  \epoc32\include\jpeg-6b\jmorecfg.h
jerror.h    \epoc32\include\jpeg-6b\jerror.h
</codeblock><p>The following table gives a brief introduction to the <filepath>bld.inf</filepath> keywords.</p><table id="GUID-644E05C0-1E42-447D-8223-EC089FF34117">
<tgroup cols="2"><colspec colname="col1"/><colspec colname="col2"/>
<tbody>
<row>
<entry><p><b>Keyword</b></p></entry>
<entry><p><b>Description</b></p></entry>
</row>
<row>
<entry><codeph>PRJ_PLATFORMS</codeph></entry>
<entry><p>Platform to which <codeph>makefiles</codeph> will be created.</p></entry>
</row>
<row>
<entry><codeph>PRJ_MMPFILES</codeph></entry>
<entry><p>MMP file list.</p></entry>
</row>
<row>
<entry><codeph>PRJ_EXPORTS</codeph></entry>
<entry><p>List of public header files for target library users. This list
can be prepared by looking at the include directory in Linux installation. </p></entry>
</row>
</tbody>
</tgroup>
</table></section>
</conbody></concept>