summaryrefslogtreecommitdiff
path: root/eclass
diff options
context:
space:
mode:
authorMike Frysinger <vapier@gentoo.org>2009-10-09 20:57:08 +0000
committerMike Frysinger <vapier@gentoo.org>2009-10-09 20:57:08 +0000
commit393c310db55a3d5a8cba0de5ab0eeab484ff31ab (patch)
treec3e013647cd92f0d5831a9a38cb979bab8fd68bd /eclass
parentrev bump to get patch to fix Server DoS (bug #288295) (diff)
downloadgentoo-2-393c310db55a3d5a8cba0de5ab0eeab484ff31ab.tar.gz
gentoo-2-393c310db55a3d5a8cba0de5ab0eeab484ff31ab.tar.bz2
gentoo-2-393c310db55a3d5a8cba0de5ab0eeab484ff31ab.zip
fix from Lars Wendler (Polynomial-C) to make sure /boot has a .keep file so portage doesnt go deleting the "empty" /boot mount point #274130 by Jochums Johannes
Diffstat (limited to 'eclass')
-rw-r--r--eclass/mount-boot.eclass12
1 files changed, 9 insertions, 3 deletions
diff --git a/eclass/mount-boot.eclass b/eclass/mount-boot.eclass
index 4a0818a743a0..fb69e11e4208 100644
--- a/eclass/mount-boot.eclass
+++ b/eclass/mount-boot.eclass
@@ -1,6 +1,6 @@
# Copyright 1999-2008 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/eclass/mount-boot.eclass,v 1.16 2009/02/27 01:53:34 vapier Exp $
+# $Header: /var/cvsroot/gentoo-x86/eclass/mount-boot.eclass,v 1.17 2009/10/09 20:57:08 vapier Exp $
#
# This eclass is really only useful for bootloaders.
#
@@ -10,14 +10,14 @@
#
# MAINTAINER: base-system@gentoo.org
-EXPORT_FUNCTIONS pkg_preinst
+EXPORT_FUNCTIONS pkg_preinst pkg_prerm
mount-boot_mount_boot_partition() {
if [[ -n ${DONT_MOUNT_BOOT} ]] ; then
return
else
elog
- elog "To avoid automounting and autoinstalling with /boot,"
+ elog "To avoid automounting and auto(un)installing with /boot,"
elog "just export the DONT_MOUNT_BOOT variable."
elog
fi
@@ -72,3 +72,9 @@ mount-boot_mount_boot_partition() {
mount-boot_pkg_preinst() {
mount-boot_mount_boot_partition
}
+
+mount-boot_pkg_prerm() {
+ touch "${ROOT}"/boot/.keep 2>/dev/null
+ mount-boot_mount_boot_partition
+ touch "${ROOT}"/boot/.keep 2>/dev/null
+}