Adding mkspecs.
[ptas] / zouba / qt4-maemo5 / mkspecs / features / symbian / platform_paths.prf
1 #
2 # ==============================================================================
3 #  Name        : platform_paths.prf
4 #  Part of     : 
5 #  Interface   : Platform Path Definitions API for Qt/S60
6 #  Description : Predefined include paths to be used in the pro-files for the 
7 #                components in the layered model. There is one definition for
8 #                each layer. The pro-file should use the statement that is 
9 #                intended for the same layer as where the pro-file resides.
10 #
11 # Usage examples:
12 #
13 #     Note: this file gets automatically added to all Qt/S60 projects
14 #    
15 #     Variable usages to add the system include paths
16 #       
17 #       The include paths has to be related to the layer in which your SW 
18 #       resides. Thus as an example: a component residing in middleware
19 #       layer should use the MW specific macro.
20 #
21 #         INCLUDEPATH += $$APP_LAYER_SYSTEMINCLUDE
22 #         INCLUDEPATH += $$MW_LAYER_SYSTEMINCLUDE
23 #         INCLUDEPATH += $$OS_LAYER_SYSTEMINCLUDE
24 #
25 #       If there is a need to include public headers of some S60 component,
26 #       various *_EXPORT_PATH macros can be utilized:
27 #
28 #         INCLUDEPATH += $$OS_LAYER_PUBLIC_EXPORT_PATH(somecomponent)
29 #
30 #     Variables related to using various parts of stdapis:
31 #
32 #       To use STLLIB you need to have this in your pro-file:
33 #
34 #         QMAKE_CXXFLAGS.CW *= $$STLLIB_USAGE_CW_FLAGS
35 #         DEFINES *= $$STLLIB_USAGE_DEFINES
36 #
37 #       Depending on what module you are using from stdapis you need to have
38 #       one or more of the following variables in your pro-file.
39 #
40 #         INCLUDEPATH += $$OS_LAYER_LIBC_SYSTEMINCLUDE
41 #         INCLUDEPATH += $$OS_LAYER_GLIB_SYSTEMINCLUDE
42 #         INCLUDEPATH += $$OS_LAYER_SSL_SYSTEMINCLUDE
43 #         INCLUDEPATH += $$OS_LAYER_STDCPP_SYSTEMINCLUDE
44 #         INCLUDEPATH += $$OS_LAYER_BOOST_SYSTEMINCLUDE
45 #         INCLUDEPATH += $$OS_LAYER_DBUS_SYSTEMINCLUDE
46 #         INCLUDEPATH += $$OS_LAYER_LIBUTILITY_SYSTEMINCLUDE
47 #
48 #
49 #       
50 #
51 # ==============================================================================
52
53 exists($${EPOCROOT}epoc32/include/platform_paths.prf) {
54     
55     # Load platform specific paths
56     load($${EPOCROOT}epoc32/include/platform_paths.prf)
57
58 } else {  
59
60     # No platform specific paths provided, use default paths
61
62     exists($${EPOCROOT}epoc32/include/mw) { # New SF structure
63     
64         # ---------------------------------------
65         # Location, where the applications layer specific public headers are exported
66         # ---------------------------------------
67
68         defineReplace(APP_LAYER_SDK_EXPORT_PATH) {
69              return (/epoc32/include/app/$$1)
70         }
71         defineReplace(APP_LAYER_PUBLIC_EXPORT_PATH) {
72              return (/epoc32/include/app/$$1)
73         }
74
75         # ---------------------------------------
76         # Location, where the applications layer specific platform headers are exported
77         # ---------------------------------------
78
79         defineReplace(APP_LAYER_DOMAIN_EXPORT_PATH) {
80              return (/epoc32/include/platform/app/$$1)
81         }
82         defineReplace(APP_LAYER_PLATFORM_EXPORT_PATH) {
83              return (/epoc32/include/platform/app/$$1)
84         }
85
86         # ---------------------------------------
87         # Location, where the middleware layer specific public headers are exported
88         # ---------------------------------------
89
90         defineReplace(MW_LAYER_SDK_EXPORT_PATH) {
91              return (/epoc32/include/mw/$$1)
92         }
93         defineReplace(MW_LAYER_PUBLIC_EXPORT_PATH) {
94              return (/epoc32/include/mw/$$1)
95         }
96
97         # ---------------------------------------
98         # Location, where the middleware layer specific platform headers are exported
99         # ---------------------------------------
100
101         defineReplace(MW_LAYER_DOMAIN_EXPORT_PATH) {
102              return (/epoc32/include/platform/mw/$$1)
103         }
104         defineReplace(MW_LAYER_PLATFORM_EXPORT_PATH) {
105              return (/epoc32/include/platform/mw/$$1)
106         }
107
108         # ---------------------------------------
109         # Location, where the os layer specific public headers are exported
110         # ---------------------------------------
111
112         defineReplace(OSEXT_LAYER_SDK_EXPORT_PATH) {
113              return (/epoc32/include/$$1)
114         }
115         # WARNING: If the following path changes see the exists() function around line 219
116         defineReplace(OS_LAYER_PUBLIC_EXPORT_PATH) {
117              return (/epoc32/include/$$1)
118         }
119
120         # ---------------------------------------
121         # Location, where the os specific platform headers are exported
122         # ---------------------------------------
123
124         defineReplace(OSEXT_LAYER_DOMAIN_EXPORT_PATH) {
125              return (/epoc32/include/platform/$$1)
126         }
127         defineReplace(OS_LAYER_PLATFORM_EXPORT_PATH) {
128              return (/epoc32/include/platform/$$1)
129         }
130
131         # ---------------------------------------
132         #  General comments about the 3 define statements related to include paths:
133         #  1) the /epoc32/include/oem is now defined there for backward compability.
134         #     Once the directory is empty, the directory will be removed. However this 
135         #     enables us to ensure that if you use these define statements => you do 
136         #     not have to remove the statements later on, when the directory no longer 
137         #     exists.
138         #  2) These statements should be enough in normal cases. For certain specific 
139         #     cases you might need to add some specific directory from /epoc32/include
140         #     (for instance /epoc32/include/ecom).
141         #     In normal cases the include staments in code should be relative to one of 
142         #     the system include paths, but in certain cases, the included files requires
143         #     that the subdirectory is also part of the system include paths.
144         # ---------------------------------------
145
146         # This variable defines the include paths, which are intended to be 
147         # used in the pro-files that are part of the applications-layer. It includes all 
148         # the needed directories from the /epoc32/include, that are valid ones for the 
149         # application-layer components. 
150         #
151         # Applications layer is the last one in the list, since most likely the most of 
152         # the headers come from middleware or os-layer  => thus they are first.
153
154         APP_LAYER_SYSTEMINCLUDE = \
155          /epoc32/include \
156          /epoc32/include/mw \
157          /epoc32/include/platform/mw \
158          /epoc32/include/platform \
159          /epoc32/include/app \
160          /epoc32/include/platform/app \
161          /epoc32/include/platform/loc \
162          /epoc32/include/platform/mw/loc \
163          /epoc32/include/platform/app/loc \
164          /epoc32/include/platform/loc/sc \
165          /epoc32/include/platform/mw/loc/sc \
166          /epoc32/include/platform/app/loc/sc
167
168         # This define statements defines the include paths, which are intended to be
169         # used in the pro-files that are part of the middleware-layer. It includes all 
170         # the needed directories from the /epoc32/include, that are valid ones for the 
171         # middleware-layer components. 
172
173         MW_LAYER_SYSTEMINCLUDE = \
174          /epoc32/include \
175          /epoc32/include/mw \
176          /epoc32/include/platform/mw \
177          /epoc32/include/platform \
178          /epoc32/include/platform/loc \
179          /epoc32/include/platform/mw/loc \
180          /epoc32/include/platform/loc/sc \
181          /epoc32/include/platform/mw/loc/sc
182
183         # This define statements defines the include paths, which are intended to be
184         # used in the pro-files that are part of the  osextensions-layer. It includes all
185         # the needed directories from the /epoc32/include, that are valid ones for the
186         # os-layer components. 
187
188         OS_LAYER_SYSTEMINCLUDE = \
189          /epoc32/include \
190          /epoc32/include/platform \
191          /epoc32/include/platform/loc \
192          /epoc32/include/platform/loc/sc
193
194         # This define statements defines the include paths, which are intended to be
195         # used in the pro-files that are part of the os-layer. This is intended 
196         # to be only used by those components which need to use in their mmp-file either
197         # kern_ext.mmh or nkern_ext.mmh. Reason is that those
198         # 2 files already contain the /epoc32/include  as system include path.
199
200         OS_LAYER_KERNEL_SYSTEMINCLUDE = \
201          /epoc32/include/platform
202
203
204         # ---------------------------------------
205         # Definitions that also define the systeminclude paths for various
206         # part of stdapis. Append to INCLUDEPATH in pro-file.
207         # ---------------------------------------
208
209         OS_LAYER_LIBC_SYSTEMINCLUDE = $$OS_LAYER_PUBLIC_EXPORT_PATH(stdapis) \
210                                       $$OS_LAYER_PUBLIC_EXPORT_PATH(stdapis/sys)
211
212         OS_LAYER_GLIB_SYSTEMINCLUDE = $$OS_LAYER_PUBLIC_EXPORT_PATH(stdapis/glib-2.0) \
213                                       $$OS_LAYER_PUBLIC_EXPORT_PATH(stdapis/glib-2.0/glib) \
214                                       $$OS_LAYER_PUBLIC_EXPORT_PATH(stdapis/glib-2.0/gObject)
215
216         OS_LAYER_SSL_SYSTEMINCLUDE = $$OS_LAYER_PUBLIC_EXPORT_PATH(stdapis/openssl)
217
218         # stlportv5 is preferred over stlport as it has the throwing version of operator new
219         exists($${EPOCROOT}epoc32/include/stdapis/stlport) \
220         :!exists($${EPOCROOT}epoc32/include/stdapis/stlportv5) {
221             OS_LAYER_STDCPP_SYSTEMINCLUDE = $$OS_LAYER_PUBLIC_EXPORT_PATH(stdapis/stlport)
222         } else {
223             OS_LAYER_STDCPP_SYSTEMINCLUDE = $$OS_LAYER_PUBLIC_EXPORT_PATH(stdapis/stlportv5)
224         }
225         
226         OS_LAYER_BOOST_SYSTEMINCLUDE = $$OS_LAYER_PUBLIC_EXPORT_PATH(stdapis/boost)
227
228         OS_LAYER_DBUS_SYSTEMINCLUDE = $$OS_LAYER_PUBLIC_EXPORT_PATH(stdapis/dbus-1.0) \
229                                       $$OS_LAYER_PUBLIC_EXPORT_PATH(stdapis/dbus-1.0/dbus)
230
231         OS_LAYER_LIBUTILITY_SYSTEMINCLUDE = $$OS_LAYER_PLATFORM_EXPORT_PATH(stdapis/utility)
232
233         # ---------------------------------------
234         # Definitions to export IBY files to different folders where they will be taken 
235         # to ROM image
236         # ---------------------------------------
237               
238         defineReplace(CORE_APP_LAYER_IBY_EXPORT_PATH) {
239             return(/epoc32/rom/include/core/app/$$1)
240         }
241         defineReplace(CORE_MW_LAYER_IBY_EXPORT_PATH) {
242             return(/epoc32/rom/include/core/mw/$$1)
243         }
244         defineReplace(CORE_OSEXT_LAYER_IBY_EXPORT_PATH) {
245             return(/epoc32/rom/include/core/os/$$1)
246         }
247         defineReplace(CORE_OS_LAYER_IBY_EXPORT_PATH) {
248             return(/epoc32/rom/include/core/os/$$1)
249         }
250         defineReplace(CORE_ADAPT_LAYER_IBY_EXPORT_PATH) {
251             return(/epoc32/rom/include/$$1)
252         }
253         
254         # You need to define the following in pro-file, if you are using the stllib:
255         # QMAKE_CXXFLAGS.CW *= $$STLLIB_USAGE_CW_FLAGS
256         # DEFINES *= $$STLLIB_USAGE_DEFINES
257         STLLIB_USAGE_CW_FLAGS = "-wchar_t on"
258         STLLIB_USAGE_DEFINES = _WCHAR_T_DECLARED
259
260     } else { # Old pre-SF structure
261
262         # ---------------------------------------
263         # Location, where the applications layer specific public headers are exported
264         # ---------------------------------------
265
266         defineReplace(APP_LAYER_SDK_EXPORT_PATH) {
267              return (/epoc32/include/applications/$$1)
268         }
269         defineReplace(APP_LAYER_PUBLIC_EXPORT_PATH) {
270              return (/epoc32/include/applications/$$1)
271         }
272
273         # ---------------------------------------
274         # Location, where the applications layer specific platform headers are exported
275         # ---------------------------------------
276
277         defineReplace(APP_LAYER_DOMAIN_EXPORT_PATH) {
278              return (/epoc32/include/domain/applications/$$1)
279         }
280         defineReplace(APP_LAYER_PLATFORM_EXPORT_PATH) {
281              return (/epoc32/include/domain/applications/$$1)
282         }
283
284         # ---------------------------------------
285         # Location, where the middleware layer specific public headers are exported
286         # ---------------------------------------
287
288         defineReplace(MW_LAYER_SDK_EXPORT_PATH) {
289              return (/epoc32/include/middleware/$$1)
290         }
291         defineReplace(MW_LAYER_PUBLIC_EXPORT_PATH) {
292              return (/epoc32/include/middleware/$$1)
293         }
294
295         # ---------------------------------------
296         # Location, where the middleware layer specific platform headers are exported
297         # ---------------------------------------
298
299         defineReplace(MW_LAYER_DOMAIN_EXPORT_PATH) {
300              return (/epoc32/include/domain/middleware/$$1)
301         }
302         defineReplace(MW_LAYER_PLATFORM_EXPORT_PATH) {
303              return (/epoc32/include/domain/middleware/$$1)
304         }
305
306         # ---------------------------------------
307         # Location, where the os layer specific public headers are exported
308         # ---------------------------------------
309
310         defineReplace(OSEXT_LAYER_SDK_EXPORT_PATH) {
311              return (/epoc32/include/osextensions/$$1)
312         }
313         # WARNING: If the following path changes see the exists() function around line 430
314         defineReplace(OS_LAYER_PUBLIC_EXPORT_PATH) {
315              return (/epoc32/include/osextensions/$$1)
316         }
317
318         # ---------------------------------------
319         # Location, where the os specific platform headers are exported
320         # ---------------------------------------
321
322         defineReplace(OSEXT_LAYER_DOMAIN_EXPORT_PATH) {
323              return (/epoc32/include/domain/osextensions/$$1)
324         }
325         defineReplace(OS_LAYER_PLATFORM_EXPORT_PATH) {
326              return (/epoc32/include/domain/osextensions/$$1)
327         }
328
329         # ---------------------------------------
330         #  General comments about the 3 define statements related to include paths:
331         #  1) the /epoc32/include/oem is now defined there for backward compability.
332         #     Once the directory is empty, the directory will be removed. However this 
333         #     enables us to ensure that if you use these define statements => you do 
334         #     not have to remove the statements later on, when the directory no longer 
335         #     exists.
336         #  2) These statements should be enough in normal cases. For certain specific 
337         #     cases you might need to add some specific directory from /epoc32/include
338         #     (for instance /epoc32/include/ecom).
339         #     In normal cases the include staments in code should be relative to one of 
340         #     the system include paths, but in certain cases, the included files requires
341         #     that the subdirectory is also part of the system include paths.
342         # ---------------------------------------
343
344         # This variable defines the include paths, which are intended to be 
345         # used in the pro-files that are part of the applications-layer. It includes all 
346         # the needed directories from the /epoc32/include, that are valid ones for the 
347         # application-layer components. 
348         #
349         # Applications layer is the last one in the list, since most likely the most of 
350         # the headers come from middleware or os-layer  => thus they are first.
351
352         APP_LAYER_SYSTEMINCLUDE = \
353          /epoc32/include \
354          /epoc32/include/oem \
355          /epoc32/include/middleware \
356          /epoc32/include/domain/middleware \
357          /epoc32/include/osextensions \
358          /epoc32/include/domain/osextensions \
359          /epoc32/include/applications \
360          /epoc32/include/domain/applications \
361          /epoc32/include/domain/osextensions/loc \
362          /epoc32/include/domain/middleware/loc \
363          /epoc32/include/domain/applications/loc \
364          /epoc32/include/domain/osextensions/loc/sc \
365          /epoc32/include/domain/middleware/loc/sc \
366          /epoc32/include/domain/applications/loc/sc
367
368         # This define statements defines the include paths, which are intended to be
369         # used in the pro-files that are part of the middleware-layer. It includes all 
370         # the needed directories from the /epoc32/include, that are valid ones for the 
371         # middleware-layer components. 
372
373         MW_LAYER_SYSTEMINCLUDE = \
374          /epoc32/include \
375          /epoc32/include/oem \
376          /epoc32/include/middleware \
377          /epoc32/include/domain/middleware \
378          /epoc32/include/osextensions \
379          /epoc32/include/domain/osextensions \
380          /epoc32/include/domain/osextensions/loc \
381          /epoc32/include/domain/middleware/loc \
382          /epoc32/include/domain/osextensions/loc/sc \
383          /epoc32/include/domain/middleware/loc/sc
384
385         # This define statements defines the include paths, which are intended to be
386         # used in the pro-files that are part of the  osextensions-layer. It includes all
387         # the needed directories from the /epoc32/include, that are valid ones for the
388         # os-layer components. 
389
390         OS_LAYER_SYSTEMINCLUDE = \
391          /epoc32/include \
392          /epoc32/include/oem \
393          /epoc32/include/osextensions \
394          /epoc32/include/domain/osextensions \
395          /epoc32/include/domain/osextensions/loc \
396          /epoc32/include/domain/osextensions/loc/sc
397
398         # This define statements defines the include paths, which are intended to be
399         # used in the pro-files that are part of the os-layer. This is intended 
400         # to be only used by those components which need to use in their mmp-file either
401         # kern_ext.mmh or nkern_ext.mmh. Reason is that those
402         # 2 files already contain the /epoc32/include  as system include path.
403
404         OS_LAYER_KERNEL_SYSTEMINCLUDE = \
405          /epoc32/include/oem \
406          /epoc32/include/osextensions \
407          /epoc32/include/domain/osextensions
408
409
410         # ---------------------------------------
411         # Definitions that also define the systeminclude paths for various
412         # part of stdapis. Append to INCLUDEPATH in pro-file.
413         # ---------------------------------------
414
415         OS_LAYER_LIBC_SYSTEMINCLUDE = $$OS_LAYER_PUBLIC_EXPORT_PATH(stdapis) \
416                                       $$OS_LAYER_PUBLIC_EXPORT_PATH(stdapis/sys) \
417                                       /epoc32/include/stdapis \
418                                       /epoc32/include/stdapis/sys
419
420         OS_LAYER_GLIB_SYSTEMINCLUDE = $$OS_LAYER_PUBLIC_EXPORT_PATH(stdapis/glib-2.0) \
421                                       $$OS_LAYER_PUBLIC_EXPORT_PATH(stdapis/glib-2.0/glib) \
422                                       $$OS_LAYER_PUBLIC_EXPORT_PATH(stdapis/glib-2.0/gObject) \
423                                       /epoc32/include/stdapis/glib-2.0 \
424                                       /epoc32/include/stdapis/glib-2.0/glib \
425                                       /epoc32/include/stdapis/glib-2.0/gObject
426
427         OS_LAYER_SSL_SYSTEMINCLUDE = $$OS_LAYER_PUBLIC_EXPORT_PATH(stdapis/openssl) \
428                                      /epoc32/include/stdapis/openssl
429
430         # stlportv5 is preferred over stlport as it has the throwing version of operator new
431         OS_LAYER_STDCPP_SYSTEMINCLUDE = $$OS_LAYER_PUBLIC_EXPORT_PATH(stdapis/stlportv5) \
432                                         /epoc32/include/stdapis/stlportv5
433         exists($${EPOCROOT}epoc32/include/osextensions/stdapis/stlport) \
434         |exists($${EPOCROOT}epoc32/include/stdapis/stlport) {
435             !exists($${EPOCROOT}epoc32/include/osextensions/stdapis/stlportv5) \
436             :!exists($${EPOCROOT}epoc32/include/stdapis/stlportv5) {
437                 OS_LAYER_STDCPP_SYSTEMINCLUDE = $$OS_LAYER_PUBLIC_EXPORT_PATH(stdapis/stlport) \
438                                                 /epoc32/include/stdapis/stlport
439             }
440         }
441         
442         OS_LAYER_BOOST_SYSTEMINCLUDE = $$OS_LAYER_PUBLIC_EXPORT_PATH(stdapis/boost) \
443                                        /epoc32/include/stdapis/boost
444
445         OS_LAYER_DBUS_SYSTEMINCLUDE = $$OS_LAYER_PUBLIC_EXPORT_PATH(stdapis/dbus-1.0) \
446                                       $$OS_LAYER_PUBLIC_EXPORT_PATH(stdapis/dbus-1.0/dbus) \
447                                       /epoc32/include/stdapis/dbus-1.0 \
448                                       /epoc32/include/stdapis/dbus-1.0/dbus
449
450         OS_LAYER_LIBUTILITY_SYSTEMINCLUDE = $$OS_LAYER_PLATFORM_EXPORT_PATH(stdapis/utility) \
451                                             /epoc32/include/stdapis/utility
452
453         # ---------------------------------------
454         # Definitions to export IBY files to different folders where they will be taken 
455         # to ROM image
456         # ---------------------------------------
457               
458         defineReplace(CORE_APP_LAYER_IBY_EXPORT_PATH) {
459             return(/epoc32/rom/include/core/app/$$1)
460         }
461         defineReplace(CORE_MW_LAYER_IBY_EXPORT_PATH) {
462             return(/epoc32/rom/include/core/mw/$$1)
463         }
464         defineReplace(CORE_OSEXT_LAYER_IBY_EXPORT_PATH) {
465             return(/epoc32/rom/include/core/osext/$$1)
466         }
467         defineReplace(CORE_OS_LAYER_IBY_EXPORT_PATH) {
468             return(/epoc32/rom/include/core/osext/$$1)
469         }
470         defineReplace(CORE_ADAPT_LAYER_IBY_EXPORT_PATH) {
471             return(/epoc32/rom/include/$$1)
472         }
473         
474         # You need to define the following in pro-file, if you are using the stllib:
475         # QMAKE_CXXFLAGS.CW *= $$STLLIB_USAGE_CW_FLAGS
476         # DEFINES *= $$STLLIB_USAGE_DEFINES
477         STLLIB_USAGE_CW_FLAGS = "-wchar_t on"
478         STLLIB_USAGE_DEFINES = _WCHAR_T_DECLARED
479     
480     } 
481 }
482
483
484