From nobody Thu Sep 29 06:39:39 2022 X-Original-To: ports@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4MdNyk0QMVz4dbS3 for ; Thu, 29 Sep 2022 06:40:14 +0000 (UTC) (envelope-from Alexander@leidinger.net) Received: from mailgate.Leidinger.net (mailgate.leidinger.net [IPv6:2a00:1828:2000:313::1:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature ECDSA (P-256) client-digest SHA256) (Client CN "mailgate.leidinger.net", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4MdNyh2p0Vz423F for ; Thu, 29 Sep 2022 06:40:12 +0000 (UTC) (envelope-from Alexander@leidinger.net) Received: from outgoing.leidinger.net (p5b165562.dip0.t-ipconnect.de [91.22.85.98]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-256) server-digest SHA256 client-signature ECDSA (P-256) client-digest SHA256) (Client CN "outgoing.leidinger.net", Issuer "R3" (verified OK)) by mailgate.Leidinger.net (Postfix) with ESMTPSA id 954ED1C44; Thu, 29 Sep 2022 08:39:59 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=leidinger.net; s=outgoing-alex; t=1664433599; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=rZCMLABlyws5lZ5uMV3VGV9RBtY1YAC+r6Sr2/TkmWA=; b=S2hcth6zmF/uQI1CuNzvr6vXIiXICorkoPf3o74ly1xMrEQDSttyuXnFZ5VYWk1Bsbdgyf rAYN+xaZ0T+9C3339FWP09SOYRG10/sNkS6HCU7LHDjoCFJm+1nI+W72adOa98Rm/uXeIA RdHNtmTaPqAdOS4O2ahYro1XX42e+2a3xyCGR2bYIsDe5RYTeAi/+fj2Yh6D17VZanfzZc 2VYNHmxK6MPCtUHs8QsX2sPOOn10jcXWCjstJ3SU2pk/qvxPawnlVHwcJyBJUhl9oFsgZC VR4NJhr8KoyVf77Epev/U2jOpW91Dk7A6hPawe4qWETKWKauZOmUh5HMFVBTqg== Received: from webmail.leidinger.net (localhost [127.0.0.1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-256) server-digest SHA256) (Client did not present a certificate) by outgoing.leidinger.net (Postfix) with ESMTPS id 07F19B3AF; Thu, 29 Sep 2022 08:39:40 +0200 (CEST) Date: Thu, 29 Sep 2022 08:39:39 +0200 Message-ID: <20220929083939.Horde.Viq2uLBgUctcrsgmaJxN_1u@webmail.leidinger.net> From: Alexander Leidinger To: Dan Mahoney Cc: ports@freebsd.org Subject: Re: Python version dependencies in pkg References: <8B490359-27A3-410C-AE98-C1362D4FA9F0@gushi.org> <89D2B2D7-FA3D-46F5-A93B-4846950A157C@gushi.org> <65597c37-813b-d0ed-ea9f-8591b68cf097@gwdg.de> In-Reply-To: <65597c37-813b-d0ed-ea9f-8591b68cf097@gwdg.de> Accept-Language: de,en Content-Type: multipart/signed; boundary="=_jbiGvh8gvmRC3Hz_jA88yWN"; protocol="application/pgp-signature"; micalg=pgp-sha256 List-Id: Porting software to FreeBSD List-Archive: https://lists.freebsd.org/archives/freebsd-ports List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-freebsd-ports@freebsd.org X-BeenThere: freebsd-ports@freebsd.org MIME-Version: 1.0 X-Rspamd-Queue-Id: 4MdNyh2p0Vz423F X-Spamd-Bar: ------ Authentication-Results: mx1.freebsd.org; dkim=pass header.d=leidinger.net header.s=outgoing-alex header.b=S2hcth6z; dmarc=pass (policy=quarantine) header.from=leidinger.net; spf=pass (mx1.freebsd.org: domain of Alexander@leidinger.net designates 2a00:1828:2000:313::1:5 as permitted sender) smtp.mailfrom=Alexander@leidinger.net X-Spamd-Result: default: False [-6.10 / 15.00]; SIGNED_PGP(-2.00)[]; NEURAL_HAM_LONG(-1.00)[-1.000]; NEURAL_HAM_SHORT(-1.00)[-0.999]; NEURAL_HAM_MEDIUM(-1.00)[-0.996]; DMARC_POLICY_ALLOW(-0.50)[leidinger.net,quarantine]; R_SPF_ALLOW(-0.20)[+mx]; MIME_GOOD(-0.20)[multipart/signed,text/plain]; R_DKIM_ALLOW(-0.20)[leidinger.net:s=outgoing-alex]; MLMMJ_DEST(0.00)[ports@freebsd.org]; RCVD_VIA_SMTP_AUTH(0.00)[]; MIME_TRACE(0.00)[0:+,1:+,2:~]; FROM_EQ_ENVFROM(0.00)[]; RCPT_COUNT_TWO(0.00)[2]; TO_MATCH_ENVRCPT_SOME(0.00)[]; MID_RHS_MATCH_FROMTLD(0.00)[]; FROM_HAS_DN(0.00)[]; ARC_NA(0.00)[]; DKIM_TRACE(0.00)[leidinger.net:+]; TO_DN_SOME(0.00)[]; ASN(0.00)[asn:34240, ipnet:2a00:1828::/32, country:DE]; RCVD_COUNT_THREE(0.00)[3]; RCVD_TLS_ALL(0.00)[] X-ThisMailContainsUnwantedMimeParts: N This message is in MIME format and has been PGP signed. --=_jbiGvh8gvmRC3Hz_jA88yWN Content-Type: text/plain; charset=utf-8; format=flowed; DelSp=Yes Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Quoting Rainer Hurling (from Thu, 29 Sep 2022=20=20 06:43:49=20+0200): > Hi Dan, > > Am 28.09.22 um 23:01 schrieb Dan Mahoney: >> >> >>> On Sep 26, 2022, at 20:22, Kevin Oberman >>=20> wrote: >>> >>> On Mon, Sep 26, 2022, 18:13 Dan Mahoney >>=20> wrote: >>> >>> >>> >>>> On Sep 26, 2022, at 09:27, Kevin Oberman >>> > wrote: >>>> >>>> On Mon, Sep 26, 2022 at 2:58 AM Dan Mahoney >>> > 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 >>>> . >>> >>> 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?=C2=A0 Because pkg alone doesn't look at the ports tr= ee >>> 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?=C2=A0 Is it >>> somewhere in the repository that's fetched before I install any >>> packages? >>> >>> -Dan >>> >>> >>> You are correct.=C2=A0 But the packages are built using the same=20=20 >>>=20Makefile and the same defaults as when built from ports for the=20=20 >>>=20specified version of FreeBSD as if it was built from ports. The Mk=20= =20 >>>=20files are updated with ports, so all packages change when the=20=20 >>>=20change is committed to the defaults file, though they will only=20=20 >>>=20take effect when the quarter changes unless you're using LATEST=20=20 >>>=20packages. >> >> Okay, so in either the package file, or the repo file, is there a=20=20 >>=20bit that says "whatever is the default" or that explicitly says "if=20= =20 >>=20there's not a python, install 3.8"? > > There is PYTHON_DEFAULT (set to 3.9 ATM) in=20=20 >=20ports/Mk/bsd.default-versions.mk. You can override this for example=20= =20 >=20by an entry in /etc/make.conf: > > DEFAULT_VERSIONS+=3D python=3D3.10 python3=3D3.10 > >> >> I realize I'm asking weird minute questions, but I'm noticing that=20=20 >>=20across our fleet we have some blend of machines that are 3.7, 3.8,=20= =20 >>=20and 3.9, and trying to just remove 3.7 attempts to deinstall=20=20 >>=20packages that would work with 3.8. > > To update from one Python version to another, there are descriptions=20= =20 >=20in /usr/ports/UPDATING, see entry from 20220626. > > After changing Python itself (i.e. from 3.7 to 3.9), rebuilding=20=20 >=20depending py3x-packages will do this version change for you (i.e.=20=20 >=20from py3.7-* to py3.9-*, ...). It works via the so called flavors. To extend a little bit on that: "pkg info | grep py3" will give you a list of ports which are=20=20 depending=20on a specific python version. If it lists py37-xxx it means=20= =20 the=20xxx port depends upon python 3.7. If you then delete python 3.7=20=20 pkg=20will also ask you if it is ok to delete all the py37-* ports. So for a given system with already installed ports it is not simply=20=20 installing=20python 3.9 and deleting 3.7. It is also updating all the=20=20 ports=20which depend upon 3.7. Bye, Alexander. --=20 http://www.Leidinger.net=20Alexander@Leidinger.net: PGP 0x8F31830F9F2772BF http://www.FreeBSD.org netchild@FreeBSD.org : PGP 0x8F31830F9F2772BF --=_jbiGvh8gvmRC3Hz_jA88yWN Content-Type: application/pgp-signature Content-Description: Digitale PGP-Signatur Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v2 iQIzBAABCAAdFiEER9UlYXp1PSd08nWXEg2wmwP42IYFAmM1PaoACgkQEg2wmwP4 2IbpBA/8Dgaw+I+7TXWP5/70BrCuu0sJlIZsyYuM5lB6ELgBj3SDYo1b8y7CSsJO gnAFtxpBIuyJdYgdB4xsQDxAqwL2p2OyD76jLDuAKDDXNtBqFeV7/RR7jbUu4Yq3 QiVlO1V4UVVDu/asO1dTGa6O2f7UCa2D5ibH1KpnpsCGk2KvQ39OkDVCF4Y1vPlN D68RamGIz1/dQMVJb3mISJa5wkNJGKeatBxnb3dvqOlZkv4CaeLPa75/6fKQpBuP spzLWQf2+kGfTZGPL0X6ADKmLR3r+/xDvqU01NvFywfcjyx9gjCskXGCvfk9d87r 8YB5V/1PTor13JBfDn7lSHYN796I+b1tlHpAxjLXs5qMWY4rMw0ms0BPDOoZ2f9o H8z+IK8A7vuzwC78bU8oCgGCNW5SdmrZKe/0Ak7GMcljl/HnU7si+sVUBydASgNx w8wjd2hAWMYmi/AHu0cZb6Mm+lZzenncVgAns7P5gwOHDGmWT7IBCYfA7orcBOi7 4ryL3VkHQK2rlI6Yc3sTXSlA5JxtgkPtwfoJvxcVwv2jnPxtAsF/x4WhNj93NCwd wzGyo7I031eOkpfdI8QNa8r/EzCzKHpCq0k7w+8DSuIqoGO8Gma+gU6ELP5ggLze EhTs7Z7hFRHpriZeoWUtAFFl1L1mKAgu9DlPv9NgqWAotDbIAyY= =tkus -----END PGP SIGNATURE----- --=_jbiGvh8gvmRC3Hz_jA88yWN--