Gentoo Archives: gentoo-commits

From: "Tomas Chvatal (scarabeus)" <scarabeus@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] gentoo-x86 commit in eclass: kde4-base.eclass kde4-functions.eclass kde4-meta.eclass
Date: Tue, 01 Dec 2009 10:56:20
Message-Id: E1NFQP4-0004nQ-33@stork.gentoo.org
1 scarabeus 09/12/01 10:56:18
2
3 Modified: kde4-base.eclass kde4-functions.eclass
4 kde4-meta.eclass
5 Log:
6 Update kde4 eclasses from overlay:
7 Changes:
8 kde-functions
9 Update the block resolving case to make it simpler.
10 kde-meta
11 Drop not required elogs.
12 Drop redundant dependencies.
13 kde-base
14 introduce kdeenablefinal useflag (masked).
15 support unpacking of xz tarballs in eapi2.
16
17 Revision Changes Path
18 1.54 eclass/kde4-base.eclass
19
20 file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/eclass/kde4-base.eclass?rev=1.54&view=markup
21 plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/eclass/kde4-base.eclass?rev=1.54&content-type=text/plain
22 diff : http://sources.gentoo.org/viewcvs.py/gentoo-x86/eclass/kde4-base.eclass?r1=1.53&r2=1.54
23
24 Index: kde4-base.eclass
25 ===================================================================
26 RCS file: /var/cvsroot/gentoo-x86/eclass/kde4-base.eclass,v
27 retrieving revision 1.53
28 retrieving revision 1.54
29 diff -u -r1.53 -r1.54
30 --- kde4-base.eclass 25 Nov 2009 19:51:11 -0000 1.53
31 +++ kde4-base.eclass 1 Dec 2009 10:56:17 -0000 1.54
32 @@ -1,6 +1,6 @@
33 # Copyright 1999-2009 Gentoo Foundation
34 # Distributed under the terms of the GNU General Public License v2
35 -# $Header: /var/cvsroot/gentoo-x86/eclass/kde4-base.eclass,v 1.53 2009/11/25 19:51:11 tampakrap Exp $
36 +# $Header: /var/cvsroot/gentoo-x86/eclass/kde4-base.eclass,v 1.54 2009/12/01 10:56:17 scarabeus Exp $
37
38 # @ECLASS: kde4-base.eclass
39 # @MAINTAINER:
40 @@ -19,7 +19,7 @@
41 # Please note that if it's set to 'never' you need to explicitly override following phases:
42 # src_configure, src_compile, src_test and src_install.
43 # Defaults to 'always'.
44 -CMAKE_REQUIRED="${CMAKE_REQUIRED:-${CMAKE_REQUIRED:-always}}"
45 +: ${CMAKE_REQUIRED:=always}
46 if [[ ${CMAKE_REQUIRED} = false || ${CMAKE_REQUIRED} = never ]]; then
47 buildsystem_eclass=""
48 export_fns=""
49 @@ -144,9 +144,9 @@
50 # @DESCRIPTION:
51 # Determine version of qt we enforce as minimal for the package. 4.4.0 4.5.1..
52 # Currently defaults to 4.5.1 for KDE 4.3 and earlier
53 -# or 4.6.0_beta for KDE 4.4 and later
54 +# or 4.6.0_rc1 for KDE 4.4 and later
55 if slot_is_at_least 4.4 "${KDE_MINIMAL}"; then
56 - QT_MINIMAL="${QT_MINIMAL:-4.6.0_beta}"
57 + QT_MINIMAL="${QT_MINIMAL:-4.6.0_rc1}"
58 fi
59
60 QT_MINIMAL="${QT_MINIMAL:-4.5.1}"
61 @@ -239,6 +239,10 @@
62 fi
63 kdedepend="
64 dev-util/pkgconfig
65 + !aqua? (
66 + x11-proto/xextproto
67 + x11-proto/xf86vidmodeproto
68 + )
69 "
70 case ${KDE_REQUIRED} in
71 always)
72 @@ -253,6 +257,7 @@
73 ;;
74 *) ;;
75 esac
76 +
77 unset kdecommondepend kdedepend
78
79 debug-print "${LINENO} ${ECLASS} ${FUNCNAME}: COMMONDEPEND is ${COMMONDEPEND}"
80 @@ -264,6 +269,9 @@
81 RDEPEND+=" ${COMMONDEPEND}"
82 unset COMMONDEPEND
83
84 +# Add experimental kdeenablefinal, disabled by default
85 +IUSE+=" kdeenablefinal"
86 +
87 # Fetch section - If the ebuild's category is not 'kde-base' and if it is not a
88 # koffice ebuild, the URI should be set in the ebuild itself
89 case ${BUILD_TYPE} in
90 @@ -305,7 +313,7 @@
91 kdelibs-*)
92 ESVN_REPO_URI="${ESVN_MIRROR}/${branch_prefix}/kdelibs/${KMNAME#kdelibs-}"
93 ;;
94 - kdereview)
95 + kdereview*)
96 ESVN_REPO_URI="${ESVN_MIRROR}/trunk/${KMNAME}/${KMMODULE}"
97 ;;
98 kdesupport)
99 @@ -360,7 +368,10 @@
100 # block for normally packed unstable releases
101 SRC_URI="mirror://kde/unstable/${PV}/src/${_kmname_pv}.tar.bz2" ;;
102 4.3.[6-9]*)
103 - SRC_URI="http://dev.gentooexperimental.org/~alexxy/kde/${PV}/${_kmname_pv}.tar.lzma" ;;
104 + # Repacked tarballs: need to depend on xz-utils to ensure that they can be unpacked
105 + SRC_URI="http://dev.gentooexperimental.org/~alexxy/kde/${PV}/${_kmname_pv}.tar.xz"
106 + DEPEND+=" app-arch/xz-utils"
107 + ;;
108 *) SRC_URI="mirror://kde/stable/${PV}/src/${_kmname_pv}.tar.bz2" ;;
109 esac
110 ;;
111 @@ -454,8 +465,25 @@
112 if [[ ${BUILD_TYPE} = live ]]; then
113 migrate_store_dir
114 subversion_src_unpack
115 + elif [[ ${EAPI} == 2 ]]; then
116 + local file
117 + for file in ${A}; do
118 + # This setup is because EAPI <= 2 cannot unpack *.tar.xz files
119 + # directly, so we do it ourselves (using the exact same code as portage)
120 + case ${file} in
121 + *.tar.xz)
122 + echo ">>> Unpacking ${file} to ${PWD}"
123 + xz -dc "${DISTDIR}"/${file} | tar xof -
124 + assert "failed unpacking ${file}"
125 + ;;
126 + *)
127 + unpack ${file}
128 + ;;
129 + esac
130 + done
131 else
132 - base_src_unpack
133 + # For EAPI >= 3, we can just use unpack() directly
134 + unpack ${A}
135 fi
136 }
137
138 @@ -500,17 +528,19 @@
139 kde4-base_src_configure() {
140 debug-print-function ${FUNCNAME} "$@"
141
142 - # Handle common release builds
143 - if ! has debug ${IUSE//+} || ! use debug; then
144 - append-cppflags -DQT_NO_DEBUG
145 - fi
146 -
147 # Build tests in src_test only, where we override this value
148 local cmakeargs="-DKDE4_BUILD_TESTS=OFF"
149
150 - # set "real" debug mode
151 + if has kdeenablefinal ${IUSE//+} && use kdeenablefinal; then
152 + cmakeargs+=" -DKDE4_ENABLE_FINAL=ON"
153 + fi
154 +
155 if has debug ${IUSE//+} && use debug; then
156 + # Set "real" debug mode
157 CMAKE_BUILD_TYPE="Debugfull"
158 + else
159 + # Handle common release builds
160 + append-cppflags -DQT_NO_DEBUG
161 fi
162
163 # Set distribution name
164
165
166
167 1.27 eclass/kde4-functions.eclass
168
169 file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/eclass/kde4-functions.eclass?rev=1.27&view=markup
170 plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/eclass/kde4-functions.eclass?rev=1.27&content-type=text/plain
171 diff : http://sources.gentoo.org/viewcvs.py/gentoo-x86/eclass/kde4-functions.eclass?r1=1.26&r2=1.27
172
173 Index: kde4-functions.eclass
174 ===================================================================
175 RCS file: /var/cvsroot/gentoo-x86/eclass/kde4-functions.eclass,v
176 retrieving revision 1.26
177 retrieving revision 1.27
178 diff -u -r1.26 -r1.27
179 --- kde4-functions.eclass 27 Oct 2009 14:16:49 -0000 1.26
180 +++ kde4-functions.eclass 1 Dec 2009 10:56:17 -0000 1.27
181 @@ -1,6 +1,6 @@
182 # Copyright 1999-2009 Gentoo Foundation
183 # Distributed under the terms of the GNU General Public License v2
184 -# $Header: /var/cvsroot/gentoo-x86/eclass/kde4-functions.eclass,v 1.26 2009/10/27 14:16:49 scarabeus Exp $
185 +# $Header: /var/cvsroot/gentoo-x86/eclass/kde4-functions.eclass,v 1.27 2009/12/01 10:56:17 scarabeus Exp $
186
187 inherit versionator
188
189 @@ -378,8 +378,7 @@
190 # will add the following to RDEPEND:
191 # !kdeprefix? ( !kde-base/kdelibs:4.3[-kdeprefix] )
192 # !kdeprefix? ( !<kde-base/kdelibs-4.3.96:4.4[-kdeprefix] )
193 -# !kdeprefix? ( !<=kde-base/kdelibs-9999:live[-kdeprefix] )
194 -# kdeprefix? ( !<=kde-base/kdelibs-9999:live[kdeprefix] )
195 +# !<=kde-base/kdelibs-9999:live
196 add_blocker() {
197 debug-print-function ${FUNCNAME} "$@"
198
199 @@ -399,7 +398,7 @@
200 local test=${slot}.50
201 version_compare $1 ${test}
202 # 1 = '<', 2 = '=', 3 = '>'
203 - [[ $? -ne 1 ]]
204 + (( $? != 1 ))
205 }
206
207 # _less_min_in_slot ver slot
208 @@ -411,10 +410,10 @@
209 # If slot == live, then test with "9999_pre", so that 9999 tests false
210 local test=9999_pre
211 # If slot == X.Y, then test with X.(Y-1).50
212 - [[ $slot == live ]] || test=${slot%.*}.$((${slot#*.} - 1)).50
213 + [[ $slot != live ]] && test=${slot%.*}.$((${slot#*.} - 1)).50
214 version_compare $1 ${test}
215 # 1 = '<', 2 = '=', 3 = '>'
216 - [[ $? -ne 3 ]]
217 + (( $? != 3 ))
218 }
219
220 # Internal function used for add_blocker and block_other_slots
221 @@ -474,11 +473,12 @@
222 else
223 atom="<=${pkg}-${!var}"
224 fi
225 - # on -kdeprefix we block every slot
226 - echo " !kdeprefix? ( !${atom}:${slot}[-kdeprefix] )"
227 - # on kdeprefix we block only our slot
228 + # we always block our own slot, ignoring kdeprefix
229 if [[ ${SLOT} == ${slot} ]]; then
230 - echo " kdeprefix? ( !${atom}:${SLOT}[kdeprefix] )"
231 + echo " !${atom}:${slot}"
232 + else
233 + # we only block other slots on -kdeprefix
234 + echo " !kdeprefix? ( !${atom}:${slot}[-kdeprefix] )"
235 fi
236 done
237
238 @@ -514,6 +514,6 @@
239
240 local use=${2:+,${2}}
241
242 - echo "!kdeprefix? ( >=kde-base/${1}-${PV}[-kdeprefix${use}] )"
243 - echo "kdeprefix? ( >=kde-base/${1}-${PV}:${SLOT}[kdeprefix${use}] )"
244 + echo " !kdeprefix? ( >=kde-base/${1}-${PV}[-kdeprefix${use}] )"
245 + echo " kdeprefix? ( >=kde-base/${1}-${PV}:${SLOT}[kdeprefix${use}] )"
246 }
247
248
249
250 1.28 eclass/kde4-meta.eclass
251
252 file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/eclass/kde4-meta.eclass?rev=1.28&view=markup
253 plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/eclass/kde4-meta.eclass?rev=1.28&content-type=text/plain
254 diff : http://sources.gentoo.org/viewcvs.py/gentoo-x86/eclass/kde4-meta.eclass?r1=1.27&r2=1.28
255
256 Index: kde4-meta.eclass
257 ===================================================================
258 RCS file: /var/cvsroot/gentoo-x86/eclass/kde4-meta.eclass,v
259 retrieving revision 1.27
260 retrieving revision 1.28
261 diff -u -r1.27 -r1.28
262 --- kde4-meta.eclass 27 Oct 2009 14:16:49 -0000 1.27
263 +++ kde4-meta.eclass 1 Dec 2009 10:56:17 -0000 1.28
264 @@ -1,6 +1,6 @@
265 # Copyright 1999-2009 Gentoo Foundation
266 # Distributed under the terms of the GNU General Public License v2
267 -# $Header: /var/cvsroot/gentoo-x86/eclass/kde4-meta.eclass,v 1.27 2009/10/27 14:16:49 scarabeus Exp $
268 +# $Header: /var/cvsroot/gentoo-x86/eclass/kde4-meta.eclass,v 1.28 2009/12/01 10:56:17 scarabeus Exp $
269 #
270 # @ECLASS: kde4-meta.eclass
271 # @MAINTAINER:
272 @@ -20,21 +20,13 @@
273 die "kde4-meta.eclass inherited but KMNAME not defined - broken ebuild"
274 fi
275
276 -# Add khelpcenter dependency when installing handbooks
277 -if [[ ${PN} != khelpcenter ]] && has handbook ${IUSE//+}; then
278 - RDEPEND+=" handbook? ( $(add_kdebase_dep khelpcenter) )"
279 -fi
280 -
281 # Add dependencies that all packages in a certain module share.
282 case ${KMNAME} in
283 kdebase|kdebase-apps|kdebase-workspace|kdebase-runtime|kdegraphics)
284 COMMONDEPEND+=" >=kde-base/qimageblitz-0.0.4"
285 ;;
286 kdepim|kdepim-runtime)
287 - COMMONDEPEND+="
288 - dev-libs/boost
289 - $(add_kdebase_dep kdepimlibs)
290 - "
291 + COMMONDEPEND+=" $(add_kdebase_dep kdepimlibs)"
292 case ${PN} in
293 akregator|kaddressbook|kjots|kmail|knode|knotes|korganizer|ktimetracker)
294 IUSE+=" +kontact"
295 @@ -222,8 +214,9 @@
296 postfix="bz2"
297 ;;
298 4.3.[6-9]*)
299 - KMTARPARAMS+=" --lzma" # lzma
300 - postfix="lzma"
301 + # Not passing --xz, as it doesn't work with stable tar
302 + KMTARPARAMS+=" --use-compress-program=xz" # xz
303 + postfix="xz"
304 ;;
305 *)
306 KMTARPARAMS+=" --bzip2" # bz2
307 @@ -700,17 +693,10 @@
308
309 # @FUNCTION: kde4-meta_pkg_postinst
310 # @DESCRIPTION:
311 -# Display information about application handbook and invoke kbuildsycoca4.
312 +# Invoke kbuildsycoca4.
313 kde4-meta_pkg_postinst() {
314 debug-print-function ${FUNCNAME} "$@"
315
316 - if has handbook ${IUSE//+} && ! use handbook; then
317 - echo
318 - einfo "Application handbook for ${PN} has not been installed."
319 - einfo "To install handbook, reemerge =${CATEGORY}/${PF} with 'handbook' USE flag."
320 - echo
321 - fi
322 -
323 kde4-base_pkg_postinst
324 }