From mboxrd@z Thu Jan 1 00:00:00 1970 From: Efraim Flashner Subject: Re: Fixing package-with-python2 (was: Package transformations) Date: Mon, 1 Feb 2016 18:35:38 +0200 Message-ID: <20160201183538.531633e3@debian-netbook> References: Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; boundary="Sig_/vClzsEyTiyQbB3JTSh9yrPl"; protocol="application/pgp-signature" Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:38291) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aQHSB-0006bQ-Jw for guix-devel@gnu.org; Mon, 01 Feb 2016 11:35:52 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1aQHS7-0008Ny-Ik for guix-devel@gnu.org; Mon, 01 Feb 2016 11:35:51 -0500 In-Reply-To: List-Id: "Development of GNU Guix and the GNU System distribution." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-devel-bounces+gcggd-guix-devel=m.gmane.org@gnu.org Sender: guix-devel-bounces+gcggd-guix-devel=m.gmane.org@gnu.org To: "Thompson, David" Cc: guix-devel --Sig_/vClzsEyTiyQbB3JTSh9yrPl Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable On Mon, 1 Feb 2016 08:49:10 -0500 "Thompson, David" wrote: > On Mon, Feb 1, 2016 at 8:06 AM, Efraim Flashner w= rote: >=20 > > I looked over the commit but not deeply enough yet, would it be possibl= e to > > use some of the logic in this to fix the package-with-python2 issue? =20 >=20 > Here's a potential solution for 'package-with-python2': module > introspection. AIUI, the issue is that some Python 2 packages need > extra manual tweaking, but 'package-with-python2' creates package > variants without these tweaks. Our algorithm could look up > 'python2-foo' in (gnu packages python) and use that package object, if > it exists. This would stop the recursive transformation for that > branch of the dependency graph and allow us to tweak Python 2 variants > as needed without fear. Not all of our python packages are in python.scm. Currently in guix/build-system/python.scm we have: (define package-with-python2 ;; Note: delay call to 'default-python2' until after the 'arguments' field ;; of packages is accessed to avoid a circular dependency when evaluating ;; the top-level of (gnu packages python). (package-with-explicit-python (delay (default-python2)) "python-" "python2-")) Excuse the code, but I think we're looking for something like: (define package-with-python2 (if (exists? python2-foo) (python2-foo) (package-with-explicit-python (delay (default-python2)) "python-" "python2-")) > Also, somewhat unrelated, package-with-python2 could add setuptools as > an input to these packages so we can remove all the unnecessary usage > of it in Python 3 packages. >=20 > Thoughts? That's something I was thinking of. --=20 Efraim Flashner =D7=90=D7=A4=D7=A8=D7=99=D7=9D = =D7=A4=D7=9C=D7=A9=D7=A0=D7=A8 GPG key =3D A28B F40C 3E55 1372 662D 14F7 41AA E7DC CA3D 8351 Confidentiality cannot be guaranteed on emails sent or received unencrypted --Sig_/vClzsEyTiyQbB3JTSh9yrPl Content-Type: application/pgp-signature Content-Description: OpenPGP digital signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v2 iQIcBAEBCgAGBQJWr4lbAAoJEPTB05F+rO6TV9oQAKPBbkAqANV4GUvmjI0Gidoh 00Bj++WfJpyI2DCEJCOY/YwWBcQaVOph5dDwoHS5fj8kNPvWDrxMniHJ1gYu4vwm A0fLm5uPnw+3W201P62X2hP7z4LCWnrDtsXBwPDsFmnxpEhw6ZqndzQe+Pmox523 F7NhqLLRrYrV853wpQ6c+qW0j+sdORYNuup2nrAaPh/X8ubAbauBR5pmpYuRu7p5 YIgEtHWfhyutat9KDffFwavrMZrgmiOyxoZU4fe/h1BmFmZe67aA6xKlKXBH3Wj+ ipPAqOHReWLyNSRLOIkbBNwkZRhd7zY64Z3UnAGQa9esqLWZdTewnaQO34DI92qR e7MQNzu2pA6RNOw7UO5hqvurcdlZLaLyas6GlshcwlXbRIaFx0lWzJMgWf+oZsf0 Whr0M4iNVyEYiSA5LLIle78Xg9W5HY4gl2WEh296wULM5rd8b2chaLq1IMnXWujh IbcMGLXpECeUL38GgSaDz9d615276RlM8kU9safEckwnZP9zHgZ/EM6D18lCOnfx BFX2vIPzbArjRvVqEIZoM9AVXobfQ+VfQfEU1FIE3v4YpWuhx62v50OOP7+ZRJow lEb3B9nsMQe4Flffej7JxtyksNMZIGqTiM+2kKtaO9tkgDZZWiGrqV2jDM1sjvXc lu28WwF1mHg4sRbeP/aQ =jYkz -----END PGP SIGNATURE----- --Sig_/vClzsEyTiyQbB3JTSh9yrPl--