From: Zac Medico Date: Sun, 2 Jun 2013 22:42:38 +0000 (-0700) Subject: treewalk: skip CHOST warning for binary packages X-Git-Tag: v2.2.0_alpha178~4 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=076c6637583328dc814828e1d10affb4e2666368;p=portage.git treewalk: skip CHOST warning for binary packages The CHOST of a binary package does not necessarily match the make.conf setting, especially if ACCEPT_CHOSTS is configured to match other CHOST values. --- diff --git a/pym/portage/dbapi/vartree.py b/pym/portage/dbapi/vartree.py index c6eaabfc0..e1a4753ce 100644 --- a/pym/portage/dbapi/vartree.py +++ b/pym/portage/dbapi/vartree.py @@ -3555,6 +3555,7 @@ class dblink(object): level=logging.ERROR, noiselevel=-1) return 1 + is_binpkg = self.settings.get("EMERGE_FROM") == "binary" slot = '' for var_name in ('CHOST', 'SLOT'): if var_name == 'CHOST' and self.cat == 'virtual': @@ -3588,7 +3589,9 @@ class dblink(object): return 1 write_atomic(os.path.join(inforoot, var_name), slot + '\n') - if val != self.settings.get(var_name, ''): + # This check only applies when built from source, since + # inforoot values are written just after src_install. + if not is_binpkg and val != self.settings.get(var_name, ''): self._eqawarn('preinst', [_("QA Notice: Expected %(var_name)s='%(expected_value)s', got '%(actual_value)s'\n") % \ {"var_name":var_name, "expected_value":self.settings.get(var_name, ''), "actual_value":val}])