OSDN Git Service

Sume bugs due to the previous change are fixed.
authorMamoru Sakaue / MwGhennndo <glmwghennndo@users.sourceforge.jp>
Tue, 5 Feb 2013 22:23:53 +0000 (07:23 +0900)
committerMamoru Sakaue / MwGhennndo <glmwghennndo@users.sourceforge.jp>
Tue, 5 Feb 2013 22:23:53 +0000 (07:23 +0900)
modified:   portsreinstall

portsreinstall

index 0fe55db..fea4eec 100755 (executable)
@@ -10,7 +10,7 @@
 # ================================================
 
 APPNAME=`basename "$0"`
-MYVERSION=2.2.2+toward_3.0.0_20130203231825
+MYVERSION=2.2.2+toward_3.0.0_20130206071750
 
 LOCALBASE=${LOCALBASE:-/usr/local}
 PREFIX=${PREFIX:-${LOCALBASE}}
@@ -438,7 +438,7 @@ WITH_PKGNG=`make -C "${PORTSDIR}" -V WITH_PKGNG | tr '[:upper:]' '[:lower:]'`
 
 if [ "x$WITH_PKGNG" = xyes ]
 then
-       [ -x /usr/local/sbin/pkg ] || { echo "ERROR: WITH_PKGNG is set, but pkgng is not available" >&2; exit 1; }
+       [ -x /usr/local/sbin/pkg ] || { echo "ERROR: WITH_PKGNG is set, but pkgng is not available." >&2; exit 1; }
        command_pkg_info='pkg info'
        command_pkg_create='pkg create'
        command_pkg_delete='pkg delete'
@@ -652,7 +652,7 @@ create_backup_pkg ()
        fi
        if [ -z "$backup_pkg" ]
        then
-               echo "WARNING: Failed to create backup package for $pkgname" >&2
+               echo "WARNING: Failed to create backup package for $pkgname." >&2
                return 1
        fi
        [ -d "$dstdir" ] || mkdir -p "$dstdir"
@@ -672,13 +672,20 @@ rm_a_line ()
 
 add_a_line_if_new ()
 {
-       local item dstpath pattern
+       local item dstpath pattern dstdir
        item=$1
        dstpath=$2
        pattern=`str_escape_regexp "$item"`
-       cp "$dstpath" "${DBDIR}/tmpfile:add_a_line_if_new"
-       grep -m 1 -E "^$pattern$" "$dstpath" > /dev/null  2>&1 \
-               || echo "$item" >> ${DBDIR}/tmpfile:add_a_line_if_new
+       if [ -e "$dstpath" ]
+       then
+               cp "$dstpath" "${DBDIR}/tmpfile:add_a_line_if_new"
+               grep -m 1 -E "^$pattern$" "$dstpath" > /dev/null  2>&1 \
+                       || echo "$item" >> ${DBDIR}/tmpfile:add_a_line_if_new
+       else
+               dstdir=`dirname "$dstpath"`
+               [ -d "$dstdir" ] || mkdir -p "$dstdir"
+               echo "$item" > ${DBDIR}/tmpfile:add_a_line_if_new
+       fi
        mv "${DBDIR}/tmpfile:add_a_line_if_new" "$dstpath"
 }
 
@@ -704,21 +711,28 @@ add_a_line_to_files_if_new ()
 
 add_lines_if_new ()
 {
-       local filepath origin advance
-       filepath=$1
+       local dstpath origin advance dstdir
+       dstpath=$1
        advance=$2
-       while read origin
-       do
-               grep -m 1 -E "^`str_escape_regexp \"$origin\"`$" "$filepath" > /dev/null 2>&1 \
-                       || echo "$origin"
-       done > ${TMPDIR}/add_lines_if_new:add
-       if [ "@$advance" = @advance ]
+       if [ -e "$dstpath" ]
        then
-               cat "${TMPDIR}/add_lines_if_new:add" "$filepath"
+               while read origin
+               do
+                       grep -m 1 -E "^`str_escape_regexp \"$origin\"`$" "$dstpath" > /dev/null 2>&1 \
+                               || echo "$origin"
+               done > ${TMPDIR}/add_lines_if_new:add
+               if [ "@$advance" = @advance ]
+               then
+                       cat "${TMPDIR}/add_lines_if_new:add" "$dstpath"
+               else
+                       cat "$dstpath" "${TMPDIR}/add_lines_if_new:add"
+               fi > ${DBDIR}/tmpfile:add_lines_if_new:newfile
        else
-               cat "$filepath" "${TMPDIR}/add_lines_if_new:add"
-       fi > ${DBDIR}/tmpfile:add_lines_if_new:newfile
-       mv "${DBDIR}/tmpfile:add_lines_if_new:newfile" "$filepath"
+               dstdir=`dirname "$dstpath"`
+               [ -d "$dstdir" ] || mkdir -p "$dstdir"
+               cat > ${DBDIR}/tmpfile:add_lines_if_new:newfile
+       fi
+       mv "${DBDIR}/tmpfile:add_lines_if_new:newfile" "$dstpath"
 }
 
 record_success ()
@@ -802,7 +816,7 @@ register_globs ()
                origin=`ports_glob "$glob"`
                [ `cat "${TMPDIR}"/register_globs:ports_glob | wc -l` -ge 1 ] || \
                {
-                       echo "WARNING: No matching ports/package glob [$glob]" >&2
+                       echo "WARNING: No matching ports/package glob [$glob]." >&2
                        continue
                }
                cat "${TMPDIR}"/register_globs:ports_glob
@@ -1107,6 +1121,7 @@ get_recursive_dependency_table ()
        then
                while read origin_requirement
                do
+                       echo "$origin_requirement"
                        get_recursive_dependency_table "$table" "$origin_requirement"
                done < $dbpath/$table.direct | sort -u > ${DBDIR}/tmpfile:get_recursive_dependency_table:$origin_esc
                mv "${DBDIR}/tmpfile:get_recursive_dependency_table:$origin_esc" "$dbpath/$table"
@@ -1205,7 +1220,22 @@ get_dependency_tag ()
        yes+no)
                echo build;;
        *)
-               echo "ERROR: Invalid combination of option values for build-/run-time dependency evaluation" >&2
+               echo "ERROR: Option -B must be combined with -b." >&2
+               exit 1;;
+       esac
+}
+
+get_dependency_msgterm ()
+{
+       case $include_buildtime_dependencies+$include_runtime_dependencies in
+       yes+yes)
+               echo 'run- and build-time';;
+       no+yes)
+               echo 'run-time';;
+       yes+no)
+               echo 'build-time';;
+       *)
+               echo "ERROR: Invalid combination of option values for build-/run-time dependency evaluation." >&2
                exit 1;;
        esac
 }
@@ -1327,15 +1357,10 @@ chk_and_warn_ignored_logical_options ()
 
 msg_stage ()
 {
-       echo -n "========== $* at `timestamp` =========="
+       echo "========== $* =========="
+       echo "[At `timestamp`]"
 }
 
-msg_reinststage_info ()
-{
-       echo -n "========== $counter [$*] ($position_msg at `timestamp`) =========="
-}
-
-
 # ==================================================
 # ==================== MAIN ========================
 # ==================================================
@@ -1392,7 +1417,7 @@ then
        elif [ $num_pkgng_versions -eq 1 ]
        then
                [ -d "${PORTSDIR}/ports-mgmt/pkg" ] \
-                       || { echo "ERROR: ${PORTSDIR}/ports-mgmt/pkg does not exist" >&2; exit 1; }
+                       || { echo "ERROR: ${PORTSDIR}/ports-mgmt/pkg does not exist." >&2; exit 1; }
                pkgng_pkg_current=`cat "${TMPDIR}"/pkgng_version`
                pkgng_pkg_new=`make -C "${PORTSDIR}/ports-mgmt/pkg" package-name`
                if [ -n "$pkgng_pkg_new" ]
@@ -1434,7 +1459,7 @@ then
                                fi
                        fi
                else
-                       echo "WARNING: No port for ports-mgmt/pkg exists in the current ports tree" >&2
+                       echo "WARNING: No port for ports-mgmt/pkg exists in the current ports tree." >&2
                fi
        fi
 fi
@@ -1454,7 +1479,7 @@ then
        then
                self_origin=`pkg_info_qo "\`cat \"${TMPDIR}\"/self_version\`"`
                [ -d "${PORTSDIR}/$self_origin" ] \
-                       || { echo "ERROR: ${PORTSDIR}/$self_origin does not exist" >&2; exit 1; }
+                       || { echo "ERROR: ${PORTSDIR}/$self_origin does not exist." >&2; exit 1; }
                self_pkg_current=`cat "${TMPDIR}"/self_version`
                self_pkg_new=`make -C "${PORTSDIR}/$self_origin" package-name`
                if [ -n "$self_pkg_new" ]
@@ -1479,7 +1504,7 @@ then
                                        echo "INFO: Restarting with the new version..."
                                        echo
                                        . "${TMPDIR}"/restart_command.sh
-                                       echo "ERROR: Failed to launch the new version" >&2
+                                       echo "ERROR: Failed to launch the new version." >&2
                                        exit 1
                                else
                                        echo "WARNING: Reinstallation failed. Restoring the old package..." >&2
@@ -1490,7 +1515,7 @@ then
                                fi
                        fi
                else
-                       echo "WARNING: No port for ${APPNAME} exists in the current ports tree" >&2
+                       echo "WARNING: No port for ${APPNAME} exists in the current ports tree." >&2
                fi
        else
                echo "INFO: This version of ${APPNAME} has been installed not by ports/packages mechanism."
@@ -1609,6 +1634,7 @@ load)
 show)
        [ -e "${DBDIR}/COMPLETE_PREPARATION" ] || { echo "ERROR: Database has not built yet." >&2; exit 1; }
        warn_update_ports
+       [ -e "${DBDIR}"/saved_options.sh ] && . "${DBDIR}"/saved_options.sh
        _filter_skip_unchanged=
        _filter_only_target=
        _for_each_matching_port=
@@ -1675,7 +1701,7 @@ show)
                _for_each_matching_port=y
                ;;
        *)
-               echo "ERROR: Invalid show argument [$1]" >&2
+               echo "ERROR: Invalid show argument [$1]." >&2
                exit 1
                ;;
        esac
@@ -1684,8 +1710,9 @@ show)
        if [ -n "${_for_each_matching_port}" ]
        then
                shift
-               [ $# -gt 0 ] || { echo "ERROR: the argument as port glob is missing" >&2; exit 1; }
+               [ $# -gt 0 ] || { echo "ERROR: the argument as port glob is missing." >&2; exit 1; }
                echo "[$grandtitle]"
+               echo "(Evaluated by `get_dependency_msgterm` dependency)"
                echo
                isfirst=y
                for origin_target in `ports_glob "$@"`
@@ -1706,7 +1733,7 @@ show)
                                fi
                        done < ${DBDIR}/requires/$origin_target/$list
                done
-               [ "$isfirst" = n ] || { echo "ERROR: no matching port for the glob" >&2; exit 1; }
+               [ "$isfirst" = n ] || { echo "ERROR: no matching port for the glob." >&2; exit 1; }
        elif [ -n "${_filter_skip_unchanged}" -a $skip_unchanged = yes ]
        then
                while read origin
@@ -1765,7 +1792,7 @@ do)
        chk_privilege
        ;;
 *)
-       echo "ERROR: Invalid command [$command]" >&2
+       echo "ERROR: Invalid command [$command]." >&2
        exit 1
        ;;
 esac
@@ -1779,11 +1806,11 @@ terminate_process_common ()
        echo
        if [ $errno -eq 130 ]
        then
-               echo "INFO: Terminated at `timestamp`$msg_where"
+               echo "INFO: Terminated at `timestamp`$msg_where."
                echo
                echo " You can restart this process from the terminated point by"
        else
-               echo "INFO: Aborted at `timestamp`$msg_where"
+               echo "INFO: Aborted at `timestamp`$msg_where."
                echo
                echo " You may restart this process from the aborted point by"
        fi
@@ -1860,7 +1887,7 @@ then
                fi
        elif [ $load_pkgtoolsconf != undef -a `which portupgrade | wc -l` -eq 0 ]
        then
-               echo "WARNING: pkgtools.conf is ignored because portupgrade is not installed" >&2
+               echo "WARNING: pkgtools.conf is ignored because portupgrade is not installed." >&2
                load_pkgtoolsconf=no
        fi
        
@@ -1990,17 +2017,7 @@ fi
 if [ -n "$target_dependent_ports$target_dependent_ports_form2$target_required_ports$target_required_ports_form2" ]
 then
        echo "INFO: Operations will be applied only to the targets:"
-       case $include_buildtime_dependencies+$include_runtime_dependencies in
-       yes+yes)
-               dependency_type='run- and build-time';;
-       no+yes)
-               dependency_type='run-time';;
-       yes+no)
-               dependency_type='build-time';;
-       *)
-               echo "ERROR: Invalid combination of option values for build-/run-time dependency evaluation" >&2
-               exit 1;;
-       esac
+       dependency_type=`get_dependency_msgterm`
        num_specified_dependents=`cat "${DBDIR}"/target_dependent_ports.specified | wc -l`
        num_specified_requirements=`cat "${DBDIR}"/target_required_ports.specified | wc -l`
        suffix=.
@@ -2018,7 +2035,9 @@ then
                cat "${DBDIR}"/target_required_ports.specified
                echo "----------------------------------------"
                echo "and their $dependency_type requirements."
-       else
+       fi
+       if [ $num_specified_dependents -eq 0 -a $num_specified_requirements -eq 0 ]
+       then
                echo  "ERROR: Target ports are specified but none of them is valid." >&2
                exit 1
        fi
@@ -2042,7 +2061,7 @@ then
                do
                        set | grep -e "^${item}_" | sed 's/^/_CONF_/'
                done > ${DBDIR}/confvars.sh
-       ) || { echo "ERROR: Invalid syntax in [${CONFFILE}]" >&2; exit 1; }
+       ) || { echo "ERROR: Invalid syntax in [${CONFFILE}]." >&2; exit 1; }
        touch "${DBDIR}/COMPLETE_PARSE_CONF"
 fi
 . "${DBDIR}/confvars.sh"
@@ -2095,7 +2114,7 @@ then
                        then
                                to=
                        else
-                               [ -d "${PORTSDIR}/$to" ] || echo "WARNING: replacement port [$to] is obsolete" >&2
+                               [ -d "${PORTSDIR}/$to" ] || echo "WARNING: replacement port [$to] is obsolete." >&2
                        fi
                        str_escape_regexp_filter < ${TMPDIR}/origins.2.tmp \
                                | sed -E "s|^|s:^|; s/$/$:`str_escape_replaceval \"$to\"`:/" \
@@ -2179,7 +2198,7 @@ then
        touch "${DBDIR}/target.inspected.list"
        if [ -f "${DBDIR}/target_ports.remain" ]
        then
-               echo "INFO: Restarting from the previously terminated point"
+               echo "INFO: Restarting from the previously terminated point."
        else
                cp -p "${DBDIR}/target_ports" "${DBDIR}/target_ports.remain"
        fi
@@ -2216,7 +2235,7 @@ then
        echo "Starting conversion of requirements-lists to actual ones at `timestamp`"
        if [ -f "${DBDIR}/convert_requirements_lists.remain" ]
        then
-               echo "INFO: Restarting from the previously terminated point"
+               echo "INFO: Restarting from the previously terminated point."
        else
                ( set -e
                        cd "${DBDIR}/initial" && find . -depth 2 -type d
@@ -2237,7 +2256,7 @@ then
                                for dbtag in requires initial
                                do
                                        target=${DBDIR}/$dbtag/$origin/${table}_${tag}
-                                       [ -e "$target" ] || continue
+                                       [ -e "$target.src" ] || continue
                                        sed -E -f "${DBDIR}/REPLACE.complete_replace_pattern" "$target.src" \
                                                | grep -v '^$' | sort -u > $target
                                done
@@ -2245,7 +2264,8 @@ then
                done
                for tag in run build
                do
-                       mv "${DBDIR}/requires/$origin/requirements_$tag" "${DBDIR}/requires/$origin/requirements_$tag.direct"
+                       target=${DBDIR}/requires/$origin/requirements_$tag
+                       [ -e "$target" ] && mv "$target" "$target.direct"
                done
                sed -i '' 1d "${DBDIR}/convert_requirements_lists.remain"
        done < ${TMPDIR}/convert_requirements_lists
@@ -2259,7 +2279,7 @@ then
        echo "Starting completion of run-time requirement lists at `timestamp`"
        if [ -f "${DBDIR}/complete_runtime_reqlists.remain" ]
        then
-               echo "INFO: Restarting from the previously terminated point"
+               echo "INFO: Restarting from the previously terminated point."
        else
                find "${DBDIR}/requires" -depth 3 -type f -name requirements_run.direct \
                        > ${DBDIR}/complete_runtime_reqlists.remain
@@ -2285,7 +2305,7 @@ then
        echo "Starting completion of build-time requirement lists at `timestamp`"
        if [ -f "${DBDIR}/complete_buildtime_reqlists.remain" ]
        then
-               echo "INFO: Restarting from the previously terminated point"
+               echo "INFO: Restarting from the previously terminated point."
        else
                find "${DBDIR}/requires" -depth 3 -type f -name requirements_build.direct \
                        > ${DBDIR}/complete_buildtime_reqlists.remain
@@ -2311,7 +2331,7 @@ then
        echo "Starting inspection of dependents at `timestamp`"
        if [ -f "${DBDIR}/inspect_dependent.remain" ]
        then
-               echo "INFO: Restarting from the previously terminated point"
+               echo "INFO: Restarting from the previously terminated point."
        else
                find "${DBDIR}/requires" -depth 2 -type d > ${DBDIR}/inspect_dependent.remain
        fi
@@ -2325,6 +2345,7 @@ then
                origin=$catname/$portname
                for tag in all run build
                do
+                       [ -e "$dbpath/requirements_$tag" ] || continue
                        sed -E "s/^/$dbrequires_valesc/; s|$|/dependents_$tag|" "$dbpath/requirements_$tag" \
                                | add_a_line_to_files_if_new "$origin"
                done
@@ -2340,7 +2361,7 @@ then
        echo "Starting preparation of matching patterns of dependencies at `timestamp`"
        if [ -f "${DBDIR}/prepare_matching_patterns_dependencies.remain" ]
        then
-               echo "INFO: Restarting from the previously terminated point"
+               echo "INFO: Restarting from the previously terminated point."
        else
                find "${DBDIR}/requires" -depth 2 -type d > ${DBDIR}/prepare_matching_patterns_dependencies.remain
        fi
@@ -2365,7 +2386,8 @@ then
                        done
                done
                chk_if_target currentorigin "$origin"
-               [ -n "${currentorigin_is_relevant}" ] && touch "$dbpath/relevant_to_target"
+               [ -z "${currentorigin_is_all}" -a -n "${currentorigin_is_relevant}" ] \
+                       && touch "$dbpath/relevant_to_target"
                sed -i '' 1d "${DBDIR}/prepare_matching_patterns_dependencies.remain"
        done < ${DBDIR}/prepare_matching_patterns_dependencies
        touch "${DBDIR}/COMPLETE_PREPARATION_OF_MATCHING_PATTERNS_OF_DEPENDENCIES"
@@ -2378,7 +2400,7 @@ then
        echo "Starting preparation of matching patterns of obsolete ports to be deleted at `timestamp`"
        if [ -f "${DBDIR}/prepare_matching_patterns_obsolete_ports.remain" ]
        then
-               echo "INFO: Restarting from the previously terminated point"
+               echo "INFO: Restarting from the previously terminated point."
        else
                cp -p "${DBDIR}/moved_or_lost.list" "${DBDIR}/prepare_matching_patterns_obsolete_ports.remain"
        fi
@@ -2398,16 +2420,15 @@ then
        echo "Starting inspection of necessity at `timestamp`"
        if [ -f "${DBDIR}/inspect_necessity.remain" ]
        then
-               echo "INFO: Restarting from the previously terminated point"
+               echo "INFO: Restarting from the previously terminated point."
        else
                find "${DBDIR}/requires" -depth 3 -type f \
                        \( -name installed_version -or -name relevant_to_target \) \
                        | sed 's|/[^/]*$||' | sort -u > ${DBDIR}/inspect_necessity.remain
        fi
        cp "${DBDIR}/inspect_necessity.remain" "${TMPDIR}/inspect_necessity"
-       while read markerpath
+       while read dbpath
        do
-               dbpath=`dirname "$markerpath"`
                portname=`basename "$dbpath"`
                catpath=`dirname "$dbpath"`
                catname=`basename "$catpath"`
@@ -2425,7 +2446,7 @@ then
        echo "Starting inspection of necessary updates at `timestamp`"
        if [ -f "${DBDIR}/necessary_updates.remain" ]
        then
-               echo "INFO: Restarting from the previously terminated point"
+               echo "INFO: Restarting from the previously terminated point."
        else
                find "${DBDIR}/requires" -depth 3 -type f -name necessary_port > ${DBDIR}/necessary_updates.remain
        fi
@@ -2475,7 +2496,8 @@ fi
 if [ ! -e "${DBDIR}/COMPLETE_ORDERED_ALL_DEPENDENCIES" ]
 then
        echo "Starting ordering of dependencies at `timestamp`"
-       [ ! -f "${DBDIR}/reinst_order.list.tmp" ] || echo "INFO: Restarting from the previously terminated point"
+       [ ! -f "${DBDIR}/reinst_order.list.tmp" ] || \
+               echo "INFO: Restarting from the previously terminated point."
        touch "${DBDIR}/reinst_order.list.tmp"
        cd "${DBDIR}/requires"
        cat > ${TMPDIR}/order_dependencies.awk << eof
@@ -2572,7 +2594,7 @@ END {
 eof
        find . -depth 3 -name requirements_all.remained -exec echo {} \; -exec cat {} \; -exec echo \; | \
                env DBDIR=${DBDIR} awk -f "${TMPDIR}"/order_dependencies.awk || { \
-                       echo "ERROR: Unsatisfied dependencies are remained" >&2
+                       echo "ERROR: Unsatisfied dependencies are remained:" >&2
                        cat "${DBDIR}/unsatisfied.list"
                        echo "*** Aborted by ${APPNAME}"
                        echo "The ports tree seems broken. You might have caught an incomplete version."
@@ -2647,7 +2669,7 @@ then
        then
                if [ -f "${DBDIR}/moved_or_lost.list.remained" ]
                then
-                       echo "INFO: Restarting from the previously terminated point"
+                       echo "INFO: Restarting from the previously terminated point."
                else
                        cp -p "${DBDIR}/moved_or_lost.list" "${DBDIR}/moved_or_lost.list.remained"
                fi
@@ -2696,7 +2718,7 @@ then
                                backup_pkg=`create_backup_pkg "$currentpkg" "${DBDIR}/backup_obsolete"` || :
                                if [ -n "$backup_pkg" ]
                                then
-                                       echo "INFO: The backup is saved at $backup_pkg"
+                                       echo "INFO: The backup is saved at $backup_pkg."
                                else
                                        echo "*** Continuating forcibly by keeping the installed package"
                                        continue
@@ -2732,7 +2754,7 @@ then
        [ -d "${DBDIR}/backup_failure" ] || mkdir -p "${DBDIR}/backup_failure"
        if [ ! -e "${DBDIR}/MODE_REDO" -a -f "${DBDIR}/reinst_todo.list" ]
        then
-               echo "INFO: Restarting from the previously terminated point"
+               echo "INFO: Restarting from the previously terminated point."
        else
                cp -p "${DBDIR}/reinst_order.list" "${DBDIR}/reinst_todo.list"
        fi
@@ -2790,22 +2812,23 @@ then
                echo "$pkgtag" > $nodedir/pkgtag
                position_msg="$origin ($pkgtag)"
                deptag=`get_dependency_tag`
+               msg_stage "$counter $position_msg"
                if grep -m 1 -E "^$origin_regexp_esc$" "${DBDIR}/success_$deptag.list" > /dev/null 2>&1
                then
-                       msg_reinststage_info "Skipping an already reinstalled package"
+                       echo "(Skipped because the reinstallation has been already completed)"
                        echo
                        rm_a_line "$origin" "${DBDIR}/reinst_todo.list"
                        continue
                fi
-               if [ $skip_unchanged = yes -a $is_currentport_latest = yes ]
+               if [ $skip_unchanged = yes ]
                then
                        if [ ! -e "$nodedir/necessary_update_$deptag" ]
                        then
                                if [ -e "$nodedir/installed_version" ]
                                then
-                                       msg_reinststage_info "Skipping because being already latest as well as the all requirements"
+                                       echo "(Skipped because being already latest as well as the all requirements)"
                                else
-                                       msg_reinststage_info "Skipping because being an only-build-time dependency of already latest packages"
+                                       echo "(Skipped because being an only-build-time dependency of already latest packages)"
                                fi
                                echo
                                rm_a_line "$origin" "${DBDIR}/reinst_todo.list"
@@ -2836,7 +2859,7 @@ then
                                fi
                                if [ $need_update = no ]
                                then
-                                       msg_reinststage_info "Skipping because being already latest or failed as well as the all requirements"
+                                       echo "(Skipped because being already latest or failed as well as the all requirements)"
                                        echo
                                        add_a_line_if_new "$origin" "${DBDIR}/todo_after_requirements_succeed_$deptag.list"
                                        rm_a_line "$origin" "${DBDIR}/reinst_todo.list"
@@ -2861,7 +2884,7 @@ then
                                [ -z "${currentorigin_is_former_required}" ] \
                                        || echo "(Former requirement of the target port(s))" >> ${TMPDIR}/msg_if_target
                        else
-                               msg_reinststage_info "Skipping because being irrelevant"
+                               echo "(Skipped because being irrelevant)"
                                echo
                                rm_a_line "$origin" "${DBDIR}/reinst_todo.list"
                                continue
@@ -2869,7 +2892,7 @@ then
                fi
                if grep -m 1 -E "^$origin_regexp_esc$" "${DBDIR}/HOLD_PORTS.conflist" > /dev/null 2>&1
                then
-                       msg_reinststage_info "Skipping because being a hold package"
+                       echo "(Skipped because being a hold package)"
                        cat ${TMPDIR}/msg_if_target
                        echo
                        rm_a_line "$origin" "${DBDIR}/reinst_todo.list"
@@ -2877,7 +2900,7 @@ then
                fi
                if grep -m 1 -E "^$origin_regexp_esc$" "${DBDIR}/taboo.all.list" > /dev/null 2>&1
                then
-                       msg_reinststage_info "Ignored because being taboo"
+                       echo "(Ignored because being taboo)"
                        cat ${TMPDIR}/msg_if_target
                        echo
                        rm_a_line "$origin" "${DBDIR}/reinst_todo.list"
@@ -2885,7 +2908,7 @@ then
                fi
                if grep -m 1 -E "^$origin_regexp_esc$" "${DBDIR}/manually_done.list" > /dev/null 2>&1
                then
-                       msg_reinststage_info "Marking to be manually-done"
+                       echo "(Marked to be manually-done)"
                        cat ${TMPDIR}/msg_if_target
                        echo
                        rm_a_line "$origin" "${DBDIR}/reinst_todo.list"
@@ -2893,7 +2916,7 @@ then
                fi
                if [ -e "$nodedir/SUPPRESSED" ]
                then
-                       msg_reinststage_info "Skipping because being suppressed"
+                       echo "(Skipped because being suppressed)"
                        cat ${TMPDIR}/msg_if_target
                        echo
                        rm_a_line "$origin" "${DBDIR}/reinst_todo.list"
@@ -2908,7 +2931,7 @@ then
                        instdesc='an installation'
                fi
                _MSG_CURRENT_STAGE="$instdesc process for $position_msg $counter"
-               msg_stage "$counter Starting $instdesc process for $position_msg"
+               echo "------- Starting $instdesc process --------"
                cat ${TMPDIR}/msg_if_target
                cd "${PORTSDIR}/$origin"
                if [ -e "$nodedir/status/in_build" ]
@@ -3168,7 +3191,7 @@ then
                                [ -e "$nodedir/dependents_$tag" ] || continue
                                while read origin_dependent
                                do
-                                       touch "$nodedir_dependent/need_reinstall_due_to_updated_requirements_$tag"
+                                       touch "${DBDIR}/requires/$origin_dependent/need_reinstall_due_to_updated_requirements_$tag"
                                done < $nodedir/dependents_$tag
                        done
                        touch "$nodedir/status/COMPLETE_TELL_UPDATE_TO_DEPANDENTS"