/[gentoo-x86]/eclass/kde4-base.eclass
Gentoo

Diff of /eclass/kde4-base.eclass

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

Revision 1.10 Revision 1.11
1# Copyright 2007-2008 Gentoo Foundation 1# Copyright 2007-2008 Gentoo Foundation
2# Distributed under the terms of the GNU General Public License v2 2# Distributed under the terms of the GNU General Public License v2
3# $Header: /var/cvsroot/gentoo-x86/eclass/kde4-base.eclass,v 1.10 2008/04/14 13:23:14 zlin Exp $ 3# $Header: /var/cvsroot/gentoo-x86/eclass/kde4-base.eclass,v 1.11 2008/05/15 19:49:32 ingmar Exp $
4 4
5# @ECLASS: kde4-base.eclass 5# @ECLASS: kde4-base.eclass
6# @MAINTAINER: 6# @MAINTAINER:
7# kde@gentoo.org 7# kde@gentoo.org
8# @BLURB: This eclass provides functions for kde 4.0 ebuilds 8# @BLURB: This eclass provides functions for kde 4.0 ebuilds
16inherit base eutils multilib cmake-utils kde4-functions 16inherit base eutils multilib cmake-utils kde4-functions
17 17
18EXPORT_FUNCTIONS pkg_setup src_unpack src_compile src_test src_install pkg_postinst pkg_postrm 18EXPORT_FUNCTIONS pkg_setup src_unpack src_compile src_test src_install pkg_postinst pkg_postrm
19 19
20kde4-base_set_qt_dependencies() { 20kde4-base_set_qt_dependencies() {
21 local qt qtcore qtgui qt3support qtsvg qttest qtopengl qtdepend qtopengldepend 21 local qt qtcore qtgui qt3support qtdepend qtopengldepend
22 22
23 # use dependencies 23 # use dependencies
24 case "${EAPI}" in 24 case "${EAPI}" in
25 kdebuild-1) 25 kdebuild-1)
26 qt="[accessibility][dbus][debug?][gif][jpeg][png][qt3support][ssl][zlib]" 26 qt="[accessibility][dbus][gif][jpeg][png][qt3support][ssl][zlib]"
27 qtcore="[debug?][qt3support][ssl]" 27 qtcore="[qt3support][ssl]"
28 qtgui="[accessibility][dbus][debug?]" 28 qtgui="[accessibility][dbus]"
29 qt3support="[accessibility][debug?]" 29 qt3support="[accessibility]"
30 qtsvg="[debug?]"
31 qttest="[debug?]"
32 qtopengl="[debug?]"
33 case "${OPENGL_REQUIRED}" in 30 case "${OPENGL_REQUIRED}" in
34 always) 31 always)
35 qt="${qt}[opengl]" 32 qt="${qt}[opengl]"
36 ;; 33 ;;
37 optional) 34 optional)
44 # split qt 41 # split qt
45 qtdepend=" 42 qtdepend="
46 x11-libs/qt-core:4${qtcore} 43 x11-libs/qt-core:4${qtcore}
47 x11-libs/qt-gui:4${qtgui} 44 x11-libs/qt-gui:4${qtgui}
48 x11-libs/qt-qt3support:4${qt3support} 45 x11-libs/qt-qt3support:4${qt3support}
46 x11-libs/qt-script:4
49 x11-libs/qt-svg:4${qtsvg} 47 x11-libs/qt-svg:4
50 x11-libs/qt-test:4${qttest}" 48 x11-libs/qt-test:4"
51 qtopengldepend="x11-libs/qt-opengl:4${qtopengl}" 49 qtopengldepend="x11-libs/qt-opengl:4"
52 50
53 # allow monolithic qt for PV < 4.1 51 # allow monolithic qt for PV < 4.1
54 case "${PV}" in 52 case "${PV}" in
55 scm|9999.4|4.1*) : ;; 53 scm|9999.4|4.1*) : ;;
56 *) 54 *)
288kde4-base_pkg_setup() { 286kde4-base_pkg_setup() {
289 debug-print-function $FUNCNAME "$@" 287 debug-print-function $FUNCNAME "$@"
290 288
291 case "${EAPI}" in 289 case "${EAPI}" in
292 kdebuild-1) 290 kdebuild-1)
293 [[ -n ${QT4_BUILT_WITH_USE_CHECK} || -n ${KDE4_BUILT_WITH_USE_CHECK} ]] && \ 291 [[ -n ${QT4_BUILT_WITH_USE_CHECK} || -n ${KDE4_BUILT_WITH_USE_CHECK[@]} ]] && \
294 die "built_with_use illegal in this EAPI!" 292 die "built_with_use illegal in this EAPI!"
295 ;; 293 ;;
296 *) 294 *)
295 # Make KDE4_BUILT_WITH_USE_CHECK an array if it isn't already
296 local line kde4_built_with_use_check=()
297 if [[ -n ${KDE4_BUILT_WITH_USE_CHECK[@]} && $(declare -p KDE4_BUILT_WITH_USE_CHECK) != 'declare -a '* ]]; then
298 while read line; do
299 [[ -z ${line} ]] && continue
300 kde4_built_with_use_check+=("${line}")
301 done <<< "${KDE4_BUILT_WITH_USE_CHECK}"
302 KDE4_BUILT_WITH_USE_CHECK="${kde4_built_with_use_check[@]}"
303 fi
304
297 # KDE4 applications require qt4 compiled with USE="accessibility dbus gif jpeg png qt3support ssl zlib". 305 # KDE4 applications require qt4 compiled with USE="accessibility dbus gif jpeg png qt3support ssl zlib".
298 if has_version '<x11-libs/qt-4.4_alpha:4'; then 306 if has_version '<x11-libs/qt-4.4_alpha:4'; then
299 QT4_BUILT_WITH_USE_CHECK="${QT4_BUILT_WITH_USE_CHECK} accessibility dbus gif jpeg png qt3support ssl zlib" 307 QT4_BUILT_WITH_USE_CHECK="${QT4_BUILT_WITH_USE_CHECK} accessibility dbus gif jpeg png qt3support ssl zlib"
300 else 308 else
301 KDE4_BUILT_WITH_USE_CHECK="${KDE4_BUILT_WITH_USE_CHECK} 309 KDE4_BUILT_WITH_USE_CHECK=("${KDE4_BUILT_WITH_USE_CHECK[@]}"
302 x11-libs/qt-core qt3support ssl 310 "x11-libs/qt-core qt3support ssl"
303 x11-libs/qt-gui accessibility dbus 311 "x11-libs/qt-gui accessibility dbus"
304 x11-libs/qt-qt3support accessibility" 312 "x11-libs/qt-qt3support accessibility")
305 fi
306
307 if has debug ${IUSE//+} && use debug; then
308 if has_version '<x11-libs/qt-4.4.0_alpha:4'; then
309 QT4_BUILT_WITH_USE_CHECK="${QT4_BUILT_WITH_USE_CHECK} debug"
310 else
311 KDE4_BUILT_WITH_USE_CHECK="${KDE4_BUILT_WITH_USE_CHECK}
312 x11-libs/qt-core:4 debug
313 x11-libs/qt-gui:4 debug
314 x11-libs/qt-qt3support:4 debug
315 x11-libs/qt-svg:4 debug
316 x11-libs/qt-test:4 debug"
317 if has opengl ${IUSE//+} && use opengl || [[ ${OPENGL_REQUIRED} == always ]]; then
318 KDE4_BUILT_WITH_USE_CHECK="${KDE4_BUILT_WITH_USE_CHECK}
319 x11-libs/qt-opengl:4 debug"
320 fi
321 fi
322 fi 313 fi
323 314
324 if has opengl ${IUSE//+} && use opengl || [[ ${OPENGL_REQUIRED} == always ]]; then 315 if has opengl ${IUSE//+} && use opengl || [[ ${OPENGL_REQUIRED} == always ]]; then
325 if has_version '<x11-libs/qt-4.4.0_alpha:4'; then 316 if has_version '<x11-libs/qt-4.4.0_alpha:4'; then
326 QT4_BUILT_WITH_USE_CHECK="${QT4_BUILT_WITH_USE_CHECK} opengl" 317 QT4_BUILT_WITH_USE_CHECK="${QT4_BUILT_WITH_USE_CHECK} opengl"

Legend:
Removed from v.1.10  
changed lines
  Added in v.1.11

  ViewVC Help
Powered by ViewVC 1.1.20