Re: Python version dependencies in pkg

From: Dan Mahoney <freebsd_at_gushi.org>
Date: Tue, 27 Sep 2022 01:13:13 UTC

> On Sep 26, 2022, at 09:27, Kevin Oberman <rkoberman@gmail.com> wrote:
> 
> On Mon, Sep 26, 2022 at 2:58 AM Dan Mahoney <freebsd@gushi.org <mailto:freebsd@gushi.org>> wrote:
> All,
> 
> A quick question:
> 
> If a pkg depends on python, but not a specific version, it will simply pick a version to install (I guess, whatever version was the default when the pkg was built, 3.8 right now), correct?
> 
> If you have 3.9 installed, that will satifsfy dependencies, and it won't install python3.8, correct? Or are the dependent versions for interpretec languages in pkg locked to whatever the default is?
> 
> Assuming "any python will work", If you have 3.8 installed, and later install 3.9 -- is there any easy way to point your package at the new version as the new dependency, without deinstalling/reinstalling it?
> 
> -Dan
> 
> It will use the version specified as default in /usr/ports/Mk/bsd.default-versions.mk <http://bsd.default-versions.mk/>.

To be clear, I'm talking about pkg install, not port building.

So I understand -- that value is somehow baked in to the package tree somewhere?  Because pkg alone doesn't look at the ports tree on the installing machine (you do not need to have ports extracted to install packages), nor do I believe it looks at make.conf,

If so, where in pkg do I find the default version?  Is it somewhere in the repository that's fetched before I install any packages?

-Dan