/[gentoo-x86]/eclass/vdr-plugin.eclass
Gentoo

Diff of /eclass/vdr-plugin.eclass

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

Revision 1.75 Revision 1.79
1# Copyright 1999-2005 Gentoo Foundation 1# Copyright 1999-2012 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/Attic/vdr-plugin.eclass,v 1.75 2011/10/24 19:54:51 hd_brummy Exp $ 3# $Header: /var/cvsroot/gentoo-x86/eclass/Attic/vdr-plugin.eclass,v 1.79 2012/01/15 20:54:56 idl0r Exp $
4# 4
5# @ECLASS: vdr-plugin.eclass
6# @MAINTAINER:
7# vdr@gentoo.org
8# @BLURB: common vdr plugin ebuild functions
9# @DESCRIPTION:
10# Eclass for easing maitenance of vdr plugin ebuilds
11
5# Author: 12# Author:
6# Matthias Schwarzott <zzam@gentoo.org> 13# Matthias Schwarzott <zzam@gentoo.org>
7# Joerg Bornkessel <hd_brummy@gentoo.org> 14# Joerg Bornkessel <hd_brummy@gentoo.org>
8
9# vdr-plugin.eclass
10#
11# eclass to create ebuilds for vdr plugins
12#
13 15
14# Example ebuild (basic version without patching): 16# Example ebuild (basic version without patching):
15# 17#
16# EAPI="2" 18# EAPI="2"
17# inherit vdr-plugin 19# inherit vdr-plugin
66# all patches which ending on diff or patch in this DIR will automatically applied 68# all patches which ending on diff or patch in this DIR will automatically applied
67# 69#
68 70
69inherit base multilib eutils flag-o-matic 71inherit base multilib eutils flag-o-matic
70 72
71if ! has "${EAPI:-0}" 0 1 2 3; then 73if ! has "${EAPI:-0}" 0 1 2 3 4; then
72 die "API of vdr-plugin.eclass in EAPI=\"${EAPI}\" not established" 74 die "API of vdr-plugin.eclass in EAPI=\"${EAPI}\" not established"
73fi 75fi
74 76
75IUSE="" 77IUSE=""
76 78
263plugin_has_gettext() { 265plugin_has_gettext() {
264 [[ -d po ]] 266 [[ -d po ]]
265} 267}
266 268
267vdr_i18n_convert_to_gettext() { 269vdr_i18n_convert_to_gettext() {
270 if has_version ">=media-video/vdr-1.7.22"; then
271 local i18n_tool="${ROOT}/usr/share/vdr/bin/i18n-to-gettext"
272 else
268 local i18n_tool="${ROOT}/usr/share/vdr/bin/i18n-to-gettext.pl" 273 local i18n_tool="${ROOT}/usr/share/vdr/bin/i18n-to-gettext.pl"
274 fi
269 275
270 if [[ ${NO_GETTEXT_HACK} == "1" ]]; then 276 if [[ ${NO_GETTEXT_HACK} == "1" ]]; then
271 ewarn "Conversion to gettext disabled in ebuild" 277 ewarn "Conversion to gettext disabled in ebuild"
272 return 1 278 return 1
273 fi 279 fi
473 eerror "Please report this at bugs.gentoo.org." 479 eerror "Please report this at bugs.gentoo.org."
474 die "vdr-plugin_pkg_setup not called!" 480 die "vdr-plugin_pkg_setup not called!"
475 fi 481 fi
476 if [ -z "$1" ]; then 482 if [ -z "$1" ]; then
477 case "${EAPI:-0}" in 483 case "${EAPI:-0}" in
478 2|3) 484 2|3|4)
479 vdr-plugin_src_util unpack 485 vdr-plugin_src_util unpack
480 ;; 486 ;;
481 *) 487 *)
482 vdr-plugin_src_util all 488 vdr-plugin_src_util all
483 ;; 489 ;;
616 ewarn "emerge --config ${PN} is no longer supported" 622 ewarn "emerge --config ${PN} is no longer supported"
617 vdr-plugin_print_enable_command 623 vdr-plugin_print_enable_command
618} 624}
619 625
620case "${EAPI:-0}" in 626case "${EAPI:-0}" in
621 2|3) 627 2|3|4)
622 EXPORT_FUNCTIONS pkg_setup src_unpack src_prepare src_compile src_install pkg_postinst pkg_postrm pkg_config 628 EXPORT_FUNCTIONS pkg_setup src_unpack src_prepare src_compile src_install pkg_postinst pkg_postrm pkg_config
623 ;; 629 ;;
624 *) 630 *)
625 EXPORT_FUNCTIONS pkg_setup src_unpack src_compile src_install pkg_postinst pkg_postrm pkg_config 631 EXPORT_FUNCTIONS pkg_setup src_unpack src_compile src_install pkg_postinst pkg_postrm pkg_config
626 ;; 632 ;;

Legend:
Removed from v.1.75  
changed lines
  Added in v.1.79

  ViewVC Help
Powered by ViewVC 1.1.20