|
1 # With DEF files enabled, removed exported symbols are treated as errors |
|
2 # and there is binary compatibility between successive builds. |
|
3 |
|
4 CONFIG -= def_files_disabled |
|
5 |
|
6 # Firstly, if the MMP_RULES already contain a defBlock variable, don't generate another one |
|
7 # (this bit is slightly magic, because it depends upon everyone creating their DEFFILE statements |
|
8 # in a defBlock variable; but otherwise we have to expand MMP_RULES then scan for the DEFFILE keyword) |
|
9 !contains(MMP_RULES, defBlock) { |
|
10 # Apps are executables on Symbian, so don't have exports, and therefore don't have DEF files |
|
11 # Plugins use standard DEF files, which qmake generates, so shouldn't be using these DEFFILE |
|
12 # statements - they use the qmake generated statements instead |
|
13 # Static libraries obviously don't have DEF files, as they don't take part in dynamic linkage |
|
14 !contains(TEMPLATE, app):!contains(CONFIG, plugin):!contains(CONFIG, staticlib): { |
|
15 !isEmpty(defFilePath) { |
|
16 defBlock = \ |
|
17 "$${LITERAL_HASH}ifdef WINSCW" \ |
|
18 "DEFFILE $$defFilePath/bwins/$${TARGET}.def" \ |
|
19 "$${LITERAL_HASH}elif defined EABI" \ |
|
20 "DEFFILE $$defFilePath/eabi/$${TARGET}.def" \ |
|
21 "$${LITERAL_HASH}endif" |
|
22 } else { |
|
23 # If defFilePath is not defined, then put the folders containing the DEF files at the |
|
24 # same level as the .pro (and generated MMP) file(s) |
|
25 defBlock = \ |
|
26 "$${LITERAL_HASH}ifdef WINSCW" \ |
|
27 "DEFFILE ./bwins/$${TARGET}.def" \ |
|
28 "$${LITERAL_HASH}elif defined EABI" \ |
|
29 "DEFFILE ./eabi/$${TARGET}.def" \ |
|
30 "$${LITERAL_HASH}endif" |
|
31 } |
|
32 MMP_RULES += defBlock |
|
33 } |
|
34 } |