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 1RISyx-0005P4-IB for garchives@archives.gentoo.org; Mon, 24 Oct 2011 22:26:59 +0000 Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id E85EBE057F; Mon, 24 Oct 2011 22:26:51 +0000 (UTC) Received: from smtp.gentoo.org (smtp.gentoo.org [140.211.166.183]) by pigeon.gentoo.org (Postfix) with ESMTP id B878EE057F for ; Mon, 24 Oct 2011 22:26:51 +0000 (UTC) Received: from pelican.gentoo.org (unknown [66.219.59.40]) (using TLSv1 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id 39C9B1B400B for ; Mon, 24 Oct 2011 22:26:51 +0000 (UTC) Received: from localhost.localdomain (localhost [127.0.0.1]) by pelican.gentoo.org (Postfix) with ESMTP id 6EA5F80042 for ; Mon, 24 Oct 2011 22:26:50 +0000 (UTC) From: "Zac Medico" To: gentoo-commits@lists.gentoo.org Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Zac Medico" Message-ID: <70467e9cc23395d257a1475fd12a1f159a8e7ced.zmedico@gentoo> Subject: [gentoo-commits] proj/portage:master commit in: pym/portage/package/ebuild/ X-VCS-Repository: proj/portage X-VCS-Files: pym/portage/package/ebuild/doebuild.py X-VCS-Directories: pym/portage/package/ebuild/ X-VCS-Committer: zmedico X-VCS-Committer-Name: Zac Medico X-VCS-Revision: 70467e9cc23395d257a1475fd12a1f159a8e7ced Date: Mon, 24 Oct 2011 22:26:50 +0000 (UTC) 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: X-Archives-Hash: 084523ece4acec90670385769765fac8 commit: 70467e9cc23395d257a1475fd12a1f159a8e7ced Author: Zac Medico gentoo org> AuthorDate: Mon Oct 24 22:26:35 2011 +0000 Commit: Zac Medico gentoo org> CommitDate: Mon Oct 24 22:26:35 2011 +0000 URL: http://git.overlays.gentoo.org/gitweb/?p=3Dproj/portage.git;a= =3Dcommit;h=3D70467e9c doebuid: deprecate redundant "root" parameter --- pym/portage/package/ebuild/doebuild.py | 23 +++++++++++++++++------ 1 files changed, 17 insertions(+), 6 deletions(-) diff --git a/pym/portage/package/ebuild/doebuild.py b/pym/portage/package= /ebuild/doebuild.py index a324af2..a2d2c8c 100644 --- a/pym/portage/package/ebuild/doebuild.py +++ b/pym/portage/package/ebuild/doebuild.py @@ -358,7 +358,7 @@ _doebuild_commands_without_builddir =3D ( 'fetch', 'fetchall', 'help', 'manifest' ) =20 -def doebuild(myebuild, mydo, myroot, mysettings, debug=3D0, listonly=3D0= , +def doebuild(myebuild, mydo, _unused=3DNone, settings=3DNone, debug=3D0,= listonly=3D0, fetchonly=3D0, cleanup=3D0, dbkey=3DNone, use_cache=3D1, fetchall=3D0, = tree=3DNone, mydbapi=3DNone, vartree=3DNone, prev_mtimes=3DNone, fd_pipes=3DNone, returnpid=3DFalse): @@ -370,10 +370,10 @@ def doebuild(myebuild, mydo, myroot, mysettings, de= bug=3D0, listonly=3D0, @type myebuild: String @param mydo: Phase to run @type mydo: String - @param myroot: $ROOT (usually '/', see man make.conf) - @type myroot: String - @param mysettings: Portage Configuration - @type mysettings: instance of portage.config + @param _unused: Deprecated (use settings["ROOT"] instead) + @type _unused: String + @param settings: Portage Configuration + @type settings: instance of portage.config @param debug: Turns on various debug information (eg, debug for spawn) @type debug: Boolean @param listonly: Used to wrap fetch(); passed such that fetch only list= s files required. @@ -416,7 +416,18 @@ def doebuild(myebuild, mydo, myroot, mysettings, deb= ug=3D0, listonly=3D0, Other variables may not be strictly required, many have defaults that a= re set inside of doebuild. =09 """ -=09 + + if settings is None: + raise TypeError("settings parameter is required") + mysettings =3D settings + myroot =3D settings["ROOT"] + + if _unused is not None and _unused !=3D mysettings["ROOT"]: + warnings.warn("The third parameter of the " + "portage.doebuild() is now unused. Use " + "settings['ROOT'] instead.", + DeprecationWarning, stacklevel=3D2) + if not tree: writemsg("Warning: tree not specified to doebuild\n") tree =3D "porttree"