summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMike Gilbert <floppym@gentoo.org>2019-08-15 11:41:25 -0400
committerMike Gilbert <floppym@gentoo.org>2019-08-15 14:15:29 -0400
commitee0b97b10ce02d42e608e477d97629c6591e3489 (patch)
tree3168fafbecf2d0005f5cd2da2bb98ce764bb78ab /eclass/acct-user.eclass
parentRevert "net-print/hplip: Remove old hplip-3.18.12.ebuild, hplip-3.19.5" (diff)
downloadgentoo-ee0b97b10ce02d42e608e477d97629c6591e3489.tar.gz
gentoo-ee0b97b10ce02d42e608e477d97629c6591e3489.tar.bz2
gentoo-ee0b97b10ce02d42e608e477d97629c6591e3489.zip
acct-user.eclass: die explicitly if HOME is missing in preinst
Closes: https://bugs.gentoo.org/691478 Signed-off-by: Mike Gilbert <floppym@gentoo.org>
Diffstat (limited to 'eclass/acct-user.eclass')
-rw-r--r--eclass/acct-user.eclass8
1 files changed, 8 insertions, 0 deletions
diff --git a/eclass/acct-user.eclass b/eclass/acct-user.eclass
index 60009643c144..008dc6bb7d68 100644
--- a/eclass/acct-user.eclass
+++ b/eclass/acct-user.eclass
@@ -334,6 +334,14 @@ acct-user_pkg_preinst() {
if [[ -z ${ACCT_USER_HOME_OWNER} ]]; then
ACCT_USER_HOME_OWNER=${ACCT_USER_NAME}:${ACCT_USER_GROUPS[0]}
fi
+ # Path might be missing due to INSTALL_MASK, etc.
+ # https://bugs.gentoo.org/691478
+ if [[ ! -e "${ED}/${ACCT_USER_HOME#/}" ]]; then
+ eerror "Home directory is missing from the installation image:"
+ eerror " ${ACCT_USER_HOME}"
+ eerror "Check INSTALL_MASK for entries that would cause this."
+ die "${ACCT_USER_HOME} does not exist"
+ fi
fowners "${ACCT_USER_HOME_OWNER}" "${ACCT_USER_HOME}"
fperms "${ACCT_USER_HOME_PERMS}" "${ACCT_USER_HOME}"
fi