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

Diff of /eclass/kde4-functions.eclass

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

Revision 1.27 Revision 1.28
1# Copyright 1999-2009 Gentoo Foundation 1# Copyright 1999-2009 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-functions.eclass,v 1.27 2009/12/01 10:56:17 scarabeus Exp $ 3# $Header: /var/cvsroot/gentoo-x86/eclass/kde4-functions.eclass,v 1.28 2009/12/10 17:35:52 abcd Exp $
4 4
5inherit versionator 5inherit versionator
6 6
7# @ECLASS: kde4-functions.eclass 7# @ECLASS: kde4-functions.eclass
8# @MAINTAINER: 8# @MAINTAINER:
15# @ECLASS-VARIABLE: EAPI 15# @ECLASS-VARIABLE: EAPI
16# @DESCRIPTION: 16# @DESCRIPTION:
17# By default kde4 eclasses want EAPI 2 which might be redefinable to newer 17# By default kde4 eclasses want EAPI 2 which might be redefinable to newer
18# versions. 18# versions.
19case ${EAPI:-0} in 19case ${EAPI:-0} in
20 2) : ;; 20 2|3) : ;;
21 *) DEPEND="EAPI-TOO-OLD" ;; 21 *) DEPEND="EAPI-TOO-OLD" ;;
22esac 22esac
23 23
24# @ECLASS-VARIABLE: KDEBASE 24# @ECLASS-VARIABLE: KDEBASE
25# @DESCRIPTION: 25# @DESCRIPTION:
62# @DESCRIPTION: 62# @DESCRIPTION:
63# Function to rebuild the KDE System Configuration Cache. 63# Function to rebuild the KDE System Configuration Cache.
64# All KDE ebuilds should run this in pkg_postinst and pkg_postrm. 64# All KDE ebuilds should run this in pkg_postinst and pkg_postrm.
65buildsycoca() { 65buildsycoca() {
66 debug-print-function ${FUNCNAME} "$@" 66 debug-print-function ${FUNCNAME} "$@"
67
68 [[ -z ${EROOT} ]] && EROOT=${ROOT}${EPREFIX}
67 69
68 local KDE3DIR="${EROOT}usr/kde/3.5" 70 local KDE3DIR="${EROOT}usr/kde/3.5"
69 if [[ -z ${EROOT%%/} && -x "${KDE3DIR}"/bin/kbuildsycoca ]]; then 71 if [[ -z ${EROOT%%/} && -x "${KDE3DIR}"/bin/kbuildsycoca ]]; then
70 # Since KDE3 is aware of shortcuts in /usr, rebuild database 72 # Since KDE3 is aware of shortcuts in /usr, rebuild database
71 # for KDE3 as well. 73 # for KDE3 as well.
318# Install generated CMake library dependencies to /var/lib/kde 320# Install generated CMake library dependencies to /var/lib/kde
319install_library_dependencies() { 321install_library_dependencies() {
320 local depsfile="${T}/${PN}:${SLOT}" 322 local depsfile="${T}/${PN}:${SLOT}"
321 323
322 ebegin "Installing library dependencies as ${depsfile##*/}" 324 ebegin "Installing library dependencies as ${depsfile##*/}"
323 insinto ${EROOT}var/lib/kde 325 insinto /var/lib/kde
324 doins "${depsfile}" || die "Failed to install library dependencies." 326 doins "${depsfile}" || die "Failed to install library dependencies."
325 eend $? 327 eend $?
326} 328}
327 329
328# @FUNCTION: load_library_dependencies 330# @FUNCTION: load_library_dependencies
333 ebegin "Injecting library dependencies from '${KMLOADLIBS}'" 335 ebegin "Injecting library dependencies from '${KMLOADLIBS}'"
334 336
335 i=0 337 i=0
336 for pn in ${KMLOADLIBS} ; do 338 for pn in ${KMLOADLIBS} ; do
337 ((i++)) 339 ((i++))
338 depsfile="${EROOT}var/lib/kde/${pn}:${SLOT}" 340 depsfile="${EPREFIX}/var/lib/kde/${pn}:${SLOT}"
339 [[ -r "${depsfile}" ]] || die "Depsfile '${depsfile}' not accessible. You probably need to reinstall ${pn}." 341 [[ -r "${depsfile}" ]] || die "Depsfile '${depsfile}' not accessible. You probably need to reinstall ${pn}."
340 sed -i -e "${i}iINCLUDE(\"${depsfile}\")" "${S}/CMakeLists.txt" || \ 342 sed -i -e "${i}iINCLUDE(\"${depsfile}\")" "${S}/CMakeLists.txt" || \
341 die "Failed to include library dependencies for ${pn}" 343 die "Failed to include library dependencies for ${pn}"
342 done 344 done
343 eend $? 345 eend $?

Legend:
Removed from v.1.27  
changed lines
  Added in v.1.28

  ViewVC Help
Powered by ViewVC 1.1.20