summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorIan Stakenvicius <axs@gentoo.org>2013-01-28 21:25:21 +0000
committerIan Stakenvicius <axs@gentoo.org>2013-01-28 21:25:21 +0000
commit801ece23fb482e29a59114681b654734d11d8b7d (patch)
treedb6b2b828d245bc68cab9d6941cd44894683207c /sys-fs/eudev
parentAutobump. (diff)
downloadgentoo-2-801ece23fb482e29a59114681b654734d11d8b7d.tar.gz
gentoo-2-801ece23fb482e29a59114681b654734d11d8b7d.tar.bz2
gentoo-2-801ece23fb482e29a59114681b654734d11d8b7d.zip
fix selinux for beta2, fix location of udev-init-scripts dep
(Portage version: 2.1.11.38/cvs/Linux x86_64, signed Manifest commit with key 2B6559ED)
Diffstat (limited to 'sys-fs/eudev')
-rw-r--r--sys-fs/eudev/ChangeLog6
-rw-r--r--sys-fs/eudev/eudev-1_beta2-r1.ebuild12
-rw-r--r--sys-fs/eudev/eudev-9999.ebuild6
-rw-r--r--sys-fs/eudev/files/eudev-fix-selinux.patch49
4 files changed, 66 insertions, 7 deletions
diff --git a/sys-fs/eudev/ChangeLog b/sys-fs/eudev/ChangeLog
index 3759726b6dab..8f6437f460f7 100644
--- a/sys-fs/eudev/ChangeLog
+++ b/sys-fs/eudev/ChangeLog
@@ -1,6 +1,10 @@
# ChangeLog for sys-fs/eudev
# Copyright 1999-2013 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/sys-fs/eudev/ChangeLog,v 1.23 2013/01/28 14:34:35 axs Exp $
+# $Header: /var/cvsroot/gentoo-x86/sys-fs/eudev/ChangeLog,v 1.24 2013/01/28 21:25:21 axs Exp $
+
+ 28 Jan 2013; Ian Stakenvicius <axs@gentoo.org> eudev-1_beta2-r1.ebuild,
+ eudev-9999.ebuild, +files/eudev-fix-selinux.patch:
+ fix selinux for beta2, fix location of udev-init-scripts dep
28 Jan 2013; Ian Stakenvicius <axs@gentoo.org> eudev-1_beta2-r1.ebuild,
eudev-9999.ebuild:
diff --git a/sys-fs/eudev/eudev-1_beta2-r1.ebuild b/sys-fs/eudev/eudev-1_beta2-r1.ebuild
index f4fa5f12801b..d875d9370dd6 100644
--- a/sys-fs/eudev/eudev-1_beta2-r1.ebuild
+++ b/sys-fs/eudev/eudev-1_beta2-r1.ebuild
@@ -1,6 +1,6 @@
# Copyright 1999-2013 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/sys-fs/eudev/eudev-1_beta2-r1.ebuild,v 1.5 2013/01/28 14:34:35 axs Exp $
+# $Header: /var/cvsroot/gentoo-x86/sys-fs/eudev/eudev-1_beta2-r1.ebuild,v 1.6 2013/01/28 21:25:21 axs Exp $
EAPI=5
@@ -45,7 +45,6 @@ DEPEND="${COMMON_DEPEND}
RDEPEND="${COMMON_DEPEND}
hwdb? ( >=sys-apps/hwids-20121202.2[udev] )
- openrc? ( >=sys-fs/udev-init-scripts-18 )
!sys-fs/udev
!sys-apps/coldplug
!sys-apps/systemd
@@ -53,7 +52,8 @@ RDEPEND="${COMMON_DEPEND}
!sys-fs/device-mapper
!<sys-fs/udev-init-scripts-18"
-PDEPEND=">=virtual/udev-180"
+PDEPEND=">=virtual/udev-180
+ openrc? ( >=sys-fs/udev-init-scripts-18 )"
udev_check_KV()
{
@@ -117,6 +117,12 @@ src_prepare()
# Fix a typo found after 1_beta2 was rolled out
epatch "${FILESDIR}/${PN}-fix-typo-util.c.patch"
+ # Fix selinux - make it optional as eautoreconf is required
+ if use selinux ; then
+ epatch "${FILESDIR}/${PN}-fix-selinux.patch"
+ rm configure
+ fi
+
epatch_user
if [[ ! -e configure ]]
diff --git a/sys-fs/eudev/eudev-9999.ebuild b/sys-fs/eudev/eudev-9999.ebuild
index 2a1924ccf88c..d3e27d06eadb 100644
--- a/sys-fs/eudev/eudev-9999.ebuild
+++ b/sys-fs/eudev/eudev-9999.ebuild
@@ -1,6 +1,6 @@
# Copyright 1999-2013 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/sys-fs/eudev/eudev-9999.ebuild,v 1.17 2013/01/28 14:34:35 axs Exp $
+# $Header: /var/cvsroot/gentoo-x86/sys-fs/eudev/eudev-9999.ebuild,v 1.18 2013/01/28 21:25:21 axs Exp $
EAPI=5
@@ -45,7 +45,6 @@ DEPEND="${COMMON_DEPEND}
RDEPEND="${COMMON_DEPEND}
hwdb? ( >=sys-apps/hwids-20121202.2[udev] )
- openrc? ( >=sys-fs/udev-init-scripts-18 )
!sys-fs/udev
!sys-apps/coldplug
!sys-apps/systemd
@@ -53,7 +52,8 @@ RDEPEND="${COMMON_DEPEND}
!sys-fs/device-mapper
!<sys-fs/udev-init-scripts-18"
-PDEPEND=">=virtual/udev-180"
+PDEPEND=">=virtual/udev-180
+ openrc? ( >=sys-fs/udev-init-scripts-18 )"
udev_check_KV()
{
diff --git a/sys-fs/eudev/files/eudev-fix-selinux.patch b/sys-fs/eudev/files/eudev-fix-selinux.patch
new file mode 100644
index 000000000000..ad13a59d5400
--- /dev/null
+++ b/sys-fs/eudev/files/eudev-fix-selinux.patch
@@ -0,0 +1,49 @@
+commit 26e92619267df364bac4aed29376a36669fb53d3
+Author: Ian Stakenvicius <axs@gentoo.org>
+Date: Mon Jan 28 11:16:31 2013 -0500
+
+ Add missing selinux code to udev core (convenience lib)
+
+ Original Author: Alexey D. (TZ86)
+ Signed-off-by: Ian Stakenvicius <axs@gentoo.org>
+ Signed-off-by: Matthew Thode <prometheanfire@gentoo.org>
+
+diff --git a/src/udev/Makefile.am b/src/udev/Makefile.am
+index 972c275..866d2c2 100644
+--- a/src/udev/Makefile.am
++++ b/src/udev/Makefile.am
+@@ -72,7 +72,8 @@ libudev_core_la_CFLAGS = \
+
+ libudev_core_la_LIBADD = \
+ $(top_builddir)/src/libudev/libudev-private.la \
+- $(BLKID_LIBS)
++ $(BLKID_LIBS) \
++ $(SELINUX_LIBS)
+
+ if HAVE_MODULES
+ libudev_core_la_SOURCES += \
+diff --git a/src/udev/label.c b/src/udev/label.c
+index d353da5..7e8d8f9 100644
+--- a/src/udev/label.c
++++ b/src/udev/label.c
+@@ -31,12 +31,19 @@
+ #include "path-util.h"
+
+ #ifdef HAVE_SELINUX
+-#include "selinux-util.h"
++#include <stdbool.h>
+ #include <selinux/selinux.h>
+ #include <selinux/label.h>
+
+ static struct selabel_handle *label_hnd = NULL;
++static int use_selinux_cached = -1;
+
++bool use_selinux(void) {
++ if (use_selinux_cached < 0)
++ use_selinux_cached = is_selinux_enabled() > 0;
++
++ return use_selinux_cached;
++}
+ #endif
+
+ int label_init(const char *prefix) {