Index: files/patch-bin_portupgrade =================================================================== --- files/patch-bin_portupgrade (revision 0) +++ files/patch-bin_portupgrade (working copy) @@ -0,0 +1,91 @@ +--- bin/portupgrade.orig 2015-05-15 00:13:41 UTC ++++ bin/portupgrade +@@ -193,6 +193,7 @@ def init_global + $fetch_only = false + $fetch_recursive = false + $force = false ++ $force_all = false + $keep_going = false + $ignore_moved = false + $interactive = false +@@ -245,7 +246,6 @@ usage: #{MYNAME} [-habcCDDefFiklnOpPPqrR + opts.def_option("-a", "--all", + "Do with all the installed packages") { |v| + $all = v +- $recursive = false + $upward_recursive = false + } + +@@ -298,7 +298,17 @@ usage: #{MYNAME} [-habcCDDefFiklnOpPPqrR + + opts.def_option("-f", "--force", + "Force the upgrade of a port even if it is to be a" << NEXTLINE << +- "downgrade or just a reinstall, or the port is held") { |v| ++ "downgrade or just a reinstall, or the port is held" << NEXTLINE << ++ "Specified twice, --force-all is implied") { |v| ++ if $force ++ $force_all = v ++ end ++ $force = v ++ } ++ ++ opts.def_option("--force_all", ++ "Or -ff; Force upgrade or reinstall of all ports") { |v| ++ $force_all = v + $force = v + } + +@@ -418,7 +428,7 @@ usage: #{MYNAME} [-habcCDDefFiklnOpPPqrR + opts.def_option("-r", "--recursive", + "Do with all those depending on the given packages" << NEXTLINE << + "as well") { +- $recursive = true unless $all ++ $recursive = true + } + + opts.def_option("-R", "--upward-recursive", +@@ -596,7 +606,7 @@ Environment Variables [default]: + $pkgdb.glob(pattern, false).each do |pkgname| + first ||= pkgname + +- list |= $pkgdb.recurse(pkgname, $recursive, false, $sanity_check) ++ list |= $pkgdb.recurse(pkgname, $recursive && !(arg.equal? all), false, $sanity_check) + end + rescue => e + raise e if e.class == PkgDB::NeedsPkgNGSupport +@@ -611,14 +621,14 @@ Environment Variables [default]: + end + end + +- upgrade_tasks |= list ++ list -= upgrade_tasks + + found = true + + # Check packages for updates and gather dependecies + depends = [] + not_need_upgrade = [] +- upgrade_tasks.each do |task| ++ list.each do |task| + pkg = PkgInfo.new(task) + if task == first && $origin + origin = $origin +@@ -670,7 +680,7 @@ Environment Variables [default]: + end + name =~ /^(.+)-([^-]+)$/ + newversion = PkgVersion.new($2) +- if newversion <= pkg.version && !$force ++ if newversion <= pkg.version && !($force_all || ($force && !(arg.equal? all))) + not_need_upgrade << task + next + end +@@ -678,7 +688,8 @@ Environment Variables [default]: + #install_tasks |= get_notinstalled_depends(origin) + end + end +- upgrade_tasks -= not_need_upgrade ++ list -= not_need_upgrade ++ upgrade_tasks |= list + + # Check dependencies for updates + depends -= [''] Property changes on: files/patch-bin_portupgrade ___________________________________________________________________ Added: fbsd:nokeywords ## -0,0 +1 ## +yes \ No newline at end of property Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:mime-type ## -0,0 +1 ## +text/plain \ No newline at end of property Index: files/patch-man_portupgrade.1 =================================================================== --- files/patch-man_portupgrade.1 (revision 0) +++ files/patch-man_portupgrade.1 (working copy) @@ -0,0 +1,75 @@ +--- man/portupgrade.1.orig 2015-05-15 00:13:41 UTC ++++ man/portupgrade.1 +@@ -188,6 +188,21 @@ Force the upgrade of a package even if i + a reinstall of the same version, or the port is held by user using the + HOLD_PKGS variable in + .Pa pkgtools.conf . ++This option is ignored when combined with ++.Fl a ++or ++.Ar '*' ++as ++.Ar pkgname_glob . ++.Pp ++.It Fl ff ++.It Fl -force-all ++Force the upgrade or reinstallation of all packages when combined with ++.Fl a ++or ++.Ar '*' ++as ++.Ar pkgname_glob . + .Pp + .It Fl F + .It Fl -fetch-only +@@ -335,6 +350,12 @@ Do not read the configuration file - + .It Fl r + .It Fl -recursive + Act on all those packages depending on the given packages as well. ++This option is ignored when combined with ++.Fl a ++or ++.Ar '*' ++as ++.Ar pkgname_glob . + .Pp + .It Fl R + .It Fl -upward-recursive +@@ -648,6 +669,37 @@ from a version comparison. + is the option to specify an exclusion pattern. + .Pp + .It ++Rebuild and reinstall all ports that depend on ++.Ar sdl , ++and upgrade all other ports in the proper order: ++.Pp ++.Dl portupgrade -arf sdl ++.Pp ++The ++.Fl f ++/ ++.Fl -force ++and ++.Fl r ++/ ++.Fl -recursive ++options only apply to the explicitly specified port(s) and not to ++all of the ports implied by ++.Fl a ++/ ++.Fl all . ++.Pp ++.It ++Rebuild and reinstall all ports: ++.Pp ++.Dl portupgrade -aff ++.Pp ++.Fl ff ++/ ++.Fl -force-all ++option applies to all ports. ++.Pp ++.It + Rebuild and reinstall all that ports that were installed prior to the date + 2001-09-20: + .Pp Property changes on: files/patch-man_portupgrade.1 ___________________________________________________________________ Added: fbsd:nokeywords ## -0,0 +1 ## +yes \ No newline at end of property Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +FreeBSD=%H \ No newline at end of property Added: svn:mime-type ## -0,0 +1 ## +text/plain \ No newline at end of property