1 | /****************************************************************************
|
---|
2 | **
|
---|
3 | ** Copyright (C) 2009 Nokia Corporation and/or its subsidiary(-ies).
|
---|
4 | ** All rights reserved.
|
---|
5 | ** Contact: Nokia Corporation ([email protected])
|
---|
6 | **
|
---|
7 | ** This file is part of the documentation of the Qt Toolkit.
|
---|
8 | **
|
---|
9 | ** $QT_BEGIN_LICENSE:LGPL$
|
---|
10 | ** Commercial Usage
|
---|
11 | ** Licensees holding valid Qt Commercial licenses may use this file in
|
---|
12 | ** accordance with the Qt Commercial License Agreement provided with the
|
---|
13 | ** Software or, alternatively, in accordance with the terms contained in
|
---|
14 | ** a written agreement between you and Nokia.
|
---|
15 | **
|
---|
16 | ** GNU Lesser General Public License Usage
|
---|
17 | ** Alternatively, this file may be used under the terms of the GNU Lesser
|
---|
18 | ** General Public License version 2.1 as published by the Free Software
|
---|
19 | ** Foundation and appearing in the file LICENSE.LGPL included in the
|
---|
20 | ** packaging of this file. Please review the following information to
|
---|
21 | ** ensure the GNU Lesser General Public License version 2.1 requirements
|
---|
22 | ** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
|
---|
23 | **
|
---|
24 | ** In addition, as a special exception, Nokia gives you certain additional
|
---|
25 | ** rights. These rights are described in the Nokia Qt LGPL Exception
|
---|
26 | ** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
|
---|
27 | **
|
---|
28 | ** GNU General Public License Usage
|
---|
29 | ** Alternatively, this file may be used under the terms of the GNU
|
---|
30 | ** General Public License version 3.0 as published by the Free Software
|
---|
31 | ** Foundation and appearing in the file LICENSE.GPL included in the
|
---|
32 | ** packaging of this file. Please review the following information to
|
---|
33 | ** ensure the GNU General Public License version 3.0 requirements will be
|
---|
34 | ** met: http://www.gnu.org/copyleft/gpl.html.
|
---|
35 | **
|
---|
36 | ** If you have questions regarding the use of this file, please contact
|
---|
37 | ** Nokia at [email protected].
|
---|
38 | ** $QT_END_LICENSE$
|
---|
39 | **
|
---|
40 | ****************************************************************************/
|
---|
41 |
|
---|
42 | //! [0]
|
---|
43 | cd /path/to/Qt
|
---|
44 | ./configure -static -prefix /path/to/Qt <other parameters>
|
---|
45 | make sub-src
|
---|
46 | //! [0]
|
---|
47 |
|
---|
48 |
|
---|
49 | //! [1]
|
---|
50 | cd /path/to/Qt/examples/tools/plugandpaint
|
---|
51 | //! [1]
|
---|
52 |
|
---|
53 |
|
---|
54 | //! [2]
|
---|
55 | make clean
|
---|
56 | PATH=/path/to/Qt/bin:$PATH
|
---|
57 | export PATH
|
---|
58 | qmake -config release
|
---|
59 | make
|
---|
60 | //! [2]
|
---|
61 |
|
---|
62 |
|
---|
63 | //! [3]
|
---|
64 | ldd ./application
|
---|
65 | //! [3]
|
---|
66 |
|
---|
67 |
|
---|
68 | //! [4]
|
---|
69 | cd /path/to/Qt/examples/tools/plugandpaint
|
---|
70 | //! [4]
|
---|
71 |
|
---|
72 |
|
---|
73 | //! [5]
|
---|
74 | make clean
|
---|
75 | qmake -config release
|
---|
76 | make
|
---|
77 | //! [5]
|
---|
78 |
|
---|
79 |
|
---|
80 | //! [6]
|
---|
81 | cd ../plugandpaintplugins
|
---|
82 | make clean
|
---|
83 | qmake -config release
|
---|
84 | make
|
---|
85 | //! [6]
|
---|
86 |
|
---|
87 |
|
---|
88 | //! [7]
|
---|
89 | #!/bin/sh
|
---|
90 | appname=`basename $0 | sed s,\.sh$,,`
|
---|
91 |
|
---|
92 | dirname=`dirname $0`
|
---|
93 | tmp="${dirname#?}"
|
---|
94 |
|
---|
95 | if [ "${dirname%$tmp}" != "/" ]; then
|
---|
96 | dirname=$PWD/$dirname
|
---|
97 | fi
|
---|
98 | LD_LIBRARY_PATH=$dirname
|
---|
99 | export LD_LIBRARY_PATH
|
---|
100 | $dirname/$appname $*
|
---|
101 | //! [7]
|
---|
102 |
|
---|
103 |
|
---|
104 | //! [8]
|
---|
105 | DESTDIR = /path/to/Qt/plugandpaint/plugins
|
---|
106 | //! [8]
|
---|
107 |
|
---|
108 |
|
---|
109 | //! [9]
|
---|
110 | qApp->addLibraryPath("/some/other/path");
|
---|
111 | //! [9]
|
---|
112 |
|
---|
113 |
|
---|
114 | //! [10]
|
---|
115 | ldd ./application
|
---|
116 | //! [10]
|
---|
117 |
|
---|
118 |
|
---|
119 | //! [11]
|
---|
120 | cd C:\path\to\Qt
|
---|
121 | configure -static <any other options you need>
|
---|
122 | //! [11]
|
---|
123 |
|
---|
124 |
|
---|
125 | //! [12]
|
---|
126 | nmake sub-src
|
---|
127 | //! [12]
|
---|
128 |
|
---|
129 |
|
---|
130 | //! [13]
|
---|
131 | cd examples\tools\plugandpaint
|
---|
132 | //! [13]
|
---|
133 |
|
---|
134 |
|
---|
135 | //! [14]
|
---|
136 | nmake clean
|
---|
137 | qmake -config release
|
---|
138 | nmake
|
---|
139 | //! [14]
|
---|
140 |
|
---|
141 |
|
---|
142 | //! [15]
|
---|
143 | cd examples\tools\plugandpaint
|
---|
144 | //! [15]
|
---|
145 |
|
---|
146 |
|
---|
147 | //! [16]
|
---|
148 | nmake clean
|
---|
149 | qmake -config release
|
---|
150 | nmake
|
---|
151 | //! [16]
|
---|
152 |
|
---|
153 |
|
---|
154 | //! [17]
|
---|
155 | cd ..\plugandpaintplugins
|
---|
156 | nmake clean
|
---|
157 | qmake -config release
|
---|
158 | nmake
|
---|
159 | //! [17]
|
---|
160 |
|
---|
161 |
|
---|
162 | //! [18]
|
---|
163 | plugins\pnp_basictools.dll
|
---|
164 | plugins\pnp_extrafilters.dll
|
---|
165 | //! [18]
|
---|
166 |
|
---|
167 |
|
---|
168 | //! [19]
|
---|
169 | qApp->addLibraryPath("C:\some\other\path");
|
---|
170 | //! [19]
|
---|
171 |
|
---|
172 |
|
---|
173 | //! [20]
|
---|
174 | embed_manifest_dll
|
---|
175 | embed_manifest_exe
|
---|
176 | //! [20]
|
---|
177 |
|
---|
178 |
|
---|
179 | //! [21]
|
---|
180 | CONFIG += embed_manifest_exe
|
---|
181 | //! [21]
|
---|
182 |
|
---|
183 |
|
---|
184 | //! [22]
|
---|
185 | <Visual Studio Install Path>\VC\redist\<Architecture>\Microsoft.VC80.CRT
|
---|
186 | //! [22]
|
---|
187 |
|
---|
188 |
|
---|
189 | //! [23]
|
---|
190 | CONFIG-=embed_manifest_dll
|
---|
191 | //! [23]
|
---|
192 |
|
---|
193 |
|
---|
194 | //! [24]
|
---|
195 | depends <application executable>
|
---|
196 | //! [24]
|
---|
197 |
|
---|
198 |
|
---|
199 | //! [25]
|
---|
200 | C:<path to Qt>\plugins
|
---|
201 | //! [25]
|
---|
202 |
|
---|
203 |
|
---|
204 | //! [26]
|
---|
205 | CONFIG-=app_bundle
|
---|
206 | //! [26]
|
---|
207 |
|
---|
208 |
|
---|
209 | //! [27]
|
---|
210 | cd /path/to/Qt
|
---|
211 | ./configure -static <other parameters>
|
---|
212 | make sub-src
|
---|
213 | //! [27]
|
---|
214 |
|
---|
215 |
|
---|
216 | //! [28]
|
---|
217 | cd /path/to/Qt/examples/tools/plugandpaint
|
---|
218 | //! [28]
|
---|
219 |
|
---|
220 |
|
---|
221 | //! [29]
|
---|
222 | make clean
|
---|
223 | qmake -config release
|
---|
224 | make
|
---|
225 | //! [29]
|
---|
226 |
|
---|
227 |
|
---|
228 | //! [30]
|
---|
229 | otool -L plugandpaint.app/Contents/MacOs/plugandpaint
|
---|
230 | //! [30]
|
---|
231 |
|
---|
232 |
|
---|
233 | //! [31]
|
---|
234 | plugandpaint.app/Contents/MacOS/plugandpaint:
|
---|
235 | /System/Library/Frameworks/Carbon.framework/Versions/A/Carbon
|
---|
236 | (compatibility version 2.0.0, current version 128.0.0)
|
---|
237 | /System/Library/Frameworks/QuickTime.framework/Versions/A/QuickTime
|
---|
238 | (compatibility version 1.0.0, current version 10.0.0)
|
---|
239 | /usr/lib/libz.1.dylib
|
---|
240 | (compatibility version 1.0.0, current version 1.2.3)
|
---|
241 | /System/Library/Frameworks/ApplicationServices.framework/Versions/A/ApplicationServices
|
---|
242 | (compatibility version 1.0.0, current version 22.0.0)
|
---|
243 | /usr/lib/libstdc++.6.dylib
|
---|
244 | (compatibility version 7.0.0, current version 7.3.0)
|
---|
245 | /usr/lib/libgcc_s.1.dylib
|
---|
246 | (compatibility version 1.0.0, current version 1.0.0)
|
---|
247 | /usr/lib/libmx.A.dylib
|
---|
248 | (compatibility version 1.0.0, current version 92.0.0)
|
---|
249 | /usr/lib/libSystem.B.dylib
|
---|
250 | (compatibility version 1.0.0, current version 88.0.0)
|
---|
251 | //! [31]
|
---|
252 |
|
---|
253 |
|
---|
254 | //! [32]
|
---|
255 | -lQtGui
|
---|
256 | //! [32]
|
---|
257 |
|
---|
258 |
|
---|
259 | //! [33]
|
---|
260 | /where/static/qt/lib/is/libQtGui.a
|
---|
261 | //! [33]
|
---|
262 |
|
---|
263 |
|
---|
264 | //! [34]
|
---|
265 | cd /path/to/Qt/examples/tools/plugandpaint
|
---|
266 | //! [34]
|
---|
267 |
|
---|
268 |
|
---|
269 | //! [35]
|
---|
270 | make clean
|
---|
271 | qmake -config release
|
---|
272 | make
|
---|
273 | //! [35]
|
---|
274 |
|
---|
275 |
|
---|
276 | //! [36]
|
---|
277 | cd ../plugandpaintplugins
|
---|
278 | make clean
|
---|
279 | qmake -config release
|
---|
280 | make
|
---|
281 | //! [36]
|
---|
282 |
|
---|
283 |
|
---|
284 | //! [37]
|
---|
285 | otool -L QtGui.framework/QtGui
|
---|
286 | //! [37]
|
---|
287 |
|
---|
288 |
|
---|
289 | //! [38]
|
---|
290 | QtGui.framework/QtGui:
|
---|
291 | /path/to/Qt/lib/QtGui.framework/Versions/4.0/QtGui
|
---|
292 | (compatibility version 4.0.0, current version 4.0.1)
|
---|
293 | /System/Library/Frameworks/Carbon.framework/Versions/A/Carbon
|
---|
294 | (compatibility version 2.0.0, current version 128.0.0)
|
---|
295 | /System/Library/Frameworks/QuickTime.framework/Versions/A/QuickTime
|
---|
296 | (compatibility version 1.0.0, current version 10.0.0)
|
---|
297 | /path/to/Qt/QtCore.framework/Versions/4.0/QtCore
|
---|
298 | (compatibility version 4.0.0, current version 4.0.1)
|
---|
299 | /usr/lib/libz.1.dylib
|
---|
300 | (compatibility version 1.0.0, current version 1.2.3)
|
---|
301 | /System/Library/Frameworks/ApplicationServices.framework/Versions/A/ApplicationServices
|
---|
302 | (compatibility version 1.0.0, current version 22.0.0)
|
---|
303 | /usr/lib/libstdc++.6.dylib
|
---|
304 | (compatibility version 7.0.0, current version 7.3.0)
|
---|
305 | /usr/lib/libgcc_s.1.dylib
|
---|
306 | (compatibility version 1.0.0, current version 1.0.0)
|
---|
307 | /usr/lib/libmx.A.dylib
|
---|
308 | (compatibility version 1.0.0, current version 92.0.0)
|
---|
309 | /usr/lib/libSystem.B.dylib
|
---|
310 | (compatibility version 1.0.0, current version 88.0.0)
|
---|
311 | //! [38]
|
---|
312 |
|
---|
313 |
|
---|
314 | //! [39]
|
---|
315 | mkdir plugandpaint.app/Contents/Frameworks
|
---|
316 | cp -R /path/to/Qt/lib/QtCore.framework
|
---|
317 | plugandpaint.app/Contents/Frameworks
|
---|
318 | cp -R /path/to/Qt/lib/QtGui.framework
|
---|
319 | plugandpaint.app/Contents/Frameworks
|
---|
320 | //! [39]
|
---|
321 |
|
---|
322 |
|
---|
323 | //! [40]
|
---|
324 | install_name_tool -id @executable_path/../Frameworks/QtCore.framework/Versions/4.0/QtCore
|
---|
325 | plugandpaint.app/Contents/Frameworks/QtCore.framework/Versions/4.0/QtCore
|
---|
326 | install_name_tool -id @executable_path/../Frameworks/QtGui.framework/Versions/4.0/QtGui
|
---|
327 | plugandpaint.app/Contents/Frameworks/QtGui.framework/Versions/4.0/QtGui
|
---|
328 | //! [40]
|
---|
329 |
|
---|
330 |
|
---|
331 | //! [41]
|
---|
332 | install_name_tool -change path/to/Qt/lib/QtCore.framework/Versions/4.0/QtCore
|
---|
333 | @executable_path/../Frameworks/QtCore.framework/Versions/4.0/QtCore
|
---|
334 | plugandpaint.app/Contents/MacOs/plugandpaint
|
---|
335 | install_name_tool -change path/to/qt/lib/QtGui.framework/Versions/4.0/QtGui
|
---|
336 | @executable_path/../Frameworks/QtGui.framework/Versions/4.0/QtGui
|
---|
337 | plugandpaint.app/Contents/MacOs/plugandpaint
|
---|
338 | //! [41]
|
---|
339 |
|
---|
340 |
|
---|
341 | //! [42]
|
---|
342 | install_name_tool -change path/to/Qt/lib/QtCore.framework/Versions/4.0/QtCore
|
---|
343 | @executable_path/../Frameworks/QtCore.framework/Versions/4.0/QtCore
|
---|
344 | plugandpaint.app/Contents/Frameworks/QtGui.framework/Versions/4.0/QtGui
|
---|
345 | //! [42]
|
---|
346 |
|
---|
347 |
|
---|
348 | //! [43]
|
---|
349 | mv plugins plugandpaint.app/Contents
|
---|
350 | //! [43]
|
---|
351 |
|
---|
352 |
|
---|
353 | //! [44]
|
---|
354 | libpnp_basictools.dylib:
|
---|
355 | libpnp_basictools.dylib
|
---|
356 | (compatibility version 0.0.0, current version 0.0.0)
|
---|
357 | /path/to/Qt/lib/QtGui.framework/Versions/4.0/QtGui
|
---|
358 | (compatibility version 4.0.0, current version 4.0.1)
|
---|
359 | /System/Library/Frameworks/Carbon.framework/Versions/A/Carbon
|
---|
360 | (compatibility version 2.0.0, current version 128.0.0)
|
---|
361 | /System/Library/Frameworks/QuickTime.framework/Versions/A/QuickTime
|
---|
362 | (compatibility version 1.0.0, current version 10.0.0)
|
---|
363 | /path/to/Qt/lib/QtCore.framework/Versions/4.0/QtCore
|
---|
364 | (compatibility version 4.0.0, current version 4.0.1)
|
---|
365 | /usr/lib/libz.1.dylib
|
---|
366 | (compatibility version 1.0.0, current version 1.2.3)
|
---|
367 | /System/Library/Frameworks/ApplicationServices.framework/Versions/A/ApplicationServices
|
---|
368 | (compatibility version 1.0.0, current version 22.0.0)
|
---|
369 | /usr/lib/libstdc++.6.dylib
|
---|
370 | (compatibility version 7.0.0, current version 7.3.0)
|
---|
371 | /usr/lib/libgcc_s.1.dylib
|
---|
372 | (compatibility version 1.0.0, current version 1.0.0)
|
---|
373 | /usr/lib/libmx.A.dylib
|
---|
374 | (compatibility version 1.0.0, current version 92.0.0)
|
---|
375 | /usr/lib/libSystem.B.dylib
|
---|
376 | (compatibility version 1.0.0, current version 88.0.0)
|
---|
377 | //! [44]
|
---|
378 |
|
---|
379 |
|
---|
380 | //! [45]
|
---|
381 | install_name_tool -change /path/to/Qt/lib/QtCore.framework/Versions/4.0/QtCore
|
---|
382 | @executable_path/../Frameworks/QtCore.framework/Versions/4.0/QtCore
|
---|
383 | plugandpaint.app/Contents/plugins/libpnp_basictools.dylib
|
---|
384 | install_name_tool -change /path/to/Qt/lib/QtGui.framework/Versions/4.0/QtGui
|
---|
385 | @executable_path/../Frameworks/QtGui.framework/Versions/4.0/QtGui
|
---|
386 | plugandpaint.app/Contents/plugins/libpnp_basictools.dylib
|
---|
387 | //! [45]
|
---|
388 |
|
---|
389 |
|
---|
390 | //! [46]
|
---|
391 | #elif defined(Q_OS_MAC)
|
---|
392 | if (pluginsDir.dirName() == "MacOS") {
|
---|
393 | pluginsDir.cdUp();
|
---|
394 | }
|
---|
395 | #endif
|
---|
396 | //! [46]
|
---|
397 |
|
---|
398 |
|
---|
399 | //! [47]
|
---|
400 | cp -R /path/to/Qt/plugins/imageformats
|
---|
401 | pluginandpaint.app/Contents/plugins
|
---|
402 | //! [47]
|
---|
403 |
|
---|
404 |
|
---|
405 | //! [48]
|
---|
406 | install_name_tool -change /path/to/Qt/lib/QtGui.framework/Versions/4.0/QtGui
|
---|
407 | @executable_path/../Frameworks/QtGui.framework/Versions/4.0/QtGui
|
---|
408 | plugandpaint.app/Contents/plugins/imageformats/libqjpeg.dylib
|
---|
409 | install_name_tool -change /path/to/Qt/lib/QtCore.framework/Versions/4.0/QtCore
|
---|
410 | @executable_path/../Frameworks/QtCore.framework/Versions/4.0/QtCore
|
---|
411 | plugandpaint.app/Contents/plugins/imageformats/libqjpeg.dylib
|
---|
412 | //! [48]
|
---|
413 |
|
---|
414 |
|
---|
415 | //! [49]
|
---|
416 | QDir dir(QApplication::applicationDirPath());
|
---|
417 | dir.cdUp();
|
---|
418 | dir.cd("plugins");
|
---|
419 | QApplication::setLibraryPaths(QStringList(dir.absolutePath()));
|
---|
420 | //! [49]
|
---|
421 |
|
---|
422 |
|
---|
423 | //! [50]
|
---|
424 | otool -L MyApp.app/Contents/MacOS/MyApp
|
---|
425 | //! [50]
|
---|
426 |
|
---|
427 |
|
---|
428 | //! [51]
|
---|
429 | QMAKE_MACOSX_DEPLOYMENT_TARGET = 10.3
|
---|
430 | //! [51]
|
---|
431 |
|
---|
432 | //! [51a]
|
---|
433 | install_name_tool -change /System/Library/Frameworks/CoreVideo.framework/
|
---|
434 | Versions/A/CoreVideo /System/Library/Frameworks/QuartzCore.framework/
|
---|
435 | Versions/A/QuartzCore libphonon_qt7.dylib
|
---|
436 | //! [51a]
|
---|
437 |
|
---|
438 | //! [51b]
|
---|
439 | ./CONFIGURE - SDK MacOSX10.4u.sdk
|
---|
440 | //! [51b]
|
---|
441 |
|
---|
442 | //! [52]
|
---|
443 | ./configure (other arguments) -universal -sdk /Developer/SDKs/MacOSX10.4u.sdk
|
---|
444 | //! [52]
|
---|
445 |
|
---|
446 |
|
---|
447 | //! [53]
|
---|
448 | QMAKE_MAC_SDK=/Developer/SDKs/MacOSX10.4u.sdk
|
---|
449 | CONFIG+=x86 ppc
|
---|
450 | //! [53]
|
---|
451 |
|
---|
452 |
|
---|
453 | //! [54]
|
---|
454 | qApp->addLibraryPath("C:/customPath/plugins");
|
---|
455 | //! [54]
|
---|
456 |
|
---|
457 | //! [55]
|
---|
458 | cd examples\widgets\wiggly
|
---|
459 | //! [55]
|
---|
460 |
|
---|
461 | //! [56]
|
---|
462 | vendorinfo = \
|
---|
463 | "%{\"Example Localized Vendor\"}" \
|
---|
464 | ":\"Example Vendor\""
|
---|
465 |
|
---|
466 | default_deployment.pkg_prerules = vendorinfo
|
---|
467 | //! [56]
|
---|
468 |
|
---|
469 | //! [57]
|
---|
470 | supported_platforms = \
|
---|
471 | "; This demo only supports S60 5.0" \
|
---|
472 | "[0x1028315F],0,0,0,{\"S60ProductID\"}"
|
---|
473 |
|
---|
474 | default_deployment.pkg_prerules += supported_platforms
|
---|
475 | //! [57]
|
---|
476 |
|
---|
477 | //! [58]
|
---|
478 | embedded_deployments = \
|
---|
479 | "; Embed Qt dependencies" \
|
---|
480 | "@\"$$[QT_INSTALL_PREFIX]/qt_installer.sis\",(0x2001E62D)"
|
---|
481 |
|
---|
482 | default_deployment.pkg_prerules += embedded_deployments
|
---|
483 | //! [58]
|
---|
484 |
|
---|
485 | //! [59]
|
---|
486 | qmake
|
---|
487 | make release-gcce
|
---|
488 | //! [59]
|
---|
489 |
|
---|
490 | //! [60]
|
---|
491 | make sis
|
---|
492 | //! [60]
|
---|