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

Diff of /eclass/kde4-meta.eclass

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

Revision 1.49 Revision 1.50
1# Copyright 1999-2010 Gentoo Foundation 1# Copyright 1999-2010 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-meta.eclass,v 1.49 2011/03/04 23:19:12 dilfridge Exp $ 3# $Header: /var/cvsroot/gentoo-x86/eclass/kde4-meta.eclass,v 1.50 2011/03/11 19:50:52 dilfridge Exp $
4# 4#
5# @ECLASS: kde4-meta.eclass 5# @ECLASS: kde4-meta.eclass
6# @MAINTAINER: 6# @MAINTAINER:
7# kde@gentoo.org 7# kde@gentoo.org
8# @BLURB: Eclass for writing "split" KDE packages. 8# @BLURB: Eclass for writing "split" KDE packages.
10# This eclass provides all necessary functions for writing split KDE ebuilds. 10# This eclass provides all necessary functions for writing split KDE ebuilds.
11# 11#
12# You must define KMNAME to use this eclass, and do so before inheriting it. All other variables are optional. 12# You must define KMNAME to use this eclass, and do so before inheriting it. All other variables are optional.
13# Do not include the same item in more than one of KMMODULE, KMMEXTRA, KMCOMPILEONLY, KMEXTRACTONLY. 13# Do not include the same item in more than one of KMMODULE, KMMEXTRA, KMCOMPILEONLY, KMEXTRACTONLY.
14 14
15inherit kde4-base versionator 15inherit kde4-base toolchain-funcs versionator
16 16
17case ${EAPI:-0} in
18 3)
17EXPORT_FUNCTIONS pkg_setup src_unpack src_prepare src_configure src_compile src_test src_install pkg_postinst pkg_postrm 19 KDEMETA_EXPF="pkg_setup src_unpack src_prepare src_configure src_compile src_test src_install pkg_postinst pkg_postrm"
20 ;;
21 *)
22 KDEMETA_EXPF="pkg_pretend pkg_setup src_unpack src_prepare src_configure src_compile src_test src_install pkg_postinst pkg_postrm"
23 ;;
24esac
25EXPORT_FUNCTIONS ${KDEMETA_EXPF}
18 26
19[[ -z ${KMNAME} ]] && die "kde4-meta.eclass inherited but KMNAME not defined - broken ebuild" 27[[ -z ${KMNAME} ]] && die "kde4-meta.eclass inherited but KMNAME not defined - broken ebuild"
20 28
21# Add dependencies that all packages in a certain module share. 29# Add dependencies that all packages in a certain module share.
22case ${KMNAME} in 30case ${KMNAME} in
125# @ECLASS-VARIABLE: KMTARPARAMS 133# @ECLASS-VARIABLE: KMTARPARAMS
126# @DESCRIPTION: 134# @DESCRIPTION:
127# Specify extra parameters to pass to tar, in kde4-meta_src_extract. 135# Specify extra parameters to pass to tar, in kde4-meta_src_extract.
128# '-xpf -j' are passed to tar by default. 136# '-xpf -j' are passed to tar by default.
129 137
138# @FUNCTION: kde4-meta_pkg_pretend
139# @DESCRIPTION:
140# Currently only checks the gcc version.
141kde4-meta_pkg_pretend() {
142 debug-print-function ${FUNCNAME} "$@"
143
144 slot_is_at_least 4.6 ${SLOT} && ( [[ $(gcc-major-version) -lt 4 ]] || \
145 ( [[ $(gcc-major-version) -eq 4 ]] && [[ $(gcc-minor-version) -le 3 ]] ) ) \
146 && die "Sorry, but gcc-4.3 and earlier wont work for KDE SC 4.6 (see bug 354837)."
147}
148
130# @FUNCTION: kde4-meta_pkg_setup 149# @FUNCTION: kde4-meta_pkg_setup
131# @DESCRIPTION: 150# @DESCRIPTION:
132# Currently just calls its equivalent in kde4-base.eclass(5). Use this one in 151# Currently calls its equivalent in kde4-base.eclass(5) and checks the gcc version.
133# split ebuilds. 152# Use this one in split ebuilds.
134kde4-meta_pkg_setup() { 153kde4-meta_pkg_setup() {
135 debug-print-function ${FUNCNAME} "$@" 154 debug-print-function ${FUNCNAME} "$@"
155
156 has pkg_pretend ${KDEMETA_EXPF} || kde4-meta_pkg_pretend
136 157
137 kde4-base_pkg_setup 158 kde4-base_pkg_setup
138} 159}
139 160
140# @FUNCTION: kde4-meta_src_unpack 161# @FUNCTION: kde4-meta_src_unpack

Legend:
Removed from v.1.49  
changed lines
  Added in v.1.50

  ViewVC Help
Powered by ViewVC 1.1.20