Contents of /branches/magellan-next/extras/qt4/qt4-4.7.0-r1.smage2
Parent Directory | Revision Log
Revision 6729 -
(show annotations)
(download)
Wed Sep 22 11:02:30 2010 UTC (14 years, 1 month ago) by niro
File size: 17583 byte(s)
Wed Sep 22 11:02:30 2010 UTC (14 years, 1 month ago) by niro
File size: 17583 byte(s)
auto added: ver bump to 4.7.0-r1
1 | # $Id: qt4-4.6.3-r1.smage2 5623 2010-07-17 09:08:59Z niro $ |
2 | |
3 | PNAME="qt4" |
4 | PVER="4.7.0" |
5 | PBUILD="r1" |
6 | |
7 | PCATEGORIE="x11-libs" |
8 | STATE="unstable" |
9 | |
10 | DESCRIPTION="Qt: Cross-Platform Rich Client Development Framework." |
11 | HOMEPAGE="http://trolltech.com/products/qt/" |
12 | |
13 | # build phonon or not (yes/no), disabled atm |
14 | QT4_PHONON="no" |
15 | SPECIAL_VARS="QT4_PHONON" |
16 | |
17 | SDEPEND=">= sys-dev/bison-2.4 |
18 | >= x11-proto/xineramaproto-1.1 |
19 | >= x11-proto/xextproto-7 |
20 | >= x11-proto/inputproto-2 |
21 | >= dev-util/pkgconfig-0.25 |
22 | >= dev-libs/expat-2 |
23 | >= x11-libs/libICE-1 |
24 | >= x11-libs/libSM-1.1 |
25 | >= x11-libs/libX11-1.2 |
26 | >= x11-libs/libXau-1 |
27 | >= x11-libs/libxcb-1.2 |
28 | >= x11-libs/libXcursor-1.1 |
29 | >= x11-libs/libXdmcp-1 |
30 | >= x11-libs/libXext-1 |
31 | >= x11-libs/libXfixes-4 |
32 | >= x11-libs/libXft-2.1 |
33 | >= x11-libs/libXi-1.2 |
34 | >= x11-libs/libXinerama-1 |
35 | >= x11-libs/libXrandr-1.3 |
36 | >= x11-libs/libXrender-0.9 |
37 | >= media-libs/libjpeg-8 |
38 | >= media-libs/libmng-1.0.10 |
39 | >= media-libs/libpng-1.4 |
40 | >= media-libs/lcms-1.19 |
41 | >= media-libs/freetype-2.4 |
42 | >= media-libs/fontconfig-2.8 |
43 | >= net-print/cups-1.4 |
44 | >= sys-libs/zlib-1.2 |
45 | >= media-libs/giflib-4.1 |
46 | >= sys-apps/dbus-1.3 |
47 | >= virtual/opengl |
48 | >= media-libs/nas-1.9 |
49 | >= dev-libs/openssl-1.0.0 |
50 | >= dev-db/sqlite-3.7 |
51 | >= dev-db/mysql5-5.1 |
52 | >= dev-db/unixodbc-2.3" |
53 | |
54 | if [[ ${QT4_PHONON} = yes ]] |
55 | then |
56 | SDEPEND+=" |
57 | >= media-libs/gstreamer-0.10.25 |
58 | >= media-libs/gst-plugins-base-0.10.25 |
59 | >= media-libs/gst-plugins-good-0.10.16" |
60 | fi |
61 | |
62 | #PROVIDE="virtual/phonon" |
63 | |
64 | SRCFILE="${PNAME/4/}-everywhere-opensource-src-${PVER}.tar.gz" |
65 | SRCDIR="${BUILDDIR}/${PNAME/4/}-everywhere-opensource-src-${PVER}" |
66 | |
67 | SPLIT_PACKAGES="${PNAME}-core |
68 | ${PNAME}-dbus |
69 | ${PNAME}-script |
70 | ${PNAME}-gui |
71 | ${PNAME}-svg |
72 | ${PNAME}-sql |
73 | ${PNAME}-xmlpatterns |
74 | ${PNAME}-opengl |
75 | ${PNAME}-qt3support |
76 | ${PNAME}-webkit |
77 | ${PNAME}-test |
78 | ${PNAME}-multimedia |
79 | ${PNAME}-assistant |
80 | ${PNAME}-declarative |
81 | ${PNAME}" # this is the transistional meta package! |
82 | |
83 | if [[ ${QT4_PHONON} = yes ]] |
84 | then |
85 | SPLIT_PACKAGES+="${PNAME}-phonon" |
86 | fi |
87 | |
88 | KDE_QT_SNAPSHOT_ID="8fa76375a2f030ecf8aa23c917f51f04333a1b2c" |
89 | |
90 | # include kde4 to get the right KDEDIR for phonon! |
91 | sminclude mtools kde4 |
92 | |
93 | SRC_URI=( |
94 | ftp://ftp.qt.nokia.com/qt/source/${SRCFILE} |
95 | mirror://${PNAME}/${SRCFILE} |
96 | mirror://${PNAME}/qt-4.5.1-no-hardcoded_fonts.patch |
97 | mirror://${PNAME}/qt-${PVER}-kde-qt-${KDE_QT_SNAPSHOT_ID}.patch |
98 | ) |
99 | |
100 | # add phonon patches |
101 | if [[ ${QT4_PHONON} = yes ]] |
102 | then |
103 | SRC_URI=( |
104 | ${SRC_URI[*]} |
105 | mirror://${PNAME}/qt-4.5.3-phonon-2.patch |
106 | ) |
107 | fi |
108 | |
109 | UP2DATE="updatecmd ftp://ftp.qt.nokia.com/qt/source/ | grep -v -- -tp | grep -v -- -beta | grep qt-everywhere-opensource-src | lasttarball gz" |
110 | |
111 | ## global vars ## |
112 | export QTDIR=${SRCDIR} |
113 | export LD_LIBRARY_PATH=${QTDIR}/lib |
114 | export PATH=${QTDIR}/bin:${PATH} |
115 | export PLATFORM=linux-g++ |
116 | [[ ${ARCH} = x86_64 ]] && export PLATFORM=linux-g++-64 |
117 | # install prefix |
118 | export QT_PREFIX=/usr |
119 | # etc dir |
120 | export QT_SYSCONFDIR=/etc/${PNAME} |
121 | # envfile |
122 | export QT_ENVFILE=/etc/env.d/45${PNAME} |
123 | |
124 | # do not run postinstall/remove from kde4 include |
125 | unset -f postinstall |
126 | unset -f postremove |
127 | |
128 | split_info_qt4() |
129 | { |
130 | DESCRIPTION="Qt4: Cross-Platform Rich Client Development Framework." |
131 | DEPEND="== x11-libs/qt4-core-${PVER} |
132 | == x11-libs/qt4-gui-${PVER} |
133 | == x11-libs/qt4-svg-${PVER} |
134 | == x11-libs/qt4-sql-${PVER} |
135 | == x11-libs/qt4-script-${PVER} |
136 | == x11-libs/qt4-xmlpatterns-${PVER} |
137 | == x11-libs/qt4-dbus-${PVER} |
138 | == x11-libs/qt4-opengl-${PVER} |
139 | == x11-libs/qt4-qt3support-${PVER} |
140 | == x11-libs/qt4-webkit-${PVER} |
141 | == x11-libs/qt4-test-${PVER} |
142 | == x11-libs/qt4-multimedia-${PVER} |
143 | == x11-libs/qt4-assistant-${PVER} |
144 | == x11-libs/qt4-declarative-${PVER}" |
145 | |
146 | if [[ ${QT4_PHONON} = yes ]] |
147 | then |
148 | DEPEND+=" |
149 | == x11-libs/qt4-phonon-${PVER}" |
150 | fi |
151 | |
152 | PKGTYPE="virtual" |
153 | NOPKGBUILD="true" |
154 | |
155 | # drop everything we don't need in the meta package: |
156 | INHERITS="" |
157 | SPECIAL_VARS="" |
158 | SPECIAL_FUNCTIONS="" |
159 | SDEPEND="" |
160 | PROVIDE="" |
161 | unset -f preinstall |
162 | #unset -f postinstall |
163 | unset -f preremove |
164 | unset -f postremove |
165 | |
166 | # inform the user |
167 | postinstall() |
168 | { |
169 | echo |
170 | echo "Please note that this meta package is only provided for convenience." |
171 | echo "No packages should depend directly on this meta package, but on the" |
172 | echo "specific split Qt packages needed." |
173 | echo |
174 | echo "This package will be removed in future versions!" |
175 | echo |
176 | } |
177 | } |
178 | |
179 | split_info_qt4-core() |
180 | { |
181 | DESCRIPTION="Qt4: Cross-Platform Rich Client Development Framework." |
182 | DEPEND=">= dev-libs/openssl-0.9.8k |
183 | >= sys-libs/zlib-1.2" |
184 | } |
185 | |
186 | split_info_qt4-gui() |
187 | { |
188 | DESCRIPTION="The GUI module for the Qt4 toolkit." |
189 | DEPEND=">= x11-libs/qt4-core-${PVER} |
190 | >= x11-libs/qt4-script-${PVER} |
191 | >= x11-libs/qt4-dbus-${PVER} |
192 | >= x11-libs/libSM-1.1 |
193 | >= x11-libs/libX11-1.2 |
194 | >= x11-libs/libXcursor-1.1 |
195 | >= x11-libs/libXext-1 |
196 | >= x11-libs/libXfont-1.4 |
197 | >= x11-libs/libXi-1.2 |
198 | >= x11-libs/libXinerama-1 |
199 | >= x11-libs/libXrandr-1.3 |
200 | >= media-libs/libjpeg-7 |
201 | >= media-libs/libmng-1.0.10 |
202 | >= media-libs/libpng-1.2.40 |
203 | >= media-libs/libtiff-3.9.1 |
204 | >= media-libs/freetype-2.3.9 |
205 | >= media-libs/fontconfig-2.7 |
206 | >= net-print/cups-1.4 |
207 | >= sys-libs/zlib-1.2 |
208 | >= media-libs/nas-1.9" |
209 | } |
210 | |
211 | split_info_qt4-svg() |
212 | { |
213 | DESCRIPTION="The SVG module for the Qt4 toolkit." |
214 | DEPEND=">= x11-libs/qt4-gui-${PVER}" |
215 | } |
216 | |
217 | split_info_qt4-sql() |
218 | { |
219 | DESCRIPTION="The SQL module for the Qt4 toolkit." |
220 | DEPEND=">= x11-libs/qt4-core-${PVER} |
221 | >= dev-db/sqlite-3.6 |
222 | >= dev-db/mysql5-5.1 |
223 | >= dev-db/unixodbc-2.2.14" |
224 | } |
225 | |
226 | split_info_qt4-script() |
227 | { |
228 | DESCRIPTION="The ECMAScript module for the Qt4 toolkit." |
229 | DEPEND=">= x11-libs/qt4-core-${PVER}" |
230 | } |
231 | |
232 | split_info_qt4-xmlpatterns() |
233 | { |
234 | DESCRIPTION="The patternist module for the Qt toolkit." |
235 | DEPEND=">= x11-libs/qt4-core-${PVER}" |
236 | } |
237 | |
238 | split_info_qt4-dbus() |
239 | { |
240 | DESCRIPTION="The DBus module for the Qt4 toolkit." |
241 | DEPEND=">= x11-libs/qt4-core-${PVER} |
242 | >= sys-apps/dbus-1.3" |
243 | } |
244 | |
245 | split_info_qt4-opengl() |
246 | { |
247 | DESCRIPTION="The OpenGL module for the Qt4 toolkit." |
248 | DEPEND=">= x11-libs/qt4-core-${PVER} |
249 | >= x11-libs/qt4-gui-${PVER} |
250 | >= virtual/opengl" |
251 | } |
252 | |
253 | if [[ ${QT4_PHONON} = yes ]] |
254 | then |
255 | split_info_qt4-phonon() |
256 | { |
257 | DESCRIPTION="The Phonon module for the Qt4 toolkit." |
258 | DEPEND=">= x11-libs/qt4-gui-${PVER} |
259 | >= sys-apps/dbus-1.3 |
260 | >= media-libs/gstreamer-0.10.25 |
261 | >= media-libs/gst-plugins-base-0.10.25 |
262 | >= media-libs/gst-plugins-good-0.10.16" |
263 | |
264 | PROVIDE="virtual/phonon" |
265 | |
266 | preinstall() |
267 | { |
268 | if [[ -n $(magequery -n phonon) ]] |
269 | then |
270 | die "please uninstall kde-base/phonon first!" |
271 | fi |
272 | } |
273 | |
274 | postinstall() |
275 | { |
276 | # breaks compilation if the old phonon symlink from kde-phonon exist |
277 | if [[ -L ${MROOT}/opt/kde4/lib/libphonon.so ]] |
278 | then |
279 | rm ${MROOT}/opt/kde4/lib/libphonon.so |
280 | fi |
281 | } |
282 | } |
283 | fi |
284 | |
285 | split_info_qt4-qt3support() |
286 | { |
287 | DESCRIPTION="The Qt3 support module for the Qt toolkit." |
288 | DEPEND=">= x11-libs/qt4-core-${PVER} |
289 | >= x11-libs/qt4-gui-${PVER} |
290 | >= x11-libs/qt4-sql-${PVER}" |
291 | if [[ ${QT4_PHONON} = yes ]] |
292 | then |
293 | DEPEND+=" |
294 | == x11-libs/qt4-phonon-${PVER}" |
295 | fi |
296 | } |
297 | |
298 | split_info_qt4-webkit() |
299 | { |
300 | DESCRIPTION="The Webkit module for the Qt4 toolkit." |
301 | DEPEND=">= x11-libs/qt4-core-${PVER} |
302 | >= x11-libs/qt4-dbus-${PVER} |
303 | >= x11-libs/qt4-gui-${PVER}" |
304 | if [[ ${QT4_PHONON} = yes ]] |
305 | then |
306 | DEPEND+=" |
307 | == x11-libs/qt4-phonon-${PVER}" |
308 | fi |
309 | } |
310 | |
311 | split_info_qt4-test() |
312 | { |
313 | DESCRIPTION="The testing framework module for the Qt4 toolkit." |
314 | DEPEND=">= x11-libs/qt4-core-${PVER}" |
315 | } |
316 | |
317 | split_info_qt4-multimedia() |
318 | { |
319 | DESCRIPTION="The Multimedia module for the Qt4 toolkit." |
320 | DEPEND=">= x11-libs/qt4-core-${PVER} |
321 | >= x11-libs/qt4-gui-${PVER}" |
322 | } |
323 | |
324 | split_info_qt4-assistant() |
325 | { |
326 | DESCRIPTION="The assistant help module for the Qt4 toolkit." |
327 | DEPEND=">= x11-libs/qt4-gui-${PVER} |
328 | >= x11-libs/qt4-sql-${PVER} |
329 | >= x11-libs/qt4-webkit-${PVER}" |
330 | } |
331 | |
332 | split_info_qt4-declarative() |
333 | { |
334 | DESCRIPTION="The Declarative module for the Qt4 toolkit." |
335 | DEPEND=">= x11-libs/qt4-core-${PVER} |
336 | >= x11-libs/qt4-gui-${PVER} |
337 | >= x11-libs/qt4-multimedia-${PVER} |
338 | >= x11-libs/qt4-opengl-${PVER} |
339 | >= x11-libs/qt4-script-${PVER} |
340 | >= x11-libs/qt4-sql-${PVER} |
341 | >= x11-libs/qt4-svg-${PVER} |
342 | >= x11-libs/qt4-webkit-${PVER} |
343 | >= x11-libs/qt4-xmlpatterns-${PVER}" |
344 | } |
345 | |
346 | src_prepare() |
347 | { |
348 | munpack ${SRCFILE} || die |
349 | cd ${SRCDIR} |
350 | |
351 | # no hardcoded font-aliases |
352 | # see: https://cvs.fedoraproject.org/viewvc/rpms/qt4/F-8/qt-x11-opensource-src-4.3.4-no-hardcoded-font-aliases.patch?view=markup |
353 | mpatch qt-4.5.1-no-hardcoded_fonts.patch || die |
354 | |
355 | if [[ ${QT4_PHONON} = yes ]] |
356 | then |
357 | # install service files needed by kde |
358 | mpatch qt-4.5.3-phonon-2.patch || die |
359 | # fix variable kdelocation from the patch |
360 | sed -i "s:@@KDEDIR@@:${KDEDIR}:g" ${SRCDIR}/src/plugins/phonon/gstreamer/gstreamer.pro || die |
361 | fi |
362 | |
363 | # kdeqt patches from http://gitorious.org/+kde-developers/qt/kde-qt |
364 | mpatch qt-${PVER}-kde-qt-${KDE_QT_SNAPSHOT_ID}.patch || die |
365 | |
366 | # set our cflags and fix up our header and lib locations |
367 | cd ${SRCDIR}/mkspecs/${PLATFORM} |
368 | sed -i -e "s:QMAKE_CFLAGS_RELEASE.*=.*:QMAKE_CFLAGS_RELEASE=${CFLAGS}:" \ |
369 | -e "s:QMAKE_CXXFLAGS_RELEASE.*=.*:QMAKE_CXXFLAGS_RELEASE=${CXXFLAGS}:" \ |
370 | -e "s:QMAKE_LFLAGS_RELEASE.*=.*:QMAKE_LFLAGS_RELEASE=${LDFLAGS}:" \ |
371 | -e 's:$(QTDIR)/include:&/qt:' \ |
372 | -e "s:\$(QTDIR)/lib:\$(QTDIR)/$(mlibdir):" \ |
373 | qmake.conf \ |
374 | || die |
375 | |
376 | # fix libdir to lib64 on 64bit arches |
377 | sed -i "s:/lib$:/$(mlibdir):" qmake.conf || die |
378 | |
379 | # disable rpath |
380 | sed -i "s:QMAKE_RPATH.*=.*:QMAKE_RPATH=:" qmake.conf || die |
381 | |
382 | # get rid of /usr/X11R6 |
383 | sed -i "s:X11R6/::" qmake.conf || die |
384 | |
385 | # same goes for the g++ definitions |
386 | # they where moved to an extra file with qt4 |
387 | cd ${SRCDIR}/mkspecs/common |
388 | sed -i -e "s:QMAKE_CFLAGS_RELEASE.*=.*:QMAKE_CFLAGS_RELEASE=${CPPFLAGS} ${CFLAGS} ${ASFLAGS}:" \ |
389 | -e "s:QMAKE_CXXFLAGS_RELEASE.*=.*:QMAKE_CXXFLAGS_RELEASE=${CPPFLAGS} ${CXXFLAGS} ${ASFLAGS}:" \ |
390 | -e "s:QMAKE_LFLAGS_RELEASE.*=.*:QMAKE_LFLAGS_RELEASE=${LDFLAGS}:" \ |
391 | -e 's:$(QTDIR)/include:&/qt:' \ |
392 | -e "s:\$(QTDIR)/lib:\$(QTDIR)/$(mlibdir):" \ |
393 | g++.conf \ |
394 | || die |
395 | |
396 | # fix libdir to lib64 on 64bit arches |
397 | sed -i "s:/lib$:/$(mlibdir):" g++.conf || die |
398 | |
399 | # disable rpath |
400 | sed -i "s:QMAKE_RPATH.*=.*:QMAKE_RPATH=:" g++.conf || die |
401 | |
402 | # get rid of /usr/X11R6 |
403 | sed -i "s:X11R6/::" linux.conf || die |
404 | } |
405 | |
406 | src_compile() |
407 | { |
408 | cd ${SRCDIR} |
409 | |
410 | # add missing lib64 search path on 64bit arches |
411 | local myconf |
412 | [[ $(mlibdir) != lib ]] && myconf="-L/usr/$(mlibdir)" |
413 | |
414 | # enable this only for binutils >=2.18 |
415 | [[ $(ld -v | sed 's/.*\ \([0-9].[0-9].*\)/\1/') > 2.17 ]] && myconf+=" -reduce-relocations" |
416 | |
417 | # disable openvg atm |
418 | myconf+=" -no-openvg" |
419 | |
420 | if [[ ${QT4_PHONON} = yes ]] |
421 | then |
422 | myconf+=" -phonon" |
423 | myconf+=" -phonon-backend" |
424 | else |
425 | myconf+=" -no-phonon" |
426 | myconf+=" -no-phonon-backend" |
427 | fi |
428 | |
429 | ./configure \ |
430 | -prefix ${QT_PREFIX} \ |
431 | -sysconfdir ${QT_SYSCONFDIR} \ |
432 | -datadir ${QT_PREFIX}/share/qt \ |
433 | -docdir ${QT_PREFIX}/share/doc/qt-${PVER} \ |
434 | -headerdir ${QT_PREFIX}/include/qt \ |
435 | -plugindir ${QT_PREFIX}/$(mlibdir)/qt/plugins \ |
436 | -libdir ${QT_PREFIX}/$(mlibdir) \ |
437 | -datadir ${QT_PREFIX}/share/qt \ |
438 | -translationdir ${QT_PREFIX}/share/qt/translations \ |
439 | -confirm-license \ |
440 | -opensource \ |
441 | -platform ${PLATFORM} \ |
442 | -xplatform ${PLATFORM} \ |
443 | -verbose \ |
444 | -silent \ |
445 | -fast \ |
446 | -release \ |
447 | -no-separate-debug-info \ |
448 | -optimized-qmake \ |
449 | -system-libjpeg \ |
450 | -system-libmng \ |
451 | -system-libpng \ |
452 | -system-libtiff \ |
453 | -system-zlib \ |
454 | -system-nas-sound \ |
455 | -system-sqlite \ |
456 | -nomake examples \ |
457 | -nomake demos \ |
458 | -nomake docs \ |
459 | -no-rpath \ |
460 | -qt3support \ |
461 | -stl \ |
462 | -lpthread \ |
463 | -largefile \ |
464 | -sm \ |
465 | -xrender \ |
466 | -opengl \ |
467 | -qt-gif \ |
468 | -cups \ |
469 | -dbus-linked \ |
470 | -openssl \ |
471 | -webkit \ |
472 | -svg \ |
473 | -xmlpatterns \ |
474 | -declarative \ |
475 | -plugin-sql-sqlite \ |
476 | -plugin-sql-mysql \ |
477 | -plugin-sql-odbc \ |
478 | -I/usr/include/mysql \ |
479 | -L/usr/$(mlibdir)/mysql \ |
480 | ${myconf} \ |
481 | || die |
482 | |
483 | mmake all || die |
484 | } |
485 | |
486 | src_install_qt4-core() |
487 | { |
488 | cd ${SRCDIR} |
489 | |
490 | local i |
491 | for i in src/tools/moc \ |
492 | src/tools/rcc \ |
493 | src/tools/uic \ |
494 | src/corelib \ |
495 | src/xml \ |
496 | src/network \ |
497 | src/plugins/codecs \ |
498 | tools/linguist/lrelease \ |
499 | tools/linguist/lupdate \ |
500 | tools/linguist/lconvert |
501 | do |
502 | mmake -C ${i} INSTALL_ROOT=${BINDIR} install || die |
503 | done |
504 | |
505 | # install missing qmake |
506 | mmake INSTALL_ROOT=${BINDIR} install_qmake || die |
507 | mlink qmake ${QT_PREFIX}/bin/qmake${PVER:0:1} || die |
508 | |
509 | # install missing findtr |
510 | minstallexec ${SRCDIR}/bin/findtr ${QT_PREFIX}/bin || die |
511 | |
512 | # install all spec files |
513 | mmake INSTALL_ROOT=${BINDIR} install_mkspecs || die |
514 | |
515 | # remove unneeded specs |
516 | echo "removing unneeded specs ..." |
517 | install -d ${BUILDDIR}/keep |
518 | mv ${BINDIR}/${QT_PREFIX}/share/qt/mkspecs/default ${BUILDDIR}/keep || die |
519 | mv ${BINDIR}/${QT_PREFIX}/share/qt/mkspecs/common ${BUILDDIR}/keep || die |
520 | mv ${BINDIR}/${QT_PREFIX}/share/qt/mkspecs/features ${BUILDDIR}/keep || die |
521 | mv ${BINDIR}/${QT_PREFIX}/share/qt/mkspecs/qws ${BUILDDIR}/keep || die |
522 | mv ${BINDIR}/${QT_PREFIX}/share/qt/mkspecs/${PLATFORM} ${BUILDDIR}/keep || die |
523 | if [[ ${ARCH} = x86_64 ]] |
524 | then |
525 | mv ${BINDIR}/${QT_PREFIX}/share/qt/mkspecs/linux-g++ ${BUILDDIR}/keep || die |
526 | fi |
527 | mv ${BINDIR}/${QT_PREFIX}/share/qt/mkspecs/qconfig.pri ${BUILDDIR}/keep || die |
528 | rm -rf ${BINDIR}/${QT_PREFIX}/share/qt/mkspecs/* || die |
529 | mv ${BUILDDIR}/keep/* ${BINDIR}/${QT_PREFIX}/share/qt/mkspecs || die |
530 | |
531 | # fix qmake cache file |
532 | minstalldir ${QT_PREFIX}/share/qt || die |
533 | sed "s:${SRCDIR}:${QT_PREFIX}:g" ${SRCDIR}/.qmake.cache > ${BINDIR}/${QT_PREFIX}/share/qt/.qmake.cache || die |
534 | |
535 | # # some needed symlinks |
536 | # mlink libqt-mt.so ${QT_PREFIX}/$(mlibdir)/libqt.so || die |
537 | |
538 | # generate translations and install them |
539 | # use freshly built libraries |
540 | LD_LIBRARY_PATH=${SRCDIR}/lib ${SRCDIR}/bin/lrelease translations/*.ts || die |
541 | minstalldir ${QT_PREFIX}/share/qt/translations || die |
542 | minstallfile translations/\*.qm ${QT_PREFIX}/share/qt/translations || die |
543 | |
544 | # keep the qt4 sysdir |
545 | mkeepdir ${QT_SYSCONFDIR} || die |
546 | |
547 | # environ vars |
548 | minstalldir /etc/env.d || die |
549 | echo "QMAKESPEC=\"${PLATFORM}\"" > ${BINDIR}/${QT_ENVFILE} || die |
550 | echo "QTDIR=\"${QT_PREFIX}\"" >> ${BINDIR}/${QT_ENVFILE} || die |
551 | |
552 | if [[ ${QT_PREFIX} != /usr ]] |
553 | then |
554 | # overwrite the env file here, there may be one in usr |
555 | # and we want this as system-wide default |
556 | :> ${BINDIR}/${QT_ENVFILE} || die |
557 | echo "PATH=\"${QT_PREFIX}/bin\"" >> ${BINDIR}/${QT_ENVFILE} || die |
558 | echo "ROOTPATH=\"${QT_PREFIX}/bin\"" >> ${BINDIR}/${QT_ENVFILE} || die |
559 | echo "LDPATH=\"${QT_PREFIX}/$(mlibdir)\"" >> ${BINDIR}/${QT_ENVFILE} || die |
560 | echo "MANPATH=\"${QT_PREFIX}/share/man\"" >> ${BINDIR}/${QT_ENVFILE} || die |
561 | echo "PKG_CONFIG_PATH=\"${QT_PREFIX}/$(mlibdir)/pkgconfig\"" ${BINDIR}/${QT_ENVFILE} || die |
562 | fi |
563 | |
564 | minstalldocs GPL* changes-${PVER} LICENSE* OPENSOURCE* README* || die |
565 | } |
566 | |
567 | src_install_qt4-gui() |
568 | { |
569 | cd ${SRCDIR} |
570 | |
571 | local i |
572 | for i in src/gui \ |
573 | src/scripttools \ |
574 | tools/designer \ |
575 | tools/linguist/linguist \ |
576 | tools/qdbus/qdbusviewer \ |
577 | src/plugins/imageformats/gif \ |
578 | src/plugins/imageformats/ico \ |
579 | src/plugins/imageformats/jpeg \ |
580 | src/plugins/imageformats/mng \ |
581 | src/plugins/imageformats/tiff \ |
582 | src/plugins/inputmethods |
583 | do |
584 | mmake -C ${i} INSTALL_ROOT=${BINDIR} install || die |
585 | done |
586 | } |
587 | |
588 | src_install_qt4-svg() |
589 | { |
590 | cd ${SRCDIR} |
591 | |
592 | local i |
593 | for i in src/svg \ |
594 | src/plugins/imageformats/svg \ |
595 | src/plugins/iconengines/svgiconengine |
596 | do |
597 | mmake -C ${i} INSTALL_ROOT=${BINDIR} install || die |
598 | done |
599 | } |
600 | |
601 | src_install_qt4-sql() |
602 | { |
603 | cd ${SRCDIR} |
604 | |
605 | local i |
606 | for i in src/sql src/plugins/sqldrivers |
607 | do |
608 | mmake -C ${i} INSTALL_ROOT=${BINDIR} install || die |
609 | done |
610 | } |
611 | |
612 | src_install_qt4-script() |
613 | { |
614 | cd ${SRCDIR} |
615 | mmake -C src/script INSTALL_ROOT=${BINDIR} install || die |
616 | } |
617 | |
618 | src_install_qt4-xmlpatterns() |
619 | { |
620 | cd ${SRCDIR} |
621 | |
622 | local i |
623 | for i in src/xmlpatterns tools/xmlpatterns |
624 | do |
625 | mmake -C ${i} INSTALL_ROOT=${BINDIR} install || die |
626 | done |
627 | } |
628 | |
629 | src_install_qt4-dbus() |
630 | { |
631 | cd ${SRCDIR} |
632 | |
633 | local i |
634 | for i in src/dbus \ |
635 | tools/qdbus/qdbus \ |
636 | tools/qdbus/qdbusxml2cpp \ |
637 | tools/qdbus/qdbuscpp2xml |
638 | do |
639 | mmake -C ${i} INSTALL_ROOT=${BINDIR} install || die |
640 | done |
641 | } |
642 | |
643 | src_install_qt4-opengl() |
644 | { |
645 | cd ${SRCDIR} |
646 | |
647 | local i |
648 | for i in src/opengl src/plugins/graphicssystems/opengl |
649 | do |
650 | mmake -C ${i} INSTALL_ROOT=${BINDIR} install || die |
651 | done |
652 | } |
653 | |
654 | if [[ ${QT4_PHONON} = yes ]] |
655 | then |
656 | src_install_qt4-phonon() |
657 | { |
658 | cd ${SRCDIR} |
659 | |
660 | local i |
661 | for i in src/phonon src/plugins/phonon |
662 | do |
663 | mmake -C ${i} INSTALL_ROOT=${BINDIR} install || die |
664 | done |
665 | |
666 | # needed symlink; kde-4.4 includes from Phonon/* |
667 | if [[ ! -e ${BINDIR}/${QT_PREFIX}/include/qt/Phonon ]] |
668 | then |
669 | mlink phonon ${QT_PREFIX}/include/qt/Phonon || die |
670 | fi |
671 | } |
672 | fi |
673 | |
674 | src_install_qt4-qt3support() |
675 | { |
676 | cd ${SRCDIR} |
677 | |
678 | local i |
679 | for i in src/qt3support \ |
680 | src/tools/uic3 \ |
681 | tools/designer/src/plugins/widgets \ |
682 | tools/qtconfig \ |
683 | tools/porting |
684 | do |
685 | mmake -C ${i} INSTALL_ROOT=${BINDIR} install || die |
686 | done |
687 | } |
688 | |
689 | src_install_qt4-webkit() |
690 | { |
691 | cd ${SRCDIR} |
692 | |
693 | local i |
694 | for i in src/3rdparty/webkit/WebCore \ |
695 | tools/designer/src/plugins/qwebview |
696 | do |
697 | mmake -C ${i} INSTALL_ROOT=${BINDIR} install || die |
698 | done |
699 | } |
700 | |
701 | src_install_qt4-test() |
702 | { |
703 | cd ${SRCDIR} |
704 | mmake -C src/testlib INSTALL_ROOT=${BINDIR} install || die |
705 | } |
706 | |
707 | src_install_qt4-multimedia() |
708 | { |
709 | cd ${SRCDIR} |
710 | mmake -C src/multimedia INSTALL_ROOT=${BINDIR} install || die |
711 | } |
712 | |
713 | src_install_qt4-assistant() |
714 | { |
715 | cd ${SRCDIR} |
716 | |
717 | local i |
718 | for i in tools/assistant \ |
719 | tools/pixeltool \ |
720 | tools/qdoc3 |
721 | do |
722 | mmake -C ${i} INSTALL_ROOT=${BINDIR} install || die |
723 | done |
724 | |
725 | # no-make atm! |
726 | # # install missing qch docs |
727 | # minstall ${QT_PREFIX}/share/doc/qt-${PVER}/qch || die |
728 | # minstallfile doc/qch/\*.qch ${QT_PREFIX}/share/doc/qt-${PVER}/qch || die |
729 | # |
730 | # # install missing qdoc3 |
731 | # minstalldir ${QT_PREFIX}/bin || die |
732 | # minstallexec tools/qdoc3/qdoc3 ${QT_PREFIX}/bin || die |
733 | } |
734 | |
735 | src_install_qt4-declarative() |
736 | { |
737 | cd ${SRCDIR} |
738 | |
739 | local i |
740 | for i in src/declarative \ |
741 | tools/qml |
742 | do |
743 | mmake -C ${i} INSTALL_ROOT=${BINDIR} install || die |
744 | done |
745 | } |