Portupgrade not running get_notinstalled_depends (2.4.3_1,
2 vs 2.4.3_2, 2)
James
james at hicag.org
Fri Feb 22 18:23:30 UTC 2008
On Wed, Feb 20, 2008 at 9:32 AM, James <james at hicag.org> wrote:
> For example, in my tests, if I have an alt-dep set for a package and
> I install a port that depends on that package it'll still install
> the original package rather than my alt-dep.
In case anyone's interested or running into this too I have an
update to the issue I ran into here.
As it turns out I was off base about the cause of the problem. It
wasn't the change instituted in version 2.4.3_2,2 at all. That
version fixes a problem when upgrading ports, not installing them.
I was running into problems installing ports.
In one of my tests I was installing the following ports in one
portinstall session.
databases/mysql50-client
databases/mysql50-server
databases/mysql50-scripts
databases/mytop
The problem I ran into was with databases/p5-DBD-mysql50 vs.
databases/p5-DBD-mysql.
databases/mysql50-scripts depends on databases/p5-DBD-mysql50 and
databases/mytop depends on databases/p5-DBD-mysql. portinstall
tries to install both and fails because they conflict. I figured
I could use ALT_PKGDEP to help me here. I used this:
'databases/p5-DBD-mysql' => 'databases/p5-DBD-mysql50',
But the install was still failing. After reading the code and
working in irb a bit I traced the problem down to the way alt_dep
(used when resolving alt-deps) works. Turns out it only works
when the port involved in the alternate dependency is already
installed (because it uses pkgdb methods -- if the port isn't
installed pkgdb has nothing to say). In other words the alternate
dependency will not take effect if the port involved is being
installed in the same session that the alternate dependency is
being used.
I was able to work around my trouble by installing -client,
-server, and -scripts first. Then installing mytop in another
session. Viola, the alt-dep works because the port involved in
the alt-dep already present.
If anyone considers this a bug I'd be happy to help work on a
correction. Heck I may do it anyhow.
HTH!
--
James.
More information about the freebsd-ports
mailing list