~ubuntu-branches/ubuntu/wily/qgis/wily

« back to all changes in this revision

Viewing changes to mac/xcode/ReadMe-Developers.rtf

  • Committer: Bazaar Package Importer
  • Author(s): Johan Van de Wauw
  • Date: 2010-07-11 20:23:24 UTC
  • mfrom: (3.1.4 squeeze)
  • Revision ID: james.westby@ubuntu.com-20100711202324-5ktghxa7hracohmr
Tags: 1.4.0+12730-3ubuntu1
* Merge from Debian unstable (LP: #540941).
* Fix compilation issues with QT 4.7
* Add build-depends on libqt4-webkit-dev 

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
{\rtf1\ansi\ansicpg1252\cocoartf949\cocoasubrtf430
 
2
{\fonttbl\f0\fswiss\fcharset0 Helvetica;}
 
3
{\colortbl;\red255\green255\blue255;}
 
4
\vieww10500\viewh12500\viewkind0
 
5
\pard\tx720\tx1440\tx2160\tx2880\tx3600\tx4320\tx5040\tx5760\tx6480\tx7200\tx7920\tx8640\qc\pardirnatural
 
6
 
 
7
\f0\b\fs36 \cf0 QGIS Xcode Project\
 
8
Developer Notes\
 
9
\pard\tx720\tx1440\tx2160\tx2880\tx3600\tx4320\tx5040\tx5760\tx6480\tx7200\tx7920\tx8640\ql\qnatural\pardirnatural
 
10
 
 
11
\b0\fs24 \cf0 \
 
12
\pard\tx720\tx1440\tx2160\tx2880\tx3600\tx4320\tx5040\tx5760\tx6480\tx7200\tx7920\tx8640\ql\qnatural\pardirnatural
 
13
 
 
14
\b \cf0 Sources\
 
15
\pard\tx720\tx1440\tx2160\tx2880\tx3600\tx4320\tx5040\tx5760\tx6480\tx7200\tx7920\tx8640\ql\qnatural\pardirnatural
 
16
 
 
17
\b0 \cf0 \
 
18
\'95 Adding sources and other files and folders to the project.\
 
19
\
 
20
Always use \ul Relative to Project\ulnone  reference type.\
 
21
\
 
22
Cmake files can't be used to dynamically generate source lists in the Xcode targets.  Any additions and deletions of source files in the cmake configuration must be manually mirrored in the Xcode project.\
 
23
\
 
24
\'95\'a0Layout\
 
25
\
 
26
\pard\tx720\tx1440\tx2160\tx2880\tx3600\tx4320\tx5040\tx5760\tx6480\tx7200\tx7920\tx8640\li720\fi-360\ql\qnatural\pardirnatural
 
27
\cf0 \ul \ulc0 Configuration Files\ulnone  - Xcode config files.  dependency config, system target, core moc lists set here.\
 
28
\ul Sources\ulnone  - standard Qgis sources\
 
29
\ul generated\ulnone  - intermediate sources generated by bison, flex, moc, uic, rcc in script phases.  Subfolders will start empty of files, and contents appear red in the project until generated.\
 
30
\pard\tx720\tx1440\tx2160\tx2880\tx3600\tx4320\tx5040\tx5760\tx6480\tx7200\tx7920\tx8640\ql\qnatural\pardirnatural
 
31
\cf0 \
 
32
\'95 Custom Rules\
 
33
\
 
34
- moc\
 
35
\
 
36
source file names matching: *.h\
 
37
script: $QTMOC $QT_CXXFLAGS -o "$DERIVED_FILES_DIR/moc_$INPUT_FILE_BASE.cpp" "$INPUT_FILE_PATH"\
 
38
with output files: $(DERIVED_FILES_DIR)/moc_$(INPUT_FILE_BASE).cpp\
 
39
\
 
40
- qrc\
 
41
\
 
42
sources: *.qrc\
 
43
script: $QTRCC -name $INPUT_FILE_BASE -o "$DERIVED_FILES_DIR/qrc_$INPUT_FILE_BASE.cpp" "$INPUT_FILE_PATH"\
 
44
output: $(DERIVED_FILES_DIR)/qrc_$(INPUT_FILE_BASE).cpp\
 
45
\
 
46
- ui\
 
47
\
 
48
do ui generation in a script phase because:\
 
49
\
 
50
        - Xcode will attempt to process generated *.h with moc rule\
 
51
        - parallel processing might not finish ui's before a cpp source needs it\
 
52
\
 
53
plugins need a user-defined setting to set the TARGET_PLUGINDIR of the plugin.\
 
54
\
 
55
\'95 Header paths\
 
56
\
 
57
- to access ui headers in qgis_gui from other targets:\
 
58
\
 
59
"$(TARGET_TEMP_DIR)/../qgis_gui.build/DerivedSources"\
 
60
\
 
61
\
 
62
\pard\tx720\tx1440\tx2160\tx2880\tx3600\tx4320\tx5040\tx5760\tx6480\tx7200\tx7920\tx8640\ql\qnatural\pardirnatural
 
63
 
 
64
\b \cf0 Targets
 
65
\b0 \
 
66
\
 
67
There is no way to conditionaly compile whole targets, or individual sources.  So fo now, all conditional sources are required.  Conditional targets must be built manually.\
 
68
\
 
69
Linked libraries can be conditionalized in the config file.\
 
70
\
 
71
Sources can be conditionalized inside the source, with one big #ifdef block.\
 
72
\
 
73
Another possibility is to indirectly add sources in a script phase as generated - copy the true source if condition true, dump dummy empty source if false.  The target always compiles the generated source.  Wouldn't work for whole targets, as bogus binary is generated.\
 
74
\
 
75
\
 
76
Targets can be destructive (most are) - for example, everything is built directly into the application bundle, which is really the domain of the Qgis.app target.  This simplifies packaging for optional plugins.  This means that if just the app target is cleaned, all link and copy phases of all other targets must be redone.\
 
77
\
 
78
\
 
79
The app target must be built last.  This is so that the Qt bundling phase install_name_tool step will get all built libraries and plugins.  Also, the bundled and stripped-of-headers Qt frameworks would interfere with building all other targets.\
 
80
\
 
81
\
 
82
libqgispython must be in MacOS/lib.  Qgis attempts to load it dynamically, with a hardwired path.\
 
83
\
 
84
\
 
85
 
 
86
\b Adding Providers and Plugins (C++)\
 
87
\pard\tx720\tx1440\tx2160\tx2880\tx3600\tx4320\tx5040\tx5760\tx6480\tx7200\tx7920\tx8640\ql\qnatural\pardirnatural
 
88
 
 
89
\b0 \cf0 \
 
90
1. Add sources to project\
 
91
\
 
92
2. Duplicate provider or plugin template target and rename\
 
93
\
 
94
3. Add sources to target\
 
95
\
 
96
4. Edit target settings (make sure to change both Debug and Release configurations):\
 
97
\
 
98
        a. Product Name\
 
99
        b. Header Search Paths - add extra source folders needed, and config _INC vars\
 
100
        c. Other Linker Flags - add config *_LIB vars as needed\
 
101
        d. Preprocessor Macros - add extra defs if needed\
 
102
        e. TARGET_PLUGINDIR - name of folder of plugin source\
 
103
\
 
104
\
 
105
\pard\tx720\tx1440\tx2160\tx2880\tx3600\tx4320\tx5040\tx5760\tx6480\tx7200\tx7920\tx8640\ql\qnatural
 
106
\cf0 - William Kyngesburye\
 
107
\pard\tx720\tx1440\tx2160\tx2880\tx3600\tx4320\tx5040\tx5760\tx6480\tx7200\tx7920\tx8640\ql\qnatural
 
108
{\field{\*\fldinst{HYPERLINK "mailto:kyngchaos@kyngchaos.com"}}{\fldrslt \cf0 kyngchaos@kyngchaos.com}}
 
109
\fs20 \
 
110
\pard\tx720\tx1440\tx2160\tx2880\tx3600\tx4320\tx5040\tx5760\tx6480\tx7200\tx7920\tx8640\ql\qnatural
 
111
{\field{\*\fldinst{HYPERLINK "http://www.kyngchaos.com"}}{\fldrslt 
 
112
\fs24 \cf0 http://www.kyngchaos.com/}}
 
113
\fs24 \
 
114
}
 
 
b'\\ No newline at end of file'