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 1RZd69-0000K7-Iv for garchives@archives.gentoo.org; Sun, 11 Dec 2011 06:41:21 +0000 Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id E480721C0C6; Sun, 11 Dec 2011 06:41:13 +0000 (UTC) Received: from smtp.gentoo.org (smtp.gentoo.org [140.211.166.183]) by pigeon.gentoo.org (Postfix) with ESMTP id AD2F321C0C6 for ; Sun, 11 Dec 2011 06:41:13 +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 D3C441B400C for ; Sun, 11 Dec 2011 06:41:12 +0000 (UTC) Received: from localhost.localdomain (localhost [127.0.0.1]) by pelican.gentoo.org (Postfix) with ESMTP id E2C4E8004A for ; Sun, 11 Dec 2011 06:41:11 +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: Subject: [gentoo-commits] proj/portage:master commit in: pym/portage/, pym/portage/util/ X-VCS-Repository: proj/portage X-VCS-Files: pym/portage/const.py pym/portage/util/movefile.py X-VCS-Directories: pym/portage/ pym/portage/util/ X-VCS-Committer: zmedico X-VCS-Committer-Name: Zac Medico X-VCS-Revision: da0831b24be79e008939f8507f9d457367e533ee Date: Sun, 11 Dec 2011 06:41:11 +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: 56805eac-7c6f-4def-936d-de6651c6306a X-Archives-Hash: ee3e2457f2901dff1c4805e8a43aa7a3 commit: da0831b24be79e008939f8507f9d457367e533ee Author: Zac Medico gentoo org> AuthorDate: Sun Dec 11 06:41:01 2011 +0000 Commit: Zac Medico gentoo org> CommitDate: Sun Dec 11 06:41:01 2011 +0000 URL: http://git.overlays.gentoo.org/gitweb/?p=3Dproj/portage.git;a= =3Dcommit;h=3Dda0831b2 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 =3D True _ENABLE_PRESERVE_LIBS =3D True _ENABLE_REPO_NAME_WARN =3D True _ENABLE_SET_CONFIG =3D True +_ENABLE_XATTR =3D True _SANDBOX_COMPAT_LEVEL =3D "22" =20 =20 @@ -177,3 +178,8 @@ if not _ENABLE_PRESERVE_LIBS: =20 if not _ENABLE_SET_CONFIG: WORLD_SETS_FILE =3D '/dev/null' + +if not _ENABLE_XATTR: + SUPPORTED_FEATURES =3D set(SUPPORTED_FEATURES) + SUPPORTED_FEATURES.remove("xattr") + SUPPORTED_FEATURES =3D 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=3DNone, sstat=3DNone, = mysettings=3DNone, mysettings =3D portage.settings =20 src_bytes =3D _unicode_encode(src, encoding=3Dencoding, errors=3D'stric= t') - xattr_enabled =3D "xattr" in mysettings.features + xattr_enabled =3D _ENABLE_XATTR and "xattr" in mysettings.features selinux_enabled =3D mysettings.selinux_enabled() if selinux_enabled: selinux =3D _unicode_module_wrapper(_selinux, encoding=3Dencoding)