/[gentoo-x86]/eclass/enlightenment.eclass
Gentoo

Diff of /eclass/enlightenment.eclass

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

Revision 1.83 Revision 1.84
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/enlightenment.eclass,v 1.83 2010/06/19 00:35:11 abcd Exp $ 3# $Header: /var/cvsroot/gentoo-x86/eclass/enlightenment.eclass,v 1.84 2010/08/22 23:31:08 vapier Exp $
4# 4
5# Author: vapier@gentoo.org 5# @ECLASS: enlightenment.eclass
6# @MAINTAINER:
7# enlightenment@gentoo.org
8# @BLURB: simplify enlightenment package management
6 9
7inherit eutils libtool 10inherit eutils libtool
11
12# @ECLASS-VARIABLE: E_PYTHON
13# @DEFAULT_UNSET
14# @DESCRIPTION:
15# if defined, the package is based on Python/distutils
16
17# @ECLASS-VARIABLE: E_CYTHON
18# @DEFAULT_UNSET
19# @DESCRIPTION:
20# if defined, the package is Cython bindings (implies E_PYTHON)
8 21
9# E_STATE's: 22# E_STATE's:
10# release [default] 23# release [default]
11# KEYWORDS arch 24# KEYWORDS arch
12# SRC_URI $P.tar.gz 25# SRC_URI $P.tar.gz
54elif [[ -n ${E_SNAP_DATE} ]] ; then 67elif [[ -n ${E_SNAP_DATE} ]] ; then
55 E_STATE="snap" 68 E_STATE="snap"
56else 69else
57 E_STATE="release" 70 E_STATE="release"
58fi 71fi
72
73# Parse requested python state
74: ${E_PYTHON:=${E_CYTHON}}
75if [[ -n ${E_PYTHON} ]] ; then
76 WANT_AUTOTOOLS="no"
77
78 PYTHON_DEPEND="2:2.4"
79
80 inherit python distutils
81fi
82
59if [[ ${WANT_AUTOTOOLS} == "yes" ]] ; then 83if [[ ${WANT_AUTOTOOLS} == "yes" ]] ; then
60 WANT_AUTOCONF=${E_WANT_AUTOCONF:-latest} 84 WANT_AUTOCONF=${E_WANT_AUTOCONF:-latest}
61 WANT_AUTOMAKE=${E_WANT_AUTOMAKE:-latest} 85 WANT_AUTOMAKE=${E_WANT_AUTOMAKE:-latest}
62 inherit autotools 86 inherit autotools
63fi 87fi
86esac 110esac
87IUSE="nls doc" 111IUSE="nls doc"
88 112
89DEPEND="doc? ( app-doc/doxygen )" 113DEPEND="doc? ( app-doc/doxygen )"
90RDEPEND="nls? ( sys-devel/gettext )" 114RDEPEND="nls? ( sys-devel/gettext )"
91 115[[ -n ${E_PYTHON} ]] && DEPEND+=" >=dev-python/setuptools-0.6_rc9"
92# gettext (via `autopoint`) needs to run cvs #245073 116[[ -n ${E_CYTHON} ]] && DEPEND+=" >=dev-python/cython-0.12.1"
93[[ ${E_STATE} == "live" ]] && DEPEND="${DEPEND} dev-vcs/cvs"
94 117
95case ${EURI_STATE:-${E_STATE}} in 118case ${EURI_STATE:-${E_STATE}} in
96 release) S=${WORKDIR}/${P};; 119 release) S=${WORKDIR}/${P};;
97 snap) S=${WORKDIR}/${P};; 120 snap) S=${WORKDIR}/${P};;
98 live) S=${WORKDIR}/${E_S_APPEND};; 121 live) S=${WORKDIR}/${E_S_APPEND};;
157 econf ${MY_ECONF} 180 econf ${MY_ECONF}
158} 181}
159 182
160enlightenment_src_compile() { 183enlightenment_src_compile() {
161 hasq src_configure ${ENLIGHTENMENT_EXPF} || enlightenment_src_configure 184 hasq src_configure ${ENLIGHTENMENT_EXPF} || enlightenment_src_configure
185
186 if [[ -z ${E_PYTHON} ]] ; then
162 emake || enlightenment_die "emake failed" 187 emake || enlightenment_die "emake failed"
163 use doc && [[ -x ./gendoc ]] && { ./gendoc || enlightenment_die "gendoc failed" ; } 188 else
189 distutils_src_compile
190 fi
191
192 if use doc ; then
193 if [[ -x ./gendoc ]] ; then
194 ./gendoc || enlightenment_die "gendoc failed"
195 else
196 emake doc || enlightenment_die "emake doc failed"
197 fi
198 fi
164} 199}
165 200
166enlightenment_src_install() { 201enlightenment_src_install() {
167 emake install DESTDIR="${D}" || enlightenment_die 202 emake install DESTDIR="${D}" || enlightenment_die
168 find "${D}" '(' -name CVS -o -name .svn -o -name .git ')' -type d -exec rm -rf '{}' \; 2>/dev/null 203 find "${D}" '(' -name CVS -o -name .svn -o -name .git ')' -type d -exec rm -rf '{}' \; 2>/dev/null
173} 208}
174 209
175enlightenment_pkg_postinst() { 210enlightenment_pkg_postinst() {
176 : enlightenment_warning_msg 211 : enlightenment_warning_msg
177} 212}
178

Legend:
Removed from v.1.83  
changed lines
  Added in v.1.84

  ViewVC Help
Powered by ViewVC 1.1.20