[MacPorts] #14564: port -uR upgrade doesn't upgrade dependencies
#14564: port -uR upgrade doesn't upgrade dependencies -----------------------------------------+---------------------------------- Reporter: waltman-macports@mawode.com | Owner: macports-tickets@lists.macosforge.org Type: defect | Status: new Priority: Normal | Milestone: Component: ports | Version: 1.6.0 Keywords: | -----------------------------------------+---------------------------------- I ran "port sync; port outdated" and saw that libpng was out of date. The manpage for port(1) lists among its options: -R also upgrade dependents (only for upgrading) -u uninstall non-active ports when upgrading and uninstalling So I figured that running "port -uR upgrade libpng" would upgrade any packages that depend on libpng, and then remove the old copies. But instead of doing that, it just upgraded itself. Then it complained that it couldn't remove the old copy because aterm depended it it: ---> Unable to uninstall libpng 1.2.24_0+darwin_8, the following ports depend on it: ---> aterm Error: Uninstall libpng 1.2.24_0+darwin_8 failed: Please uninstall the ports that depend on libpng first. That error message was repeated 6 times. There seem to be several potential bugs here: * If aterm depends on a specific version of libpng, why wasn't it rebuilt? * If aterm doesn't need to be rebuilt (e.g. it can use either 1.2.24 or 1.2.25 via symlinks in /opt/local/lib), then why is it an error to unstall the old package? * Why was the error message repeated 6 times? -- Ticket URL: <http://trac.macosforge.org/projects/macports/ticket/14564> MacPorts </projects/macports> Ports system for Mac OS
#14564: port -uR upgrade doesn't upgrade dependencies ------------------------------------------+--------------------------------- Reporter: waltman-macports@mawode.com | Owner: macports-tickets@lists.macosforge.org Type: defect | Status: new Priority: Normal | Milestone: Component: ports | Version: 1.6.0 Resolution: | Keywords: ------------------------------------------+--------------------------------- Comment (by raimue@macports.org): `-u` can only be used in conjunction with `-f` at the moment. Ports cannot depend on a specific version, they just depends on another port. Therefore every dependent would be upgrade. There is no way to tell if it is necessary. No idea why it was printed 6 times. -- Ticket URL: <http://trac.macosforge.org/projects/macports/ticket/14564#comment:1> MacPorts </projects/macports> Ports system for Mac OS
#14564: port -uR upgrade doesn't upgrade dependencies ------------------------------------------+--------------------------------- Reporter: waltman-macports@mawode.com | Owner: macports-tickets@lists.macosforge.org Type: defect | Status: new Priority: Normal | Milestone: Component: ports | Version: 1.6.0 Resolution: | Keywords: ------------------------------------------+--------------------------------- Comment (by waltman-macports@mawode.com): Replying to [comment:1 raimue@macports.org]:
`-u` can only be used in conjunction with `-f` at the moment.
Then it should say that on the manpage :)
Ports cannot depend on a specific version, they just depends on another port. Therefore every dependent would be upgrade. There is no way to tell if it is necessary.
Isn't that the whole point of -R? If not, then what does "also upgrade dependents" mean?
No idea why it was printed 6 times.
Yes, that's very odd. -- Ticket URL: <http://trac.macosforge.org/projects/macports/ticket/14564#comment:2> MacPorts </projects/macports> Ports system for Mac OS
#14564: port -uR upgrade doesn't upgrade dependencies ------------------------------------------+--------------------------------- Reporter: waltman-macports@mawode.com | Owner: macports-tickets@lists.macosforge.org Type: defect | Status: closed Priority: Normal | Milestone: Component: ports | Version: 1.6.0 Resolution: invalid | Keywords: ------------------------------------------+--------------------------------- Changes (by dluke@macports.org): * status: new => closed * resolution: => invalid Comment: -u can be used without -f, it's just not really useful unless you use it with -f. -u should be avoided in general though. It's better to do the upgrade and then uninstall (with -f) the newly inactive ports. -R will rebuild everything that depended on the new port, this is only actually necessary some of the time, but macports isn't yet smart enough to only do it if it's necessary. IIRC using -R with -f can cause multiple rebuilds which is annoying. To address your original questions: 1. No ports depend on specific versions of other ports. If you upgrade a library and its ABI changes anything that depended on that library will most likely have to be rebuilt (this is what -R is for). Frequently, though, library authors try to maintain ABI compatibility. For my personal usage, I use port -dvnf upgrade outdated and then manually fix things if necessary (or use -R if I know there is an ABI change). 2. aterm didn't get rebuilt because things stopped after the uninstall error 3. Without the actual output, it's difficult to determine why on your system the message was printed 6 times. The upgrade code isn't very long, though, so you could probably figure it out yourself if you were really curious. -- Ticket URL: <http://trac.macosforge.org/projects/macports/ticket/14564#comment:3> MacPorts </projects/macports> Ports system for Mac OS
participants (1)
-
MacPorts