public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
From: "Zac Medico" <zmedico@gentoo.org>
To: gentoo-commits@lists.gentoo.org
Subject: [gentoo-commits] proj/portage:master commit in: pym/portage/, pym/portage/util/
Date: Sun, 11 Dec 2011 06:41:11 +0000 (UTC)	[thread overview]
Message-ID: <da0831b24be79e008939f8507f9d457367e533ee.zmedico@gentoo> (raw)

commit:     da0831b24be79e008939f8507f9d457367e533ee
Author:     Zac Medico <zmedico <AT> gentoo <DOT> org>
AuthorDate: Sun Dec 11 06:41:01 2011 +0000
Commit:     Zac Medico <zmedico <AT> gentoo <DOT> org>
CommitDate: Sun Dec 11 06:41:01 2011 +0000
URL:        http://git.overlays.gentoo.org/gitweb/?p=proj/portage.git;a=commit;h=da0831b2

Add _ENABLE_XATTR constant for the stable branch.

---
 pym/portage/const.py         |    6 ++++++
 pym/portage/util/movefile.py |    4 ++--
 2 files changed, 8 insertions(+), 2 deletions(-)

diff --git a/pym/portage/const.py b/pym/portage/const.py
index 5c738e4..37abb16 100644
--- a/pym/portage/const.py
+++ b/pym/portage/const.py
@@ -164,6 +164,7 @@ _ENABLE_DYN_LINK_MAP    = True
 _ENABLE_PRESERVE_LIBS   = True
 _ENABLE_REPO_NAME_WARN  = True
 _ENABLE_SET_CONFIG      = True
+_ENABLE_XATTR           = True
 _SANDBOX_COMPAT_LEVEL   = "22"
 
 
@@ -177,3 +178,8 @@ if not _ENABLE_PRESERVE_LIBS:
 
 if not _ENABLE_SET_CONFIG:
 	WORLD_SETS_FILE = '/dev/null'
+
+if not _ENABLE_XATTR:
+	SUPPORTED_FEATURES = set(SUPPORTED_FEATURES)
+	SUPPORTED_FEATURES.remove("xattr")
+	SUPPORTED_FEATURES = frozenset(SUPPORTED_FEATURES)

diff --git a/pym/portage/util/movefile.py b/pym/portage/util/movefile.py
index 476f8e7..9834c5a 100644
--- a/pym/portage/util/movefile.py
+++ b/pym/portage/util/movefile.py
@@ -13,7 +13,7 @@ import portage
 from portage import bsd_chflags, _encodings, _os_overrides, _selinux, \
 	_unicode_decode, _unicode_encode, _unicode_func_wrapper,\
 	_unicode_module_wrapper
-from portage.const import MOVE_BINARY
+from portage.const import MOVE_BINARY, _ENABLE_XATTR
 from portage.exception import OperationNotSupported
 from portage.localization import _
 from portage.process import spawn
@@ -85,7 +85,7 @@ def movefile(src, dest, newmtime=None, sstat=None, mysettings=None,
 		mysettings = portage.settings
 
 	src_bytes = _unicode_encode(src, encoding=encoding, errors='strict')
-	xattr_enabled = "xattr" in mysettings.features
+	xattr_enabled = _ENABLE_XATTR and "xattr" in mysettings.features
 	selinux_enabled = mysettings.selinux_enabled()
 	if selinux_enabled:
 		selinux = _unicode_module_wrapper(_selinux, encoding=encoding)



             reply	other threads:[~2011-12-11  6:41 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-12-11  6:41 Zac Medico [this message]
  -- strict thread matches above, loose matches on Subject: below --
2013-10-02  9:50 [gentoo-commits] proj/portage:master commit in: pym/portage/, pym/portage/util/ Arfrever Frehtes Taifersar Arahesis
2012-02-04 14:47 Zac Medico
2011-10-02  5:36 Zac Medico
2011-06-04  0:01 Zac Medico

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=da0831b24be79e008939f8507f9d457367e533ee.zmedico@gentoo \
    --to=zmedico@gentoo.org \
    --cc=gentoo-commits@lists.gentoo.org \
    --cc=gentoo-dev@lists.gentoo.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox