For base (PkgBase), pkg would be better being a "backend" for both installer and freebsd-update.
And I think kinda complexities are unavoidable, because src and ports are managed as individual git repo. Multiple "seemingly same but actually different" things exists. No mangling should happen, so both should be treated as different thing on installation and upgrades, just using the same tool to maintain distributions / packages. For example, clang from base on regular installation and clang from ports (pkg) on cross-toolchain installation shoud be treated as different thing, even if both has exactly same version, as their build options (configurations) and/or included components would be different. Otherwise, for devel/llvm* with the same major version as the one on base, install missing components only should be 100% sufficient, but it's not actually. There should be much more components to consider. And, IMHO, switching from current distributions (base, kern,...) to finer grained PkgBase is "back to Unixism". Unix is (IIUC, at least initially) designed to be fine-grained, sharing components as "parts" as much as possible. Shared objects, piped small tools and so on. But maintained and developed "as a whole" in single project, as much as possible. On Mon, 04 Aug 2025 10:14:25 +0200 vermaden <verma...@interia.pl> wrote: > Both approaches have their own ups and downs. > > One tool to rule them all is not always the best way. > > It can be ... but it must be sensible and be implemented really intelligently. > > > > > > > > > Temat: Re: PKGBASE Removes FreeBSD Base System Feature > Data: 2025-08-04 10:03 > Nadawca: "Mariusz Zaborski" <osho...@freebsd.org> > Adresat: "vermaden" <verma...@interia.pl>; > DW: "Don Lewis" <truck...@freebsd.org>; "Daniel Morante" > <dan...@morante.net>; "stable@freebsd.org" <stable@freebsd.org>; > > > > > > > >> Also - nothing stands in the way that pkg(8) will check pkgbase(8) what > >> PKGBASE packages are installed and then install needed Base System > >> packages with pkgbase(8) to satisfy its pkg(8) dependencies. > > > > But this adds additional complexity, as you have to manage two separate > > databases almost as if they were one. > > Where do you define this dependancy? Can other independent repose also use > > this feature? How to tell which repo depends on which? > > Can other repos introduce new databases? > > > > I think the correct solution is to have a single tool. > > Then you introduce packages like FreeBSD-full, FreeBSD-lite, or > > FreeBSD-jail (or flavours, whatever works). These packages are marked as > > vital and depend on different base system packages. > > > > For example, FreeBSD-full might depend on FreeBSD-rescue, while > > FreeBSD-jail does not. > > > > And that’s all there is to it. > > > > If you try to remove FreeBSD-rescue, you can’t - because it would require > > removing FreeBSD-full as well, which is vital and can't be removed. > > In the case of a jail installation or a minimal FreeBSD setup, if you > > install something like FreeIPA and it requires FreeBSD-krb in your jail, it > > will be installed automatically. > > When you later remove FreeIPA, and no other package depends on FreeBSD-krb, > > it can be removed as well. > > > > I think something similar was mentioned by bapt@ on > > gh: https://github.com/freebsd/pkg/issues/2485#issuecomment-3135130067 > > > > On Mon, 4 Aug 2025 at 09:19, vermaden <verma...@interia.pl> wrote: > > > >> Hi. > >> > >> That is a good point - but if I have too choose between a feature You just > >> mentioned and really separated and safe Base System from the third party > >> pkg(8) packages operations - then I choose Base System safety. > >> > >> Also - nothing stands in the way that pkg(8) will check pkgbase(8) what > >> PKGBASE packages are installed and then install needed Base System > >> packages with pkgbase(8) to satisfy its pkg(8) dependencies. > >> > >> Regards, > >> vermaden > >> > >> Temat: Re: PKGBASE Removes FreeBSD Base System Feature > >> Data: 2025-08-04 8:58 > >> Nadawca: "Mariusz Zaborski" &lt;osho...@freebsd.org> > >> Adresat: "Don Lewis" &lt;truck...@freebsd.org>; > >> DW: "Daniel Morante" &lt;dan...@morante.net>; stable@freebsd.org; > >> > >>> > >>>>(1) > >>>> Keep pkg(8) for third party packages with /etc/pkg and > >>>> /usr/local/etc/pkg and /var/db/pkg dirs for configuration. > >>>> > >>>> Use separate pkgbase(8) with /etc/pkgbase and /usr/local/etc/pkgbase and > >>>> /var/db/pkgbase dirs for managing PKGBASE packages. By pkgbase(8) I have > >>>> the same pkg(8) project in mind - just renamed as pkgbase(8) and with > >>>> */pkgbase dirs instead of */pkg. > >>> > >>> I can imagine a situation where a third-party package depends on a > >>> package from the base system. > >>> When you bootstrap a jail or your machine, you might start with a minimal > >>> installation, but I would expect pkg&nbsp;to automatically figure out > >>> what needs to be installed when it's required. > >>> > >>> On Mon, 4 Aug 2025 at 08:37, Don Lewis &lt;truck...@freebsd.org> > >>> wrote: > >>> > >>>> On&nbsp; 3 Aug, Daniel Morante wrote: > >>>>> I just took a look at > >>>>> https://pkg.freebsd.org/FreeBSD:15:amd64/base_latest/ > >>>>> &lt;https://pkg.freebsd.org/FreeBSD:15:amd64/base_latest/> and I am > >>>>> instantly disappointed. I was a fan of the idea, but seeing how they > >>>>> decided to make one package for each item is a massive bummer. Why > >>>>> would > >>>>> you split it up this way? When when you install the Mozilla Firefox via > >>>>> package, you don't install every file individually as a separate > >>>>> package. > >>>>> > >>>>> It's the same concept for FreeBSD. All these files make up a single > >>>>> entity "FreeBSD" the operating system. Why on earth would you install > >>>>> each item that's required to run FreeBSD as a separate package? All > >>>>> this > >>>>> will do is create increased overhead when installing the system (as > >>>>> each > >>>>> package must go through it's verification and transaction process), and > >>>>> all sorts of trouble down the line when dependency hell sets in. > >>>>> > >>>>> This is not the FreeBSD way.&nbsp; Very sad, concerned, and > >>>>> disappointed at > >>>>> this design choice. > >>>> > >>>> What benefit is there to installing setuid program lpr on an > >>>> appliance-like system without a printer other than enlarging the attack > >>>> surface?&nbsp; If I remove it, do I have to build my own > >>>> freebsd-update > >>>> system to keep things up to date? > >>>> > >>>> I frequently want to build small systems without a compiler if I know > >>>> that I will never build software on them. -- Tomoaki AOKI <junch...@dec.sakura.ne.jp>