From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from pigeon.gentoo.org ([208.92.234.80] helo=lists.gentoo.org) by finch.gentoo.org with esmtp (Exim 4.60) (envelope-from ) id 1Mz9ZE-0005hb-Vq for garchives@archives.gentoo.org; Sat, 17 Oct 2009 13:43:33 +0000 Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id DABD2E05D7; Sat, 17 Oct 2009 13:43:31 +0000 (UTC) Received: from smtp.gentoo.org (smtp.gentoo.org [140.211.166.183]) by pigeon.gentoo.org (Postfix) with ESMTP id 92EE4E05D7 for ; Sat, 17 Oct 2009 13:43:31 +0000 (UTC) Received: from stork.gentoo.org (stork.gentoo.org [64.127.104.133]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTP id 32BBA673AB for ; Sat, 17 Oct 2009 13:43:31 +0000 (UTC) Received: from lack by stork.gentoo.org with local (Exim 4.69) (envelope-from ) id 1Mz9ZC-0001FH-KM for gentoo-commits@lists.gentoo.org; Sat, 17 Oct 2009 13:43:30 +0000 From: "Jim Ramsay (lack)" To: gentoo-commits@lists.gentoo.org Reply-To: gentoo-dev@lists.gentoo.org, lack@gentoo.org Subject: [gentoo-commits] gentoo-x86 commit in eclass: vim.eclass X-VCS-Repository: gentoo-x86 X-VCS-Files: vim.eclass X-VCS-Directories: eclass X-VCS-Committer: lack X-VCS-Committer-Name: Jim Ramsay Content-Type: text/plain; charset=utf8 Message-Id: Sender: Jim Ramsay Date: Sat, 17 Oct 2009 13:43:30 +0000 Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: quoted-printable X-Archives-Salt: 50e97f6d-13c4-44c1-8fe8-a73f3dab48f9 X-Archives-Hash: d8aacd222be4e85e2b8b4d2d404ce380 lack 09/10/17 13:43:30 Modified: vim.eclass Log: Add dependency on python[threads] (Bug #228099) =20 This includes some EAPI-aware code (finally) Revision Changes Path 1.177 eclass/vim.eclass file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/eclass/vim.eclass?= rev=3D1.177&view=3Dmarkup plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/eclass/vim.eclass?= rev=3D1.177&content-type=3Dtext/plain diff : http://sources.gentoo.org/viewcvs.py/gentoo-x86/eclass/vim.eclass?= r1=3D1.176&r2=3D1.177 Index: vim.eclass =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D RCS file: /var/cvsroot/gentoo-x86/eclass/vim.eclass,v retrieving revision 1.176 retrieving revision 1.177 diff -u -r1.176 -r1.177 --- vim.eclass 14 Oct 2009 01:29:49 -0000 1.176 +++ vim.eclass 17 Oct 2009 13:43:30 -0000 1.177 @@ -1,6 +1,6 @@ # Copyright 1999-2007 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/eclass/vim.eclass,v 1.176 2009/10/14 = 01:29:49 lack Exp $ +# $Header: /var/cvsroot/gentoo-x86/eclass/vim.eclass,v 1.177 2009/10/17 = 13:43:30 lack Exp $ =20 # Authors: # Jim Ramsay @@ -24,6 +24,15 @@ =20 inherit eutils vim-doc flag-o-matic versionator fdo-mime =20 +# Check for EAPI functions we need: +case "${EAPI:-0}" in + 2) + HAS_SRC_PREPARE=3D1 + HAS_USE_DEP=3D1 + ;; + *) ;; +esac + # Support -cvs ebuilds, even though they're not in the official tree. MY_PN=3D${PN%-cvs} =20 @@ -44,7 +53,13 @@ inherit bash-completion fi =20 -EXPORT_FUNCTIONS pkg_setup src_unpack src_compile src_install src_test p= kg_postinst pkg_postrm +TO_EXPORT=3D"pkg_setup src_compile src_install src_test pkg_postinst pkg= _postrm" +if [[ $HAS_SRC_PREPARE ]]; then + TO_EXPORT=3D"${TO_EXPORT} src_prepare" +else + TO_EXPORT=3D"${TO_EXPORT} src_unpack" +fi +EXPORT_FUNCTIONS ${TO_EXPORT} =20 if version_is_at_least 6.4_beta ; then IUSE=3D"${IUSE} nls acl" @@ -59,20 +74,27 @@ IUSE=3D"${IUSE} livecd" else IUSE=3D"${IUSE} cscope gpm perl python ruby" + + if [[ $HAS_USE_DEP ]]; then + PYTHON_DEP=3D"python? ( dev-lang/python[threads] )" + else + PYTHON_DEP=3D"python? ( dev-lang/python )" + fi + DEPEND=3D"${DEPEND} cscope? ( dev-util/cscope ) gpm? ( >=3Dsys-libs/gpm-1.19.3 ) perl? ( dev-lang/perl ) - python? ( dev-lang/python ) acl? ( kernel_linux? ( sys-apps/acl ) ) - ruby? ( virtual/ruby )" + ruby? ( virtual/ruby ) + ${PYTHON_DEP}" RDEPEND=3D"${RDEPEND} cscope? ( dev-util/cscope ) gpm? ( >=3Dsys-libs/gpm-1.19.3 ) perl? ( dev-lang/perl ) - python? ( dev-lang/python ) acl? ( kernel_linux? ( sys-apps/acl ) ) - ruby? ( virtual/ruby )" + ruby? ( virtual/ruby ) + ${PYTHON_DEP}" =20 if ! version_is_at_least 6.4_beta ; then DEPEND=3D"${DEPEND} selinux? ( sys-libs/libselinux )" @@ -238,11 +260,14 @@ # Gnome sandbox silliness. bug #114475. mkdir -p "${T}/home" export HOME=3D"${T}/home" -} =20 -vim_src_unpack() { - unpack ${A} + # Need python[threads] + if use python && ! built_with_use dev-lang/python threads; then + die "You must build dev-lang/python with USE=3Dthreads" + fi +} =20 +vim_src_prepare() { if [[ ${PN##*-} =3D=3D cvs ]] ; then ECVS_SERVER=3D"vim.cvs.sourceforge.net:/cvsroot/vim" ECVS_PASS=3D"" @@ -339,6 +364,11 @@ fi } =20 +vim_src_unpack() { + unpack ${A} + vim_src_prepare +} + vim_src_compile() { local myconf confrule =20