epoc32/include/non_foundation_paths.hrh
author William Roberts <williamr@symbian.org>
Tue, 16 Mar 2010 16:12:26 +0000
branchSymbian2
changeset 2 2fe1408b6811
child 4 837f303aceeb
permissions -rw-r--r--
Final list of Symbian^2 public API header files
williamr@2
     1
/*
williamr@2
     2
* Copyright (c) 2002-2009 Nokia Corporation and/or its subsidiary(-ies). 
williamr@2
     3
* All rights reserved.
williamr@2
     4
* This component and the accompanying materials are made available
williamr@2
     5
* under the terms of the License "Symbian Foundation License v1.0" to Symbian Foundation members and "Symbian Foundation End User License Agreement v1.0" to non-members
williamr@2
     6
* which accompanies this distribution, and is available
williamr@2
     7
* at the URL "http://www.symbianfoundation.org/legal/licencesv10.html".
williamr@2
     8
*
williamr@2
     9
* Initial Contributors:
williamr@2
    10
* Nokia Corporation - initial contribution.
williamr@2
    11
*
williamr@2
    12
* Contributors:
williamr@2
    13
*
williamr@2
    14
* Description:  This file defines macros to be used by non-foundation code.
williamr@2
    15
*                Main thing is that non_foundation code should NEVER for instance export 
williamr@2
    16
*                headers to same directories in epoc32/include as the foundation code.
williamr@2
    17
*                
williamr@2
    18
*                However to support transition from non-foundation code to foundation code asset
williamr@2
    19
*                we introduce same layers as in foundation.
williamr@2
    20
williamr@2
    21
* Usage examples:
williamr@2
    22
*      #include <non_foundation_paths.hrh>
williamr@2
    23
*    
williamr@2
    24
*     *************************************************************
williamr@2
    25
*     * MMP file related macro usages to add the system include paths
williamr@2
    26
*     * 
williamr@2
    27
*     * The include paths has to be related to the layer in which your SW 
williamr@2
    28
*     * resides. Thus as an example: a component residing in middleware
williamr@2
    29
*     * layer should use the MW specific macro.
williamr@2
    30
*     * Keep this as a separate line in the mmp-files. If you need to
williamr@2
    31
*     * add your own SYSTEMINCLUDE paths, please defined them as
williamr@2
    32
*     * separate statement.
williamr@2
    33
*     * In addition to these , the non-foundation code should also use
williamr@2
    34
*     * one of the foundation specific macros. (APP_LAYER_SYSTEMINCLUDE,
williamr@2
    35
*     * MW_LAYER_SYSTEMINCLUDE or OS_LAYER_SYSTEMINCLUDE)
williamr@2
    36
*     *************************************************************
williamr@2
    37
*         NON_FOUNDATION_APP_LAYER_SYSTEMINCLUDE
williamr@2
    38
*         NON_FOUNDATION_MW_LAYER_SYSTEMINCLUDE
williamr@2
    39
*         NON_FOUNDATION_OS_LAYER_SYSTEMINCLUDE
williamr@2
    40
*         NON_FOUNDATION_ADAPT_LAYER_SYSTEMINCLUDE
williamr@2
    41
*
williamr@2
    42
*     *************************************************************
williamr@2
    43
*     * Macros related to exporting non-foundation headers  into 
williamr@2
    44
*     * correct place in the new system. 
williamr@2
    45
*     *
williamr@2
    46
*     * The macro that you should use depends on 2 things:
williamr@2
    47
*     *  - in which layer your package, which exports the APIs resides
williamr@2
    48
*     *  - what is the visibility of the API (public or platform)
williamr@2
    49
*     *************************************************************
williamr@2
    50
*      // the exporting of public APIs should use one of below macros
williamr@2
    51
*      // depending on which layer the API belogs to
williamr@2
    52
*      NON_FOUNDATION_APP_LAYER_EXPORT_PATH
williamr@2
    53
*      NON_FOUNDATION_MW_LAYER_EXPORT_PATH
williamr@2
    54
*      NON_FOUNDATION_OS_LAYER_EXPORT_PATH
williamr@2
    55
*      NON_FOUNDATION_ADAPT_LAYER_EXPORT_PATH
williamr@2
    56
*
williamr@2
    57
*      The hierarchy how APIs should reside in foundation has been specified
williamr@2
    58
*      in developer documentation. See further details from documentation.
williamr@2
    59
*      Below is example case relying on the structure
williamr@2
    60
*        my_own_api/group/bld.inf
williamr@2
    61
*        my_own_api/inc/header1.h
williamr@2
    62
*        my_own_api/inc/subdir/header2.h
williamr@2
    63
*  
williamr@2
    64
*      Assuming that the API is in middleware layer and a public API. 
williamr@2
    65
*      Then the bld.inf should have the following      
williamr@2
    66
*        ../inc/header1.h  NON_FOUNDATION_APP_LAYER_EXPORT_PATH(header1.h)
williamr@2
    67
*        ../inc/subdir/header2.h  NON_FOUNDATION_APP_LAYER_EXPORT_PATH(subdir/header2.h)
williamr@2
    68
*  
williamr@2
    69
*      In the above case the locations are as follow (with current MACRO settings):
williamr@2
    70
*        header1.h in /epoc32/include/ext/app
williamr@2
    71
*        header2.h in /epoc32/include/ext/app/subdir
williamr@2
    72
*
williamr@2
    73
*
williamr@2
    74
*
williamr@2
    75
*/
williamr@2
    76
williamr@2
    77
williamr@2
    78
#ifndef NON_FOUNDATION_PATHS_HRH
williamr@2
    79
#define NON_FOUNDATION_PATHS_HRH
williamr@2
    80
williamr@2
    81
/**
williamr@2
    82
* ---------------------------------------
williamr@2
    83
* Location, where the non-foundation code should export its headers.
williamr@2
    84
* These are specific to layer to which the non-foundation code belongs to.
williamr@2
    85
* See usage on top of this hrh-file.
williamr@2
    86
* ---------------------------------------
williamr@2
    87
*/
williamr@2
    88
williamr@2
    89
#if __GNUC__ >= 3
williamr@2
    90
#define NON_FOUNDATION_APP_LAYER_EXPORT_PATH(exported) /epoc32/include/ext/app/exported
williamr@2
    91
#define NON_FOUNDATION_MW_LAYER_EXPORT_PATH(exported) /epoc32/include/ext/mw/exported
williamr@2
    92
#define NON_FOUNDATION_OS_LAYER_EXPORT_PATH(exported) /epoc32/include/ext/os/exported
williamr@2
    93
#define NON_FOUNDATION_ADAPT_LAYER_EXPORT_PATH(exported) /epoc32/include/ext/adapt/exported
williamr@2
    94
#else
williamr@2
    95
#define NON_FOUNDATION_APP_LAYER_EXPORT_PATH(exported) /epoc32/include/ext/app/##exported
williamr@2
    96
#define NON_FOUNDATION_MW_LAYER_EXPORT_PATH(exported) /epoc32/include/ext/mw/##exported
williamr@2
    97
#define NON_FOUNDATION_OS_LAYER_EXPORT_PATH(exported) /epoc32/include/ext/os/##exported
williamr@2
    98
#define NON_FOUNDATION_ADAPT_LAYER_EXPORT_PATH(exported) /epoc32/include/ext/adapt/##exported
williamr@2
    99
#endif
williamr@2
   100
williamr@2
   101
williamr@2
   102
/**
williamr@2
   103
**************************************************************************
williamr@2
   104
*  General comments about the 3 define statements related to include paths.
williamr@2
   105
*  It should be enough only to have one of the below macros and one of the include macros
williamr@2
   106
*  from platform_paths.hrh.
williamr@2
   107
*  No other systemincludes to epoc32/include or subdirectories. 
williamr@2
   108
****************************************************************************
williamr@2
   109
*/
williamr@2
   110
williamr@2
   111
/**
williamr@2
   112
* This define statements defines the SYSTEMINCLUDE-line, which is intended to be 
williamr@2
   113
* used in the mmp-files that are part of the applications-layer. 
williamr@2
   114
*
williamr@2
   115
* Applications layer is the last one in the list, since most likely the most of 
williamr@2
   116
* the headers come from middleware or os-layer  => thus they are first.
williamr@2
   117
*/
williamr@2
   118
#define NON_FOUNDATION_APP_LAYER_SYSTEMINCLUDE SYSTEMINCLUDE \
williamr@2
   119
 /epoc32/include/ext/app \
williamr@2
   120
 /epoc32/include/ext/mw \
williamr@2
   121
 /epoc32/include/ext/os
williamr@2
   122
 
williamr@2
   123
/**
williamr@2
   124
* This define statements defines the SYSTEMINCLUDE-line, which is intended to be
williamr@2
   125
* used in the mmp-files that are part of the middleware-layer. 
williamr@2
   126
*/
williamr@2
   127
#define NON_FOUNDATION_MW_LAYER_SYSTEMINCLUDE SYSTEMINCLUDE \
williamr@2
   128
 /epoc32/include/ext/mw \
williamr@2
   129
 /epoc32/include/ext/os
williamr@2
   130
williamr@2
   131
/**
williamr@2
   132
* This define statements defines the SYSTEMINCLUDE-line, which is intended to be
williamr@2
   133
* used in the mmp-files that are part of the os-layer.
williamr@2
   134
*/
williamr@2
   135
#define NON_FOUNDATION_OS_LAYER_SYSTEMINCLUDE SYSTEMINCLUDE \
williamr@2
   136
 /epoc32/include/ext/os
williamr@2
   137
williamr@2
   138
/**
williamr@2
   139
* This define statements defines the SYSTEMINCLUDE-line, which is intended to be
williamr@2
   140
* used in the mmp-files that are part of the adapt-layer.
williamr@2
   141
*/
williamr@2
   142
#define NON_FOUNDATION_ADAPT_LAYER_SYSTEMINCLUDE SYSTEMINCLUDE \
williamr@2
   143
 /epoc32/include/ext/os \
williamr@2
   144
 /epoc32/include/ext/adapt
williamr@2
   145
williamr@2
   146
williamr@2
   147
/**
williamr@2
   148
****************************************************************************
williamr@2
   149
* Definitions to export IBY files to different folders where they will be taken 
williamr@2
   150
* to ROM image
williamr@2
   151
****************************************************************************
williamr@2
   152
*/
williamr@2
   153
williamr@2
   154
// Following three definitions are used for exporting IBY files to 
williamr@2
   155
// Core image (ROM+ROFS1). IBY files are exported according to their layer.
williamr@2
   156
#if __GNUC__ >= 3
williamr@2
   157
#define NON_FOUNDATION_CORE_ADAPT_LAYER_IBY_EXPORT_PATH(exported) /epoc32/rom/include/exported
williamr@2
   158
#else
williamr@2
   159
#define NON_FOUNDATION_CORE_ADAPT_LAYER_IBY_EXPORT_PATH(exported) /epoc32/rom/include/##exported
williamr@2
   160
#endif
williamr@2
   161
williamr@2
   162
williamr@2
   163
williamr@2
   164
#endif  // end of NON_FOUNDATION_PATHS_HRH
williamr@2
   165
williamr@2
   166
williamr@2
   167
williamr@2
   168
williamr@2
   169