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 1SFpol-0001Zp-QA for garchives@archives.gentoo.org; Thu, 05 Apr 2012 16:45:51 +0000 Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 8D82FE0D10; Thu, 5 Apr 2012 16:45:36 +0000 (UTC) Received: from smtp.gentoo.org (smtp.gentoo.org [140.211.166.183]) by pigeon.gentoo.org (Postfix) with ESMTP id 5F63EE0D10 for ; Thu, 5 Apr 2012 16:45:36 +0000 (UTC) Received: from hornbill.gentoo.org (hornbill.gentoo.org [94.100.119.163]) (using TLSv1 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id A55D11B4030 for ; Thu, 5 Apr 2012 16:45:35 +0000 (UTC) Received: from localhost.localdomain (localhost [127.0.0.1]) by hornbill.gentoo.org (Postfix) with ESMTP id 668F3E5403 for ; Thu, 5 Apr 2012 16:45:34 +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: <1333644055.42694ba42b4d265a07e91bc0aef98dbfa7ad2c4f.zmedico@gentoo> Subject: [gentoo-commits] proj/portage:master commit in: bin/ X-VCS-Repository: proj/portage X-VCS-Files: bin/misc-functions.sh X-VCS-Directories: bin/ X-VCS-Committer: zmedico X-VCS-Committer-Name: Zac Medico X-VCS-Revision: 42694ba42b4d265a07e91bc0aef98dbfa7ad2c4f X-VCS-Branch: master Date: Thu, 5 Apr 2012 16:45:34 +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: de34316e-283f-407c-a70d-b85afd915e66 X-Archives-Hash: 72c243db85b7fcafdc7b9c858ae45a03 commit: 42694ba42b4d265a07e91bc0aef98dbfa7ad2c4f Author: Sven Vermeulen gentoo org> AuthorDate: Thu Apr 5 16:40:55 2012 +0000 Commit: Zac Medico gentoo org> CommitDate: Thu Apr 5 16:40:55 2012 +0000 URL: http://git.overlays.gentoo.org/gitweb/?p=3Dproj/portage.git;a= =3Dcommit;h=3D42694ba4 Support /sys/fs/selinux/context for bug #410687. --- bin/misc-functions.sh | 6 ++++-- 1 files changed, 4 insertions(+), 2 deletions(-) diff --git a/bin/misc-functions.sh b/bin/misc-functions.sh index b083897..4e81ddf 100755 --- a/bin/misc-functions.sh +++ b/bin/misc-functions.sh @@ -1095,13 +1095,15 @@ preinst_selinux_labels() { # SELinux file labeling (needs to always be last in dyn_preinst) # only attempt to label if setfiles is executable # and 'context' is available on selinuxfs. - if [ -f /selinux/context -a -x /usr/sbin/setfiles -a -x /usr/sbin/seli= nuxconfig ]; then + if [ -f /selinux/context -o -f /sys/fs/selinux/context ] && \ + [ -x /usr/sbin/setfiles -a -x /usr/sbin/selinuxconfig ]; then vecho ">>> Setting SELinux security labels" ( eval "$(/usr/sbin/selinuxconfig)" || \ die "Failed to determine SELinux policy paths."; =09 - addwrite /selinux/context; + addwrite /selinux/context + addwrite /sys/fs/selinux/context =09 /usr/sbin/setfiles "${file_contexts_path}" -r "${D}" "${D}" ) || die "Failed to set SELinux security labels."