From c601d1f9a746ad4ac1e0fa463046dc15ab3dcd81 Mon Sep 17 00:00:00 2001 From: Fabian Groffen Date: Sun, 13 May 2007 20:52:10 +0000 Subject: [PATCH] Merged from trunk 6522:6530 +------------------------------------------------------------------------+ | 6523 | s:${PORTDIR}:/usr/portage: so that it's not implied that | | zmedico | those variables are automatically relative to ${PORTDIR} | | | when the value of ${PORTDIR} has changed to something | | | other than /usr/portage. Thanks to kerframil for | | | reporting. | |-----------+------------------------------------------------------------| | 6524 | Add TODO note about support for blocks within slots. | | zmedico | Thanks to Brian Harring for reporting. | |-----------+------------------------------------------------------------| | 6525 | Fix the varexpand quotes tests since quotes are no longer | | zmedico | removed by this function. | |-----------+------------------------------------------------------------| | 6527 | tabs -> spaces | | zmedico | | |-----------+------------------------------------------------------------| | 6528 | import dispatch_conf from the new namespace | | zmedico | | |-----------+------------------------------------------------------------| | 6529 | remove old import | | zmedico | | |-----------+------------------------------------------------------------| | 6530 | the profile check is spammy and should be squelched when | | WarnerBro | --quiet is given | +------------------------------------------------------------------------+ svn path=/main/branches/prefix/; revision=6532 --- bin/dispatch-conf | 8 ++++---- bin/ebuild | 1 - cnf/make.conf | 4 ++-- man/make.conf.5 | 4 ++-- pym/emerge/__init__.py | 14 +++++++------- pym/portage/tests/util/test_varExpand.py | 4 ++-- 6 files changed, 17 insertions(+), 18 deletions(-) diff --git a/bin/dispatch-conf b/bin/dispatch-conf index 24aa3804e..1279cf985 100755 --- a/bin/dispatch-conf +++ b/bin/dispatch-conf @@ -13,7 +13,7 @@ # if not hasattr(__builtins__, "set"): - from sets import Set as set + from sets import Set as set from stat import * from random import * @@ -21,11 +21,11 @@ import atexit, commands, os, re, shutil, stat, sys try: import portage except ImportError: - from os import path as osp - sys.path.insert(0, osp.join(osp.dirname(osp.dirname(osp.realpath(__file__))), "pym")) + from os import path as osp + sys.path.insert(0, osp.join(osp.dirname(osp.dirname(osp.realpath(__file__))), "pym")) import portage -import portage.dispatch_conf, portage.const +from portage import dispatch_conf, const from portage.process import find_binary FIND_EXTANT_CONFIGS = "find '%s' %s -iname '._cfg????_%s' ! -iname '.*~' ! -iname '.*.bak'" diff --git a/bin/ebuild b/bin/ebuild index 2d951a55f..48420d78e 100755 --- a/bin/ebuild +++ b/bin/ebuild @@ -38,7 +38,6 @@ if debug and "python-trace" in portage.features: portage.debug.set_trace(True) if portage.settings["NOCOLOR"] in ("yes","true") or not sys.stdout.isatty(): - import output portage.output.nocolor() ebuild = pargs.pop(0) diff --git a/cnf/make.conf b/cnf/make.conf index eb365b6c1..4ed71dd63 100644 --- a/cnf/make.conf +++ b/cnf/make.conf @@ -89,12 +89,12 @@ # it. The entire repository of tarballs for Gentoo is 9G. This is # considerably more than any user will ever download. 2-3G is # a large DISTDIR. -#DISTDIR=${PORTDIR}/distfiles +#DISTDIR=/usr/portage/distfiles # # PKGDIR is the location of binary packages that you can have created # with '--buildpkg' or '-b' while emerging a package. This can get # up to several hundred megs, or even a few gigs. -#PKGDIR=${PORTDIR}/packages +#PKGDIR=/usr/portage/packages # # PORT_LOGDIR is the location where portage will store all the logs it # creates from each individual merge. They are stored as NNNN-$PF.log diff --git a/man/make.conf.5 b/man/make.conf.5 index b0f755c25..fef0c6c9c 100644 --- a/man/make.conf.5 +++ b/man/make.conf.5 @@ -98,7 +98,7 @@ as \fI\-\-target=${CTARGET}\fR only if it is defined. \fBDISTDIR\fR = \fI[path]\fR Defines the location of your local source file repository. .br -Defaults to ${PORTDIR}/distfiles. +Defaults to /usr/portage/distfiles. .TP .B DOC_SYMLINKS_DIR If this variable contains a directory then symlinks to html documentation will @@ -316,7 +316,7 @@ Defaults to false. \fBPKGDIR\fR = \fI[path]\fR Defines the location where created .tbz2 binary packages will be stored. .br -Defaults to ${PORTDIR}/packages. +Defaults to /usr/portage/packages. .TP .B PORT_LOGDIR This variable defines the directory in which per\-ebuild logs are kept. diff --git a/pym/emerge/__init__.py b/pym/emerge/__init__.py index e70ff7c32..7e4d6870a 100644 --- a/pym/emerge/__init__.py +++ b/pym/emerge/__init__.py @@ -1916,10 +1916,10 @@ class depgraph: for cpv in blocked_initial: slot_atom = blocked_slots_initial[cpv] if slot_atom == pslot_atom: - # The parent blocks an initial package in the same - # slot as itself. The merge/nomerge status of neither - # node matters. In any case, this particular block is - # automatically resolved. + # TODO: Support blocks within slots in cases where it + # might make sense. For example, a new version might + # require that the old version be uninstalled at build + # time. continue if parent_static and \ slot_atom not in modified_slots[myroot]: @@ -1943,8 +1943,7 @@ class depgraph: for cpv in blocked_final: slot_atom = blocked_slots_final[cpv] if slot_atom == pslot_atom: - # The parent blocks itself, so the merge order does not - # need to be enforced. + # TODO: Support blocks within slots. continue if parent_static and \ slot_atom not in modified_slots[myroot]: @@ -5418,7 +5417,8 @@ def emerge_main(): if "candy" in settings.features: spinner.update = spinner.update_scroll - portage.deprecated_profile_check() + if not myopts["--quiet"]: + portage.deprecated_profile_check() #Freeze the portdbapi for enhanced performance: for myroot in trees: diff --git a/pym/portage/tests/util/test_varExpand.py b/pym/portage/tests/util/test_varExpand.py index 0a8bf5b11..ee0f573c9 100644 --- a/pym/portage/tests/util/test_varExpand.py +++ b/pym/portage/tests/util/test_varExpand.py @@ -25,7 +25,7 @@ class VarExpandTestCase(TestCase): def testVarExpandDoubleQuotes(self): varDict = { "a":"5" } - tests = [ ("\"${a}\"", "5") ] + tests = [ ("\"${a}\"", "\"5\"") ] for test in tests: result = varexpand( test[0], varDict ) self.failIf( result != test[1], @@ -35,7 +35,7 @@ class VarExpandTestCase(TestCase): def testVarExpandSingleQuotes(self): varDict = { "a":"5" } - tests = [ ("\'${a}\'", "${a}") ] + tests = [ ("\'${a}\'", "\'${a}\'") ] for test in tests: result = varexpand( test[0], varDict ) self.failIf( result != test[1], -- 2.26.2