Subject: pkg_add skips packages
To: None <firstname.lastname@example.org>
From: Brook Milligan <brook@trillium.NMSU.Edu>
Date: 09/08/1998 12:05:02
I just tried to use the package version of pkg_add to install some
packages and encountered the following symptom:
- run pkg_add P1.tgz to install package P1
- if P1 has no dependencies, it is installed
- if P1 depends on package P2 which is installed, P1 will be installed
- if P1 depends on package P2 which is not yet installed, P2 will be
installed but P1 will not
Clearly, the last situation is wrong, since it should also install P1
as well as P2.
I'm not up on the pkg_* code, but it looks like there might be a bug
in pkg_install/add/perform.c near line 280:
warnx("add of dependency `%s' failed%s",
p->name, Force ? " (proceeding anyway)" : "!");
I presume from the indentation that BOTH statements following the else
should be grouped together, but my reading of the code indicates that
they are not. I'm also not really sure what code does, but it may be
incremented incorrectly, perhaps causing the above symptom.
Anyone care to comment on the intention of this code fragment?