[Bug 296467] pkg upgrade installs unrelated, unnecessary other packages
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Fri, 31 Jul 2026 03:02:56 UTC
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=296467
--- Comment #13 from Mark Millard <marklmi26-fbsd@yahoo.com> ---
(In reply to wbe from comment #12)
In your context you had 2 distinct upstream repositories,
for sure. My note was off point for your details.
Your FreeBSD and FreeBSD-ports notation reported in
Comment 2 did not set priority for either, so both
had priority 0. Larger values are preferred.
man pkg.conf reports:
QUOTE
Repository configuration files are searched for in order of the
directories listed in the REPOS_DIR array, which defaults to /etc/pkg/
and /usr/local/etc/pkg/repos/.
. . .
Repositories are processed in the order they are found on the REPOS_DIR
search path, with individual repository configuration files in the same
directory processed in alphabetical order. Settings from files later in
the search path will override those from earlier ones. Packages are
selected preferentially out of all the repositories that contain them
from the repository with the highest priority, so long as they are
suitable to solve the necessary dependency requirements. However, this
preference may be overruled when CONSERVATIVE_UPGRADE is set to true, in
which case a package will as far as possible always be upgraded from the
same repository the older installed version came from, as given in the
repository annotation of the installed package. See pkg-repository(5)
for details.
END QUOTE
Note that with the same priority and the same port-package name, the
above wording does not indicate which repository would or should be
used. Lack of making repositories with duplicate port-package names
have distinct priorities leads to unspecified behavior under this
wording. Making the priorities distinct is something that should be
done when there are such duplications across enabled repositories.
--
You are receiving this mail because:
You are on the CC list for the bug.
You are the assignee for the bug.