Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
View | Details | Raw Unified | Return to bug 655996 | Differences between
and this patch

Collapse All | Expand All

(-)a/bin/misc-functions.sh (-4 / +1 lines)
Lines 439-452 preinst_selinux_labels() { Link Here
439
		# SELinux file labeling (needs to execute after preinst)
439
		# SELinux file labeling (needs to execute after preinst)
440
		# only attempt to label if setfiles is executable
440
		# only attempt to label if setfiles is executable
441
		# and 'context' is available on selinuxfs.
441
		# and 'context' is available on selinuxfs.
442
		if [ -f /selinux/context -o -f /sys/fs/selinux/context ] && \
442
		if [ -f /sys/fs/selinux/context -a -x /usr/sbin/setfiles -a -x /usr/sbin/selinuxconfig ]; then
443
			[ -x /usr/sbin/setfiles -a -x /usr/sbin/selinuxconfig ]; then
444
			__vecho ">>> Setting SELinux security labels"
443
			__vecho ">>> Setting SELinux security labels"
445
			(
444
			(
446
				eval "$(/usr/sbin/selinuxconfig)" || \
445
				eval "$(/usr/sbin/selinuxconfig)" || \
447
					die "Failed to determine SELinux policy paths.";
446
					die "Failed to determine SELinux policy paths.";
448
447
449
				addwrite /selinux/context
450
				addwrite /sys/fs/selinux/context
448
				addwrite /sys/fs/selinux/context
451
449
452
				/usr/sbin/setfiles -F "${file_contexts_path}" -r "${D}" "${D}"
450
				/usr/sbin/setfiles -F "${file_contexts_path}" -r "${D}" "${D}"
453
- 

Return to bug 655996