From: Fabian Groffen Date: Sun, 22 Oct 2006 14:31:25 +0000 (-0000) Subject: Misc prefix fixes X-Git-Url: http://git.tremily.us/gitweb.cgi?a=commitdiff_plain;h=7e65684da135852df535a5907bf50c8ae9ce7eca;p=portage.git Misc prefix fixes svn path=/main/branches/prefix/; revision=4796 --- diff --git a/bin/misc-functions.sh b/bin/misc-functions.sh index b8120cce6..5f10af533 100644 --- a/bin/misc-functions.sh +++ b/bin/misc-functions.sh @@ -293,6 +293,8 @@ preinst_sfperms() { if [ -z "$IMAGE" ]; then eerror "${FUNCNAME}: IMAGE is unset" return 1 + else + IMAGE="${IMAGE}/${EPREFIX}" fi # Smart FileSystem Permissions if hasq sfperms $FEATURES; then @@ -313,6 +315,8 @@ preinst_suid_scan() { if [ -z "$IMAGE" ]; then eerror "${FUNCNAME}: IMAGE is unset" return 1 + else + IMAGE="${IMAGE}/${EPREFIX}" fi # total suid control. if hasq suidctl $FEATURES; then @@ -352,12 +356,14 @@ preinst_selinux_labels() { if [ -z "$IMAGE" ]; then eerror "${FUNCNAME}: IMAGE is unset" return 1 + else + IMAGE="${IMAGE}/${EPREFIX}" fi if hasq selinux ${FEATURES}; then # 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 ${EPREFIX}/usr/sbin/setfiles -a -x ${EPREFIX}/usr/sbin/selinuxconfig ]; then + if [ -f ${EPREFIX}/selinux/context -a -x ${EPREFIX}/usr/sbin/setfiles -a -x ${EPREFIX}/usr/sbin/selinuxconfig ]; then vecho ">>> Setting SELinux security labels" ( eval "$(${EPREFIX}/usr/sbin/selinuxconfig)" || \ diff --git a/pym/portage.py b/pym/portage.py index 1b8222ac6..d6b4fbcb9 100644 --- a/pym/portage.py +++ b/pym/portage.py @@ -3000,7 +3000,7 @@ def doebuild(myebuild, mydo, myroot, mysettings, debug=0, listonly=0, filemode=060, filemask=0) return retval elif mydo == "preinst": - mysettings["IMAGE"] = mysettings["EDEST"] + mysettings["IMAGE"] = mysettings["D"] phase_retval = spawn(" ".join((EBUILD_SH_BINARY, mydo)), mysettings, debug=debug, free=1, logfile=logfile) if phase_retval == os.EX_OK: