if [ "$EBUILD_PHASE" != "depend" ]; then if [ ! -z "${PORT_ENOTICE_DIR}" ]; then export SANDBOX_WRITE="$SANDBOX_WRITE:${PORT_ENOTICE_DIR}" install -d "${PORT_ENOTICE_DIR}" &>/dev/null chown root:portage "${PORT_ENOTICE_DIR}" &>/dev/null chmod g+rwxs "${PORT_ENOTICE_DIR}" &>/dev/null if [ "$EBUILD_PHASE" == "unpack" ]; then rm -f ${PORT_ENOTICE_DIR}/${PF} fi fi fi einfo() { enotice info "${*}" } ewarn() { enotice warn "${*}" } eerror() { enotice error "${*}" } enotice() { local color local type type="${1}" case "${type}" in "info") color="${GOOD}" ;; "warn") color="${WARN}" ;; "error") color="${BAD}" ;; esac shift if [ ! -z "${PORT_ENOTICE_DIR}" ]; then echo "${type}:${*}" >> ${PORT_ENOTICE_DIR}/${PF} fi echo " ${color}*${NORMAL} ${*}" } # for myarg in $*; do # if [ "${myarg}" == "postinst" ] # then # if [[ -n ${PORT_ENOTICE_DIR} && -r ${T}/notices.${PF} ]] # then # cp ${T}/notices.${PF} ${PORT_ENOTICE_DIR}/${PF} # fi # fi # done