From unknown Sat Jun 21 10:35:20 2025 X-Loop: help-debbugs@gnu.org Subject: [bug#44656] [PATCH] Upgrade pypy3 Resent-From: Lars-Dominik Braun Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Sun, 15 Nov 2020 12:40:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 44656 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 44656@debbugs.gnu.org X-Debbugs-Original-To: guix-patches@gnu.org Received: via spool by submit@debbugs.gnu.org id=B.16054439835767 (code B ref -1); Sun, 15 Nov 2020 12:40:01 +0000 Received: (at submit) by debbugs.gnu.org; 15 Nov 2020 12:39:43 +0000 Received: from localhost ([127.0.0.1]:52709 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1keHJb-0001Ug-PB for submit@debbugs.gnu.org; Sun, 15 Nov 2020 07:39:43 -0500 Received: from lists.gnu.org ([209.51.188.17]:51586) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1keHJX-0001UX-H2 for submit@debbugs.gnu.org; Sun, 15 Nov 2020 07:39:30 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]:37508) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1keHJX-0000MQ-9n for guix-patches@gnu.org; Sun, 15 Nov 2020 07:39:27 -0500 Received: from mout-p-202.mailbox.org ([80.241.56.172]:36728) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_CHACHA20_POLY1305:256) (Exim 4.90_1) (envelope-from ) id 1keHJS-0003xj-4X for guix-patches@gnu.org; Sun, 15 Nov 2020 07:39:26 -0500 Received: from smtp1.mailbox.org (smtp1.mailbox.org [IPv6:2001:67c:2050:105:465:1:1:0]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-384) server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by mout-p-202.mailbox.org (Postfix) with ESMTPS id 4CYsGD653nzQkHd for ; Sun, 15 Nov 2020 13:39:16 +0100 (CET) X-Virus-Scanned: amavisd-new at heinlein-support.de DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=6xq.net; s=MBO0001; t=1605443954; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=oyJIDXJI4qiuWp2UrmXpB4Y1dFtMBJ7E18KONefv5jM=; b=iliSyyIgYdZLLP1XSXwdB0F8Q1+VTffHOBaouE1aQ2N15DCVA9roj/2S31MatTZkAbkuwk pXfkuc3cpJHB4X7J+LLJmVR2n2BUd7HTTWx0KeL5ikuvj9NGxgmTZjqcg4tzPrDYA15vKj fHCKyHN5Y9fD4EBTDrp7/mxiCmuFc5D7ZTSxkaEnp4ed4DRarAOtUVbqSWOzraqSrCavMB ycwdb94aKLmQ/oWUKsYe86tH4zNSpV5Di8QxYDNLRcDOBwqqhxzkYGyFrLBS1ag1iIiN05 o70DpI6w9tyFfOK7oF+UJCmrrH4ZIAmapDRAHqft/xHwfCMBlBH8OHWikuCkNA== Received: from smtp1.mailbox.org ([80.241.60.240]) by spamfilter06.heinlein-hosting.de (spamfilter06.heinlein-hosting.de [80.241.56.125]) (amavisd-new, port 10030) with ESMTP id d69lETnppCky for ; Sun, 15 Nov 2020 13:39:12 +0100 (CET) Date: Sun, 15 Nov 2020 13:39:11 +0100 From: Lars-Dominik Braun Message-ID: <20201115123911.GA1956@noor.fritz.box> MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="J/dobhs11T7y2rNN" Content-Disposition: inline Content-Transfer-Encoding: 8bit X-MBO-SPAM-Probability: X-Rspamd-Score: -10.75 / 15.00 / 15.00 X-Rspamd-Queue-Id: 9687E1831 X-Rspamd-UID: c28279 Received-SPF: pass client-ip=80.241.56.172; envelope-from=lars@6xq.net; helo=mout-p-202.mailbox.org X-detected-operating-system: by eggs.gnu.org: First seen = 2020/11/15 07:39:17 X-ACL-Warn: Detected OS = Linux 2.2.x-3.x [generic] [fuzzy] X-Spam_score_int: -27 X-Spam_score: -2.8 X-Spam_bar: -- X-Spam_report: (-2.8 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_LOW=-0.7, RCVD_IN_MSPIKE_H4=-0.01, RCVD_IN_MSPIKE_WL=-0.01, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-Spam-Score: -1.7 (-) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -0.3 (/) --J/dobhs11T7y2rNN Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Hi, the first patch in this series upgrades pypy3 to 7.3.2 and the second adjusts several aspects of the package. Lars --J/dobhs11T7y2rNN Content-Type: text/x-diff; charset=us-ascii Content-Disposition: attachment; filename="0001-gnu-pypy3-Update-to-7.3.2.patch" >From 0669431bc4ee103cf159f5f1d64684e6db8d6bb5 Mon Sep 17 00:00:00 2001 From: Lars-Dominik Braun Date: Sat, 17 Oct 2020 13:46:21 +0200 Subject: [PATCH 1/2] gnu: pypy3: Update to 7.3.2. * gnu/packages/python.scm (pypy3): Update to 7.3.2. --- gnu/packages/python.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gnu/packages/python.scm b/gnu/packages/python.scm index 43704bccae..8ef8ae2e1d 100644 --- a/gnu/packages/python.scm +++ b/gnu/packages/python.scm @@ -688,14 +688,14 @@ ease from the desktop to a microcontroller or embedded system.") (define-public pypy3 (package (name "pypy3") - (version "7.3.1") + (version "7.3.2") (source (origin (method url-fetch) - (uri (string-append "https://bitbucket.org/pypy/pypy/downloads/" ; + (uri (string-append "https://downloads.python.org/pypy/" "pypy3.6-v" version "-src.tar.bz2")) (sha256 (base32 - "10zsk8jby8j6visk5mzikpb1cidvz27qq4pfpa26jv53klic6b0c")) + "03f1fdw6yk2mypa9pbmgk26r8y1hhmw801l6g36zry9zsvz7aqgx")) (patches (search-patches "pypy3-7.3.1-fix-tests.patch")))) (build-system gnu-build-system) (native-inputs -- 2.26.2 --J/dobhs11T7y2rNN Content-Type: text/x-diff; charset=utf-8 Content-Disposition: attachment; filename="0002-gnu-pypy3-Various-package-fixes.patch" Content-Transfer-Encoding: 8bit >From caf5e4bf9acd10f91de2e6a9c60185475144a1b9 Mon Sep 17 00:00:00 2001 From: Lars-Dominik Braun Date: Sun, 15 Nov 2020 10:54:26 +0100 Subject: [PATCH 2/2] gnu: pypy3: Various package fixes. * gnu/packages/python.scm (pypy3) [patches]: Add new patch. [inputs]: Remove bash-minimal and add nss-certs. [native-inputs]: Remove nss-certs here. [arguments]: Use gdbm compat library, add 2to3 binary. [native-search-paths]: Add search path. * gnu/packages/patches/pypy3-7.3.1-ssl-paths.patch: New file. * gnu/local.mk: Add it. --- gnu/local.mk | 1 + .../patches/pypy3-7.3.1-ssl-paths.patch | 41 +++++++ gnu/packages/python.scm | 109 ++++++++++++------ 3 files changed, 116 insertions(+), 35 deletions(-) create mode 100644 gnu/packages/patches/pypy3-7.3.1-ssl-paths.patch diff --git a/gnu/local.mk b/gnu/local.mk index 91a3295e75..b644391a11 100644 --- a/gnu/local.mk +++ b/gnu/local.mk @@ -1536,6 +1536,7 @@ dist_patch_DATA = \ %D%/packages/patches/python-unittest2-remove-argparse.patch \ %D%/packages/patches/python-waitress-fix-tests.patch \ %D%/packages/patches/pypy3-7.3.1-fix-tests.patch \ + %D%/packages/patches/pypy3-7.3.1-ssl-paths.patch \ %D%/packages/patches/qemu-build-info-manual.patch \ %D%/packages/patches/qemu-glibc-2.27.patch \ %D%/packages/patches/qrcodegen-cpp-make-install.patch \ diff --git a/gnu/packages/patches/pypy3-7.3.1-ssl-paths.patch b/gnu/packages/patches/pypy3-7.3.1-ssl-paths.patch new file mode 100644 index 0000000000..d21133b4ae --- /dev/null +++ b/gnu/packages/patches/pypy3-7.3.1-ssl-paths.patch @@ -0,0 +1,41 @@ +Fix default certificate search path, still allowing the user to override it +with environment variables. + +--- a/lib_pypy/_cffi_ssl/_stdssl/__init__.py ++++ b/lib_pypy/_cffi_ssl/_stdssl/__init__.py +@@ -1679,20 +1679,9 @@ def get_default_verify_paths(): + https://golang.org/src/crypto/x509/root_linux.go (for the files) + ''' + certFiles = [ +- "/etc/ssl/certs/ca-certificates.crt", # Debian/Ubuntu/Gentoo etc. +- "/etc/pki/tls/certs/ca-bundle.crt", # Fedora/RHEL 6 +- "/etc/ssl/ca-bundle.pem", # OpenSUSE +- "/etc/pki/tls/cacert.pem", # OpenELEC +- "/etc/pki/ca-trust/extracted/pem/tls-ca-bundle.pem", # CentOS/RHEL 7 +- "/etc/ssl/cert.pem", # Alpine Linux + ] + certDirectories = [ +- "/etc/ssl/certs", # SLES10/SLES11 +- "/system/etc/security/cacerts", # Android +- "/usr/local/share/certs", # FreeBSD +- "/etc/pki/tls/certs", # Fedora/RHEL +- "/etc/openssl/certs", # NetBSD +- "/var/ssl/certs", # AIX ++ "@GUIX_CERT_PATH@", + ] + + # optimization: reuse the values from a local varaible +@@ -1707,9 +1696,10 @@ def get_default_verify_paths(): + ofile = _cstr_decode_fs(lib.X509_get_default_cert_file()) + odir = _cstr_decode_fs(lib.X509_get_default_cert_dir()) + +- if os.path.exists(ofile) and os.path.exists(odir): +- get_default_verify_paths.retval = (ofile_env, ofile, odir_env, odir) +- return get_default_verify_paths.retval ++ if not os.path.exists(ofile): ++ ofile = None ++ if not os.path.exists(odir): ++ odir = None + + # OpenSSL didn't supply the goods. Try some other options + for f in certFiles: diff --git a/gnu/packages/python.scm b/gnu/packages/python.scm index 8ef8ae2e1d..c0bd3335e3 100644 --- a/gnu/packages/python.scm +++ b/gnu/packages/python.scm @@ -696,7 +696,8 @@ ease from the desktop to a microcontroller or embedded system.") (sha256 (base32 "03f1fdw6yk2mypa9pbmgk26r8y1hhmw801l6g36zry9zsvz7aqgx")) - (patches (search-patches "pypy3-7.3.1-fix-tests.patch")))) + (patches (search-patches "pypy3-7.3.1-fix-tests.patch" + "pypy3-7.3.1-ssl-paths.patch")))) (build-system gnu-build-system) (native-inputs `(("python-2" ,python-2) @@ -704,13 +705,13 @@ ease from the desktop to a microcontroller or embedded system.") ("tar" ,tar) ; Required for package.py ("python2-pycparser" ,python2-pycparser) ("python2-hypothesis" ,python2-hypothesis) - ("nss-certs" ,nss-certs) ; For ssl tests ("gzip" ,gzip))) (inputs `(("libffi" ,libffi) ("zlib" ,zlib) ("ncurses" ,ncurses) ("openssl" ,openssl) + ("nss-certs" ,nss-certs) ; For ssl module ("expat" ,expat) ("bzip2" ,bzip2) ("sqlite" ,sqlite) @@ -718,10 +719,9 @@ ease from the desktop to a microcontroller or embedded system.") ("tcl" ,tcl) ("tk" ,tk) ("glibc" ,glibc) - ("bash-minimal" ,bash-minimal) ; Used as /bin/sh ("xz" ,xz))) ; liblzma (arguments - `(#:tests? #f ;FIXME: Disabled for now, there are many tests failing. + `(#:tests? #f ;FIXME: Disabled for now, there are many tests failing. #:modules ((ice-9 ftw) (ice-9 match) (guix build utils) (guix build gnu-build-system)) #:phases (modify-phases %standard-phases @@ -750,6 +750,11 @@ ease from the desktop to a microcontroller or embedded system.") (substitute* '("lib_pypy/_curses_build.py") ;; Find curses (("/usr/local") (assoc-ref inputs "ncurses"))) + (substitute* '("lib_pypy/_dbm.py") + ;; Use gdbm compat library, so we don’t need to pull in bdb + (("ctypes.util.find_library\\('db'\\)") + (string-append "'" (assoc-ref inputs "gdbm") + "/lib/libgdbm_compat.so'"))) (substitute* '("lib_pypy/_sqlite3_build.py") ;; Always use search paths (("sys\\.platform\\.startswith\\('freebsd'\\)") "True") @@ -761,11 +766,18 @@ ease from the desktop to a microcontroller or embedded system.") "/lib/libsqlite3.so.0'"))) (substitute* '("lib-python/3/subprocess.py") ;; Fix shell path - (("/bin/sh") - (string-append (assoc-ref inputs "bash-minimal") "/bin/sh"))) + (("/bin/sh") (which "sh"))) (substitute* '("lib-python/3/distutils/unixccompiler.py") ;; gcc-toolchain does not provide symlink cc -> gcc (("\"cc\"") "\"gcc\"")) + (substitute* '("lib_pypy/_cffi_ssl/_stdssl/__init__.py") + ;; Add nss-certs to default certificate search path, + ;; otherwise every packages has to specify nss-certs and + ;; openssl as input to set the proper env variables. + ;; Depends on -ssl-paths.patch. + (("@GUIX_CERT_PATH@") + (string-append (assoc-ref inputs "nss-certs") + "/etc/ssl/certs"))) #t)) (add-after 'unpack 'set-source-file-times-to-1980 @@ -785,7 +797,8 @@ ease from the desktop to a microcontroller or embedded system.") (string-append "--make-jobs=" (number->string (parallel-job-count))) "-Ojit" - "targetpypystandalone")) + "targetpypystandalone" + "--allworkingmodules")) ;; Build c modules and package everything, so tests work. (with-directory-excursion "pypy/tool/release" (unsetenv "PYTHONPATH") ; Do not use the system’s python libs: @@ -793,7 +806,12 @@ ease from the desktop to a microcontroller or embedded system.") ; attribute 'IntFlag' (invoke "python2" "package.py" "--archive-name" "pypy-dist" - "--builddir" (getcwd))))) + "--builddir" (getcwd)) + ;; install pip and setuptools into the dist directory. + ;; XXX: Breaks virtualenv, because it does not set +w + ;; on files copied from the store. + ;(invoke "pypy-dist/bin/pypy3" "-m" "ensurepip") + ))) (replace 'check (lambda* (#:key tests? #:allow-other-keys) (if tests? @@ -811,32 +829,54 @@ ease from the desktop to a microcontroller or embedded system.") #t)) (replace 'install (lambda* (#:key inputs outputs #:allow-other-keys) - (with-directory-excursion "pypy/tool/release" - ;; Delete test data. - (for-each - (lambda (x) - (delete-file-recursively (string-append - "pypy-dist/lib-python/3/" x))) - '("tkinter/test" - "test" - "sqlite3/test" - "lib2to3/tests" - "idlelib/idle_test" - "distutils/tests" - "ctypes/test" - "unittest/test")) - ;; Patch shebang referencing python2 - (substitute* '("pypy-dist/lib-python/3/cgi.py" - "pypy-dist/lib-python/3/encodings/rot_13.py") - (("#!.+/bin/python") - (string-append "#!" (assoc-ref outputs "out") "/bin/pypy3"))) - (with-fluids ((%default-port-encoding "ISO-8859-1")) - (substitute* '("pypy-dist/lib_pypy/_md5.py" - "pypy-dist/lib_pypy/_sha1.py") - (("#!.+/bin/python") - (string-append "#!" (assoc-ref outputs "out") "/bin/pypy3")))) - (copy-recursively "pypy-dist" (assoc-ref outputs "out"))) - #t))))) + (let* ((out (assoc-ref outputs "out")) + (bin-pypy3 (string-append out "/bin/pypy3")) + (shebang-match-python "#!.+/bin/python") + (shebang-pypy3 (string-append "#!" bin-pypy3)) + (dist-dir "pypy/tool/release/pypy-dist")) + (with-directory-excursion dist-dir + ;; Delete test data. + (for-each + (lambda (x) + (delete-file-recursively (string-append + "lib-python/3/" x))) + '("tkinter/test" + "test" + "sqlite3/test" + "lib2to3/tests" + "idlelib/idle_test" + "distutils/tests" + "ctypes/test" + "unittest/test")) + ;; Patch shebang referencing python2 + (substitute* '("lib-python/3/cgi.py" + "lib-python/3/encodings/rot_13.py") + ((shebang-match-python) shebang-pypy3)) + (with-fluids ((%default-port-encoding "ISO-8859-1")) + (substitute* '("lib_pypy/_md5.py" + "lib_pypy/_sha1.py") + ((shebang-match-python) shebang-pypy3)))) + (copy-recursively dist-dir out) + ;; Make sure pypy3 is callable as python/python3, so we + ;; don’t have to patch every single package. + (symlink bin-pypy3 (string-append out "/bin/python")) + (symlink bin-pypy3 (string-append out "/bin/python3")) + ;; 2to3 is missing from pypy3, create it. + (let ((2to3 (string-append out "/bin/2to3"))) + (call-with-output-file 2to3 + (lambda (port) + (format port "#!~a~%" (string-append out "/bin/pypy3")) + (format port " +import sys +from lib2to3.main import main + +sys.exit(main('lib2to3.fixes'))"))) + (chmod 2to3 #o755)) + #t)))))) + (native-search-paths + (list (search-path-specification + (variable "PYTHONPATH") + (files '("lib/pypy3.6/site-packages"))))) (home-page "https://www.pypy.org/") (synopsis "Python implementation with just-in-time compilation") (description "PyPy is a faster, alternative implementation of the Python @@ -849,4 +889,3 @@ Python code natively, including C extensions.") license:bsd-3 ; lib_pypy/cffi/_pycparser/ply/ (license:non-copyleft "http://www.unicode.org/copyright.html"))))) - -- 2.26.2 --J/dobhs11T7y2rNN-- From unknown Sat Jun 21 10:35:20 2025 X-Loop: help-debbugs@gnu.org Subject: [bug#44656] [PATCH] Upgrade pypy3 Resent-From: Christopher Baines Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Sun, 15 Nov 2020 19:34:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 44656 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: Lars-Dominik Braun Cc: 44656@debbugs.gnu.org Received: via spool by 44656-submit@debbugs.gnu.org id=B44656.160546879013009 (code B ref 44656); Sun, 15 Nov 2020 19:34:02 +0000 Received: (at 44656) by debbugs.gnu.org; 15 Nov 2020 19:33:10 +0000 Received: from localhost ([127.0.0.1]:54201 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1keNlu-0003Nl-72 for submit@debbugs.gnu.org; Sun, 15 Nov 2020 14:33:10 -0500 Received: from mira.cbaines.net ([212.71.252.8]:42094) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1keNls-0003Nd-E5 for 44656@debbugs.gnu.org; Sun, 15 Nov 2020 14:33:09 -0500 Received: from localhost (188.30.135.14.threembb.co.uk [188.30.135.14]) by mira.cbaines.net (Postfix) with ESMTPSA id A1C6427BBF4; Sun, 15 Nov 2020 19:33:07 +0000 (GMT) Received: from capella (localhost [127.0.0.1]) by localhost (OpenSMTPD) with ESMTP id 0eba7305; Sun, 15 Nov 2020 19:33:05 +0000 (UTC) References: <20201115123911.GA1956@noor.fritz.box> User-agent: mu4e 1.4.13; emacs 27.1 From: Christopher Baines In-reply-to: <20201115123911.GA1956@noor.fritz.box> Message-ID: <87zh3ibekx.fsf@cbaines.net> Date: Sun, 15 Nov 2020 19:33:02 +0000 MIME-Version: 1.0 Content-Type: multipart/signed; boundary="=-=-="; micalg=pgp-sha512; protocol="application/pgp-signature" X-Spam-Score: -0.0 (/) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) --=-=-= Content-Type: text/plain Lars-Dominik Braun writes: > the first patch in this series upgrades pypy3 to 7.3.2 and the second > adjusts several aspects of the package. Hi, Given that the two patches really form just one change, the version change with the necessary other changes to the package, would it be possible to merge most or all of the two patches together? Effectively, anything that's essential to change about the pypy3 package when upgrading the version would ideally be in the same commit as the version change. One reason for this is that it makes the change easier to understand, as the actual changes are kept together in one commit. If there are things that aren't essential to change when changing the version, they're fine to have in subsequent commits/patches. Thanks, Chris --=-=-= Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQKlBAEBCgCPFiEEPonu50WOcg2XVOCyXiijOwuE9XcFAl+xgm5fFIAAAAAALgAo aXNzdWVyLWZwckBub3RhdGlvbnMub3BlbnBncC5maWZ0aGhvcnNlbWFuLm5ldDNF ODlFRUU3NDU4RTcyMEQ5NzU0RTBCMjVFMjhBMzNCMEI4NEY1NzcRHG1haWxAY2Jh aW5lcy5uZXQACgkQXiijOwuE9XeOxBAAjxUiFbjwBhrLCH8QC20e6dnL3C7QD9k4 LY7ojifc9uc7vymUURP+inAyKhNUdBcgiJexOeAofQWOjqwqMPRvc35rqCUmxGY2 IIbVPRU7W0kGWytMmwGorOlf4ON+gJ2lruwo3T09rHaHXAxBxQnPG8JIhzWZZUWC gLVvsMLnkeYbsRjF3Vsofj0FiK9cuYwgiVAGbwFjn4uPIxOVM22Esky/yxsYDQwN dVi7JNKpe0iZTuVEoMdZ0NhZ4RhZ/D6CjN8GPMCj7KwxxAoPzprZX/kSUBZrILIt QFXSCAiCMNrnLGunlc+xWf+DTxb1ALcNUIszzbfU8xjfcYWsR4ANg6IS8LHQWvAu HiHXjtKbLe5Jsy+DYUsOb9ZOoJfv6Bsdx4JAjZ/RHeqxbXwBdXgoop6+ytOXek0o dgTXPR0rZ2orYqI6FTGYYaJ392DfuRRZZ3OFRGT0KBmjXPbsEvnq6ykuNlq5+48y TZ7XCAr334FscfIHlZNdiKOarC78V47d+hlCM4vnzo5Ea+KCsIBLtaFk54ai0ZY6 qOxkuj6h4000AfyOuzYsCEkaz2vRc/nWxH6MDUItfV8gUJuFhM1jqkfpR4nkLAvK yim1m9K6F26zI5KsYV50LkIUzPzikweLwTGYKgm7ln+AmcHZWkT4B5HgbFJ86ZcH i+VP+4qYazo= =7+W9 -----END PGP SIGNATURE----- --=-=-=-- From unknown Sat Jun 21 10:35:20 2025 X-Loop: help-debbugs@gnu.org Subject: [bug#44656] [PATCH] Upgrade pypy3 Resent-From: Lars-Dominik Braun Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Sun, 15 Nov 2020 19:57:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 44656 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: Christopher Baines Cc: 44656@debbugs.gnu.org Received: via spool by 44656-submit@debbugs.gnu.org id=B44656.160547016915188 (code B ref 44656); Sun, 15 Nov 2020 19:57:02 +0000 Received: (at 44656) by debbugs.gnu.org; 15 Nov 2020 19:56:09 +0000 Received: from localhost ([127.0.0.1]:54226 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1keO86-0003wr-Ps for submit@debbugs.gnu.org; Sun, 15 Nov 2020 14:56:09 -0500 Received: from mout-p-101.mailbox.org ([80.241.56.151]:48122) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1keO81-0003wC-07 for 44656@debbugs.gnu.org; Sun, 15 Nov 2020 14:56:05 -0500 Received: from smtp2.mailbox.org (smtp2.mailbox.org [80.241.60.241]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-384) server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by mout-p-101.mailbox.org (Postfix) with ESMTPS id 4CZ2y22fGkzQjhF; Sun, 15 Nov 2020 20:55:54 +0100 (CET) X-Virus-Scanned: amavisd-new at heinlein-support.de DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=6xq.net; s=MBO0001; t=1605470152; 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=pT4z/naOPAuVckmUBczY13RCQHi+eOJa672Ly0MnaQg=; b=D0eDuzeKYX7aQ9/kk8j/rP5V54FiasWNqQ5QSM5kVta/r7teFjYMHtyoQzhwTwpQg0ZpyW a+1fGAe0AxD5SzHRmaLfan4ISBxdEvhj5pLT7Sb22NCD5owA0TLcxf2lP+nZ2CK/FrBKYu RIhxDdPHAXJ0ij/SWBGLCTkDJd4FRdfKyvcFxeu9XhzOhkCrbdbC3QETRrc5UGVad213my gX08hg+GkwpOHHyB2i6xZTmq61as6etFI5gr+W4Ku5jPpJAuJ1tv8ZiSmbhNC/g5eGpQWr gnpEu5XYHJxnX0e06ee3Fvt0+S9GGhff6pLI4tfkl+duPCBYtmoE/IrUdqEarQ== Received: from smtp2.mailbox.org ([80.241.60.241]) by spamfilter04.heinlein-hosting.de (spamfilter04.heinlein-hosting.de [80.241.56.122]) (amavisd-new, port 10030) with ESMTP id lf1-yoITT4HO; Sun, 15 Nov 2020 20:55:50 +0100 (CET) Date: Sun, 15 Nov 2020 20:55:49 +0100 From: Lars-Dominik Braun Message-ID: <20201115195549.GA1304@noor.fritz.box> References: <20201115123911.GA1956@noor.fritz.box> <87zh3ibekx.fsf@cbaines.net> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <87zh3ibekx.fsf@cbaines.net> X-MBO-SPAM-Probability: X-Rspamd-Score: -3.51 / 15.00 / 15.00 X-Rspamd-Queue-Id: 28ADB1704 X-Rspamd-UID: 7d3250 X-Spam-Score: -0.7 (/) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) Hi Chris, > If there are things that aren't essential to change when changing the > version, they're fine to have in subsequent commits/patches. the patches do not depend on each other. The second patch merely contains quality of life improvements that work with or without bumping the version. But I though I just send them in one go. Cheers, Lars From unknown Sat Jun 21 10:35:20 2025 X-Loop: help-debbugs@gnu.org Subject: [bug#44656] [PATCH] Upgrade pypy3 Resent-From: Christopher Baines Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Mon, 16 Nov 2020 17:27:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 44656 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: Lars-Dominik Braun Cc: 44656@debbugs.gnu.org Received: via spool by 44656-submit@debbugs.gnu.org id=B44656.160554760225592 (code B ref 44656); Mon, 16 Nov 2020 17:27:02 +0000 Received: (at 44656) by debbugs.gnu.org; 16 Nov 2020 17:26:42 +0000 Received: from localhost ([127.0.0.1]:57071 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1keiH3-0006eh-Mr for submit@debbugs.gnu.org; Mon, 16 Nov 2020 12:26:41 -0500 Received: from mira.cbaines.net ([212.71.252.8]:37664) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1keiH1-0006eY-Jk for 44656@debbugs.gnu.org; Mon, 16 Nov 2020 12:26:40 -0500 Received: from localhost (188.30.135.14.threembb.co.uk [188.30.135.14]) by mira.cbaines.net (Postfix) with ESMTPSA id B462A27BBF5; Mon, 16 Nov 2020 17:26:38 +0000 (GMT) Received: from capella (localhost [127.0.0.1]) by localhost (OpenSMTPD) with ESMTP id 59e32ddb; Mon, 16 Nov 2020 17:26:36 +0000 (UTC) References: <20201115123911.GA1956@noor.fritz.box> <87zh3ibekx.fsf@cbaines.net> <20201115195549.GA1304@noor.fritz.box> User-agent: mu4e 1.4.13; emacs 27.1 From: Christopher Baines In-reply-to: <20201115195549.GA1304@noor.fritz.box> Date: Mon, 16 Nov 2020 17:26:32 +0000 Message-ID: <874klpnrg7.fsf@cbaines.net> MIME-Version: 1.0 Content-Type: multipart/signed; boundary="=-=-="; micalg=pgp-sha512; protocol="application/pgp-signature" X-Spam-Score: -0.0 (/) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) --=-=-= Content-Type: text/plain Content-Transfer-Encoding: quoted-printable Lars-Dominik Braun writes: >> If there are things that aren't essential to change when changing the >> version, they're fine to have in subsequent commits/patches. > the patches do not depend on each other. The second patch merely > contains quality of life improvements that work with or without bumping > the version. But I though I just send them in one go. Fair enough, the version upgrade works fine for me. Regarding the second patch: diff --git a/gnu/packages/patches/pypy3-7.3.1-ssl-paths.patch b/gnu/package= s/patches/pypy3-7.3.1-ssl-paths.patch new file mode 100644 index 0000000000..d21133b4ae =2D-- /dev/null +++ b/gnu/packages/patches/pypy3-7.3.1-ssl-paths.patch @@ -0,0 +1,41 @@ +Fix default certificate search path, still allowing the user to override it +with environment variables. + +--- a/lib_pypy/_cffi_ssl/_stdssl/__init__.py ++++ b/lib_pypy/_cffi_ssl/_stdssl/__init__.py +@@ -1679,20 +1679,9 @@ def get_default_verify_paths(): + https://golang.org/src/crypto/x509/root_linux.go (for the files) + ''' + certFiles =3D [ +- "/etc/ssl/certs/ca-certificates.crt", # Debian/Ubu= ntu/Gentoo etc. +- "/etc/pki/tls/certs/ca-bundle.crt", # Fedora/RHE= L 6 +- "/etc/ssl/ca-bundle.pem", # OpenSUSE +- "/etc/pki/tls/cacert.pem", # OpenELEC +- "/etc/pki/ca-trust/extracted/pem/tls-ca-bundle.pem", # CentOS/RHE= L 7 +- "/etc/ssl/cert.pem", # Alpine Lin= ux + ] + certDirectories =3D [ +- "/etc/ssl/certs", # SLES10/SLES11 +- "/system/etc/security/cacerts", # Android +- "/usr/local/share/certs", # FreeBSD +- "/etc/pki/tls/certs", # Fedora/RHEL +- "/etc/openssl/certs", # NetBSD +- "/var/ssl/certs", # AIX ++ "@GUIX_CERT_PATH@", + ] I'm not sure about removing these bits. pypy3 from Guix may be used on Debian or Fedora, and maybe using certificates from those systems would be appropriate then? +=20 + # optimization: reuse the values from a local varaible +@@ -1707,9 +1696,10 @@ def get_default_verify_paths(): + ofile =3D _cstr_decode_fs(lib.X509_get_default_cert_file()) + odir =3D _cstr_decode_fs(lib.X509_get_default_cert_dir()) +=20 +- if os.path.exists(ofile) and os.path.exists(odir): +- get_default_verify_paths.retval =3D (ofile_env, ofile, odir_env, = odir) +- return get_default_verify_paths.retval ++ if not os.path.exists(ofile): ++ ofile =3D None ++ if not os.path.exists(odir): ++ odir =3D None +=20 + # OpenSSL didn't supply the goods. Try some other options + for f in certFiles: @@ -793,7 +806,12 @@ ease from the desktop to a microcontroller or embedded= system.") ; attribute 'IntFlag' (invoke "python2" "package.py" "--archive-name" "pypy-dist" =2D "--builddir" (getcwd))))) + "--builddir" (getcwd)) + ;; install pip and setuptools into the dist direct= ory. + ;; XXX: Breaks virtualenv, because it does not set= +w + ;; on files copied from the store. + ;(invoke "pypy-dist/bin/pypy3" "-m" "ensurepip") + ))) (replace 'check (lambda* (#:key tests? #:allow-other-keys) (if tests? I'm not quite sure what this would do if it's commented back in. --=-=-= Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQKlBAEBCgCPFiEEPonu50WOcg2XVOCyXiijOwuE9XcFAl+ytkhfFIAAAAAALgAo aXNzdWVyLWZwckBub3RhdGlvbnMub3BlbnBncC5maWZ0aGhvcnNlbWFuLm5ldDNF ODlFRUU3NDU4RTcyMEQ5NzU0RTBCMjVFMjhBMzNCMEI4NEY1NzcRHG1haWxAY2Jh aW5lcy5uZXQACgkQXiijOwuE9Xf+Mw//aQ/+Diviku6g+NT49mB53Ib3bVIY44dD WxaXV042un+g8kIPnxhYc1HmpeseLfLWd3z236QGyryhLaIzIDTfX5PrxgQqO2gU jrNXZGyCrCPwlwGqSEIEn8KR0hWfjoyCPU+ib5dzdikK7KXwtYuLVCV8LXZapSgX 7HkvqeP5ytUxWgQDwayTW6MMKKneqABxUxPla5Kcee1U8+siyQb4g8N3jvdm182N v4UPk5rkBQG7zrrIp22cRxbLsEQr7K/Li/1+VFxQADQugpMzW87M4R1gvxMeSaW3 DmepcJbfSzTgdWFbAgUIvidZgcgwsgO1bfqfIyv9wb/iTMZISEQxEVwMSd3WjgRn 0KyNuNvasAIlNOX8G6X/E+Wuc1firhZa1XSmpAh53Vw+9h0LKnHIKnZztbDVta64 UI9/dGU1X6S8deRQTaaVcVvwd92T1OLh0kDVCBnTyJY1j8iq16Sj+4HuGD26gbGg uM69APwe+Q1hEDHS4g12H3GL4VevbblilsAgxBG5eDc0J/YSi6xVTZm7MXVCmElx WAU5G8KpBNpUpayrlFVC+5YcBMdZ5sS6ny1EM7chfGeRvQQMDkT5nZrvYqXVsCfd lwQfllK5OvB1Pi/ZIOZz3iyAV1H4KKG+3mRE27MVSOuXrHCM06UK+++sm8rxVIt3 kVeblHgIcEw= =SrMc -----END PGP SIGNATURE----- --=-=-=-- From unknown Sat Jun 21 10:35:20 2025 X-Loop: help-debbugs@gnu.org Subject: [bug#44656] [PATCH] Upgrade pypy3 Resent-From: Lars-Dominik Braun Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Tue, 17 Nov 2020 09:39:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 44656 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: Christopher Baines Cc: 44656@debbugs.gnu.org Received: via spool by 44656-submit@debbugs.gnu.org id=B44656.160560589913667 (code B ref 44656); Tue, 17 Nov 2020 09:39:01 +0000 Received: (at 44656) by debbugs.gnu.org; 17 Nov 2020 09:38:19 +0000 Received: from localhost ([127.0.0.1]:58342 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kexRL-0003YM-5T for submit@debbugs.gnu.org; Tue, 17 Nov 2020 04:38:19 -0500 Received: from mout-p-102.mailbox.org ([80.241.56.152]:59368) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kexRG-0003Y6-JV for 44656@debbugs.gnu.org; Tue, 17 Nov 2020 04:38:18 -0500 Received: from smtp2.mailbox.org (smtp2.mailbox.org [IPv6:2001:67c:2050:105:465:1:2:0]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-384) server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by mout-p-102.mailbox.org (Postfix) with ESMTPS id 4Cb18J1l4nzQlWd; Tue, 17 Nov 2020 10:38:08 +0100 (CET) X-Virus-Scanned: amavisd-new at heinlein-support.de DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=6xq.net; s=MBO0001; t=1605605886; 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: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=6399VOiSjOJaJ5FHFMROifn1OTUo+hn2kMlxTXdwwKM=; b=CsEqLhg6lpV2cglqbB6K04YRKInNVGSx/YwzTedy/T6Jn+0OZJZnY5eqCtnD00AolSsmKm 1L7xTXqK5HfcXX6A5panhnS4NTGkXZGdD3LqJX8kU7yhYabVHeOgtRIj5wPFmZcS5dkP6F H7rrDPE85C2jHy5vyq2ESIFZU8PFvyK6IE+Fx7D/eHHHEru9xLhplqjwBCslJkU0YUq4oa Be9zs/9UHdWT3QZO86U2mQM6H0ubnxzr3wjOd8xPcW/RDepZFPjJpia4xEx9BhS3MvDxL8 YeLX11ZRcyjSUkBRe5tqfSc8eE/2y2Pd4CaqxEptdt1g0iuuFcoVGCNzlO+TqA== Received: from smtp2.mailbox.org ([80.241.60.241]) by spamfilter01.heinlein-hosting.de (spamfilter01.heinlein-hosting.de [80.241.56.115]) (amavisd-new, port 10030) with ESMTP id wwhTMzFDq0C0; Tue, 17 Nov 2020 10:38:05 +0100 (CET) Date: Tue, 17 Nov 2020 10:38:03 +0100 From: Lars-Dominik Braun Message-ID: <20201117093803.GA1334@noor.fritz.box> References: <20201115123911.GA1956@noor.fritz.box> <87zh3ibekx.fsf@cbaines.net> <20201115195549.GA1304@noor.fritz.box> <874klpnrg7.fsf@cbaines.net> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <874klpnrg7.fsf@cbaines.net> X-MBO-SPAM-Probability: X-Rspamd-Score: -3.39 / 15.00 / 15.00 X-Rspamd-Queue-Id: 3B911170D X-Rspamd-UID: c96846 X-Spam-Score: -0.7 (/) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) Hi Chris, > I'm not sure about removing these bits. pypy3 from Guix may be used on > Debian or Fedora, and maybe using certificates from those systems would > be appropriate then? I disagree, because then pypy might behave differently on Guix System vs. foreign distros. A question up for discussion however is whether it should depend on nss-certs at all. > + ;; install pip and setuptools into the dist directory. > + ;; XXX: Breaks virtualenv, because it does not set +w > + ;; on files copied from the store. > + ;(invoke "pypy-dist/bin/pypy3" "-m" "ensurepip") > I'm not quite sure what this would do if it's commented back in. It would install pip into the same output. Currently our python package has pip built in and this change would change pypy3 to do the same. Unfortunately it does not work well on foreign distros, thus I’m leaving it commented out as future work. Cheers, Lars From unknown Sat Jun 21 10:35:20 2025 X-Loop: help-debbugs@gnu.org Subject: [bug#44656] [PATCH] Upgrade pypy3 Resent-From: Maxim Cournoyer Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Tue, 03 Aug 2021 21:40:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 44656 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: Lars-Dominik Braun Cc: 44656@debbugs.gnu.org Received: via spool by 44656-submit@debbugs.gnu.org id=B44656.162802678926510 (code B ref 44656); Tue, 03 Aug 2021 21:40:02 +0000 Received: (at 44656) by debbugs.gnu.org; 3 Aug 2021 21:39:49 +0000 Received: from localhost ([127.0.0.1]:41682 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mB28Q-0006tG-Hq for submit@debbugs.gnu.org; Tue, 03 Aug 2021 17:39:49 -0400 Received: from mail-qv1-f41.google.com ([209.85.219.41]:46747) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mB28N-0006t1-DJ for 44656@debbugs.gnu.org; Tue, 03 Aug 2021 17:39:36 -0400 Received: by mail-qv1-f41.google.com with SMTP id d17so150750qvn.13 for <44656@debbugs.gnu.org>; Tue, 03 Aug 2021 14:39:35 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version:content-transfer-encoding; bh=OpwbC5wNiMw5QSGbe0lcMK7mf8CERy7ujdTr/tzMXr4=; b=N10ZextUjkHr34uYMS4YnREcpbKHez8sA7cZjHp/FXs/9e38WxQXtPAE/Qe7+NtVGL SR/TZxb/Yu/JMuEpA5JiHKXXMhP+3y+I9zbXrwLTN+OJmaabcgSSYcWIPIWmWRxD6jtr WE9AZtXAKCRQz4YlKYGHRO14bqb215VRchmbPj3gSftHtLrnP1tGotMd9f1r73aK4NWI KQm+ijJNnUOMS0UfmU04yTnjkwJL5FB/6ggY/ejnHiT2Dk/WVVMYF66pd0pCiRcThh/E SMhH6pQDcU0cjeLvqjabyWyrmLsD1UgjQlA1NXlLuxnC6RwNE26vJg6B8c0SRdznlmSU xydg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:references:date:in-reply-to :message-id:user-agent:mime-version:content-transfer-encoding; bh=OpwbC5wNiMw5QSGbe0lcMK7mf8CERy7ujdTr/tzMXr4=; b=hl1nPyDcqVVR8etnwUzQXQZp4r5tugK2GpLMskLquzPT5iXy49UsGWjb5ZXTn6DqAa sYNb0Su2/uq4Zujm4M97vfPmvRtQ6I3F9pIcrALBNnYCP9yQCUl71IY5u4dZxgT2IXGb DS4wMMQ4KS7uGMYOOTogW/cD0JVKOlHsIa442SxOCQD8XGzJu8h/ITJUSxSH1YdU5BNV t22760IsGr6DIkmuo5aOptvHFdlxxxNDHKRgh86lPQq1eSpCSyEd/0YA8+RGnGeK4pGn AmTsahAUMRWllo4GdZF3wVxx+8yKksioiFPBbc8cXDI80V2koGJVLUrGCE3Z5W/sTarI Wb2w== X-Gm-Message-State: AOAM53006ugyEUsmoWRd+qCHpFZTI3WAT2eLPUtZFnX64wZWYOQHph3L yk9C/mpTtKXuVZR5nIXOAJh8yxW96dVck+B3 X-Google-Smtp-Source: ABdhPJzHtr4ClEHS+HVwGyaSAg+FjRGUyKz4CLAtIfOjxLiVDNuwolq0GsbeRbyBJerX9v4WoeVDWA== X-Received: by 2002:a0c:ca09:: with SMTP id c9mr23566375qvk.61.1628026769645; Tue, 03 Aug 2021 14:39:29 -0700 (PDT) Received: from hurd (dsl-10-129-132.b2b2c.ca. [72.10.129.132]) by smtp.gmail.com with ESMTPSA id d28sm141160qkj.25.2021.08.03.14.39.28 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 03 Aug 2021 14:39:29 -0700 (PDT) From: Maxim Cournoyer References: <20201115123911.GA1956@noor.fritz.box> Date: Tue, 03 Aug 2021 17:39:28 -0400 In-Reply-To: <20201115123911.GA1956@noor.fritz.box> (Lars-Dominik Braun's message of "Sun, 15 Nov 2020 13:39:11 +0100") Message-ID: <87eeba8ay7.fsf@gmail.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.2 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Spam-Score: 0.0 (/) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) Hi Lars, Lars-Dominik Braun writes: > Hi, > > the first patch in this series upgrades pypy3 to 7.3.2 and the second > adjusts several aspects of the package. > > Lars > > >>>From caf5e4bf9acd10f91de2e6a9c60185475144a1b9 Mon Sep 17 00:00:00 2001 > From: Lars-Dominik Braun > Date: Sun, 15 Nov 2020 10:54:26 +0100 > Subject: [PATCH 2/2] gnu: pypy3: Various package fixes. > > * gnu/packages/python.scm (pypy3) [patches]: Add new patch. > [inputs]: Remove bash-minimal and add nss-certs. > [native-inputs]: Remove nss-certs here. In Guix we leave the choice of the TLS certs to the users; meaning we don't hard-code their location in packages and instead have the users explicitly install them (and in the case of OpenSSL, set the necessary environment variables), the same we do for icons and other 'choosable' things; while convenient the above goes against this tradition. > [arguments]: Use gdbm compat library, add 2to3 binary. > [native-search-paths]: Add search path. > * gnu/packages/patches/pypy3-7.3.1-ssl-paths.patch: New file. > * gnu/local.mk: Add it. > --- > gnu/local.mk | 1 + > .../patches/pypy3-7.3.1-ssl-paths.patch | 41 +++++++ > gnu/packages/python.scm | 109 ++++++++++++------ > 3 files changed, 116 insertions(+), 35 deletions(-) > create mode 100644 gnu/packages/patches/pypy3-7.3.1-ssl-paths.patch > > diff --git a/gnu/local.mk b/gnu/local.mk > index 91a3295e75..b644391a11 100644 > --- a/gnu/local.mk > +++ b/gnu/local.mk > @@ -1536,6 +1536,7 @@ dist_patch_DATA =3D \ > %D%/packages/patches/python-unittest2-remove-argparse.patch \ > %D%/packages/patches/python-waitress-fix-tests.patch \ > %D%/packages/patches/pypy3-7.3.1-fix-tests.patch \ > + %D%/packages/patches/pypy3-7.3.1-ssl-paths.patch \ > %D%/packages/patches/qemu-build-info-manual.patch \ > %D%/packages/patches/qemu-glibc-2.27.patch \ > %D%/packages/patches/qrcodegen-cpp-make-install.patch \ > diff --git a/gnu/packages/patches/pypy3-7.3.1-ssl-paths.patch b/gnu/packa= ges/patches/pypy3-7.3.1-ssl-paths.patch > new file mode 100644 > index 0000000000..d21133b4ae > --- /dev/null > +++ b/gnu/packages/patches/pypy3-7.3.1-ssl-paths.patch > @@ -0,0 +1,41 @@ > +Fix default certificate search path, still allowing the user to override= it > +with environment variables. > + > +--- a/lib_pypy/_cffi_ssl/_stdssl/__init__.py > ++++ b/lib_pypy/_cffi_ssl/_stdssl/__init__.py > +@@ -1679,20 +1679,9 @@ def get_default_verify_paths(): > + https://golang.org/src/crypto/x509/root_linux.go (for the files) > + ''' > + certFiles =3D [ > +- "/etc/ssl/certs/ca-certificates.crt", # Debian/U= buntu/Gentoo etc. > +- "/etc/pki/tls/certs/ca-bundle.crt", # Fedora/R= HEL 6 > +- "/etc/ssl/ca-bundle.pem", # OpenSUSE > +- "/etc/pki/tls/cacert.pem", # OpenELEC > +- "/etc/pki/ca-trust/extracted/pem/tls-ca-bundle.pem", # CentOS/R= HEL 7 > +- "/etc/ssl/cert.pem", # Alpine L= inux > + ] > + certDirectories =3D [ > +- "/etc/ssl/certs", # SLES10/SLES11 > +- "/system/etc/security/cacerts", # Android > +- "/usr/local/share/certs", # FreeBSD > +- "/etc/pki/tls/certs", # Fedora/RHEL > +- "/etc/openssl/certs", # NetBSD > +- "/var/ssl/certs", # AIX > ++ "@GUIX_CERT_PATH@", > + ] > + > + # optimization: reuse the values from a local varaible > +@@ -1707,9 +1696,10 @@ def get_default_verify_paths(): > + ofile =3D _cstr_decode_fs(lib.X509_get_default_cert_file()) > + odir =3D _cstr_decode_fs(lib.X509_get_default_cert_dir()) > + > +- if os.path.exists(ofile) and os.path.exists(odir): > +- get_default_verify_paths.retval =3D (ofile_env, ofile, odir_env= , odir) > +- return get_default_verify_paths.retval > ++ if not os.path.exists(ofile): > ++ ofile =3D None > ++ if not os.path.exists(odir): > ++ odir =3D None > + > + # OpenSSL didn't supply the goods. Try some other options > + for f in certFiles: As mentioned above, the choice of certs should not be hard coded the in the package definition. The correct behavior of honoring SSL_CERT_DIR and SSL_CERT_FILE environment variables, and falling back to the system provided location is sane, so the above patch is unwelcome, IMHO. > diff --git a/gnu/packages/python.scm b/gnu/packages/python.scm > index 8ef8ae2e1d..c0bd3335e3 100644 > --- a/gnu/packages/python.scm > +++ b/gnu/packages/python.scm > @@ -696,7 +696,8 @@ ease from the desktop to a microcontroller or embedde= d system.") > (sha256 > (base32 > "03f1fdw6yk2mypa9pbmgk26r8y1hhmw801l6g36zry9zsvz7aqgx")) > - (patches (search-patches "pypy3-7.3.1-fix-tests.patch")))) > + (patches (search-patches "pypy3-7.3.1-fix-tests.patch" > + "pypy3-7.3.1-ssl-paths.patch")))) > (build-system gnu-build-system) > (native-inputs > `(("python-2" ,python-2) > @@ -704,13 +705,13 @@ ease from the desktop to a microcontroller or embed= ded system.") > ("tar" ,tar) ; Required for package.py > ("python2-pycparser" ,python2-pycparser) > ("python2-hypothesis" ,python2-hypothesis) > - ("nss-certs" ,nss-certs) ; For ssl tests > ("gzip" ,gzip))) > (inputs > `(("libffi" ,libffi) > ("zlib" ,zlib) > ("ncurses" ,ncurses) > ("openssl" ,openssl) > + ("nss-certs" ,nss-certs) ; For ssl module This change is not needed without the TLS patching above. > ("expat" ,expat) > ("bzip2" ,bzip2) > ("sqlite" ,sqlite) > @@ -718,10 +719,9 @@ ease from the desktop to a microcontroller or embedd= ed system.") > ("tcl" ,tcl) > ("tk" ,tk) > ("glibc" ,glibc) > - ("bash-minimal" ,bash-minimal) ; Used as /bin/sh > ("xz" ,xz))) ; liblzma > (arguments > - `(#:tests? #f ;FIXME: Disabled for now, there are many tests fa= iling. > + `(#:tests? #f ;FIXME: Disabled for now, there are many tests failin= g. > #:modules ((ice-9 ftw) (ice-9 match) > (guix build utils) (guix build gnu-build-system)) > #:phases (modify-phases %standard-phases > @@ -750,6 +750,11 @@ ease from the desktop to a microcontroller or embedd= ed system.") > (substitute* '("lib_pypy/_curses_build.py") > ;; Find curses > (("/usr/local") (assoc-ref inputs "ncurses"))) > + (substitute* '("lib_pypy/_dbm.py") > + ;; Use gdbm compat library, so we don=E2=80=99t = need to pull in bdb > + (("ctypes.util.find_library\\('db'\\)") > + (string-append "'" (assoc-ref inputs "gdbm") > + "/lib/libgdbm_compat.so'"))) OK. > (substitute* '("lib_pypy/_sqlite3_build.py") > ;; Always use search paths > (("sys\\.platform\\.startswith\\('freebsd'\\)") = "True") > @@ -761,11 +766,18 @@ ease from the desktop to a microcontroller or embed= ded system.") > "/lib/libsqlite3.so.0'"))) > (substitute* '("lib-python/3/subprocess.py") > ;; Fix shell path > - (("/bin/sh") > - (string-append (assoc-ref inputs "bash-minimal"= ) "/bin/sh"))) > + (("/bin/sh") (which "sh"))) OK. > (substitute* '("lib-python/3/distutils/unixccompil= er.py") > ;; gcc-toolchain does not provide symlink cc -> = gcc > (("\"cc\"") "\"gcc\"")) > + (substitute* '("lib_pypy/_cffi_ssl/_stdssl/__init_= _.py") > + ;; Add nss-certs to default certificate search p= ath, > + ;; otherwise every packages has to specify nss-c= erts and > + ;; openssl as input to set the proper env variab= les. > + ;; Depends on -ssl-paths.patch. > + (("@GUIX_CERT_PATH@") > + (string-append (assoc-ref inputs "nss-certs") > + "/etc/ssl/certs"))) Not every package; the required SSL environment variables it should be set in the environment by the user or by via a native search path, and the certs manually provided (installed) by the user. > #t)) > (add-after > 'unpack 'set-source-file-times-to-1980 > @@ -785,7 +797,8 @@ ease from the desktop to a microcontroller or embedde= d system.") > (string-append "--make-jobs=3D" > (number->string (parallel= -job-count))) > "-Ojit" > - "targetpypystandalone")) > + "targetpypystandalone" > + "--allworkingmodules")) > ;; Build c modules and package everything, so test= s work. > (with-directory-excursion "pypy/tool/release" > (unsetenv "PYTHONPATH") ; Do not use the system= =E2=80=99s python libs: > @@ -793,7 +806,12 @@ ease from the desktop to a microcontroller or embedd= ed system.") > ; attribute 'IntFlag' > (invoke "python2" "package.py" > "--archive-name" "pypy-dist" > - "--builddir" (getcwd))))) > + "--builddir" (getcwd)) > + ;; install pip and setuptools into the dist dire= ctory. > + ;; XXX: Breaks virtualenv, because it does not s= et +w > + ;; on files copied from the store. > + ;(invoke "pypy-dist/bin/pypy3" "-m" "ensurepip") > + ))) Since the above attempt to bundle pip failed and is new, I'd just leave it out. > (replace 'check > (lambda* (#:key tests? #:allow-other-keys) > (if tests? > @@ -811,32 +829,54 @@ ease from the desktop to a microcontroller or embed= ded system.") > #t)) > (replace 'install > (lambda* (#:key inputs outputs #:allow-other-keys) > - (with-directory-excursion "pypy/tool/release" > - ;; Delete test data. > - (for-each > - (lambda (x) > - (delete-file-recursively (string-append > - "pypy-dist/lib-pyth= on/3/" x))) > - '("tkinter/test" > - "test" > - "sqlite3/test" > - "lib2to3/tests" > - "idlelib/idle_test" > - "distutils/tests" > - "ctypes/test" > - "unittest/test")) > - ;; Patch shebang referencing python2 > - (substitute* '("pypy-dist/lib-python/3/cgi.py" > - "pypy-dist/lib-python/3/encodings= /rot_13.py") > - (("#!.+/bin/python") > - (string-append "#!" (assoc-ref outputs "out")= "/bin/pypy3"))) > - (with-fluids ((%default-port-encoding "ISO-8859-= 1")) > - (substitute* '("pypy-dist/lib_pypy/_md5.py" > - "pypy-dist/lib_pypy/_sha1.py") > - (("#!.+/bin/python") > - (string-append "#!" (assoc-ref outputs "out= ") "/bin/pypy3")))) > - (copy-recursively "pypy-dist" (assoc-ref outputs= "out"))) > - #t))))) > + (let* ((out (assoc-ref outputs "out")) > + (bin-pypy3 (string-append out "/bin/pypy3")) > + (shebang-match-python "#!.+/bin/python") > + (shebang-pypy3 (string-append "#!" bin-pypy= 3)) > + (dist-dir "pypy/tool/release/pypy-dist")) > + (with-directory-excursion dist-dir > + ;; Delete test data. > + (for-each > + (lambda (x) > + (delete-file-recursively (string-append > + "lib-python/3/" x= ))) > + '("tkinter/test" > + "test" > + "sqlite3/test" > + "lib2to3/tests" > + "idlelib/idle_test" > + "distutils/tests" > + "ctypes/test" > + "unittest/test")) > + ;; Patch shebang referencing python2 > + (substitute* '("lib-python/3/cgi.py" > + "lib-python/3/encodings/rot_13.= py") > + ((shebang-match-python) shebang-pypy3)) > + (with-fluids ((%default-port-encoding "ISO-885= 9-1")) > + (substitute* '("lib_pypy/_md5.py" > + "lib_pypy/_sha1.py= ") > + ((shebang-match-python) shebang= -pypy3)))) > + (copy-recursively dist-dir out) > + ;; Make sure pypy3 is callable as python/python3= , so we > + ;; don=E2=80=99t have to patch every single pack= age. > + (symlink bin-pypy3 (string-append out "/bin/pyth= on")) > + (symlink bin-pypy3 (string-append out "/bin/pyth= on3")) > + ;; 2to3 is missing from pypy3, create it. > + (let ((2to3 (string-append out "/bin/2to3"))) > + (call-with-output-file 2to3 > + (lambda (port) > + (format port "#!~a~%" (string-append out "= /bin/pypy3")) > + (format port " > +import sys > +from lib2to3.main import main > + > +sys.exit(main('lib2to3.fixes'))"))) > + (chmod 2to3 #o755)) > + #t)))))) I'm unconvinced about the above symlinks; it seems preferable for users to be able to unambiguously run both pypy3 and python3 (cpython) in the same profile without conflicts. The pypy3 package on Debian contains the following, for example: --8<---------------cut here---------------start------------->8--- $ apt-file show pypy3 pypy3: /usr/bin/pypy3 pypy3: /usr/bin/pypy3clean pypy3: /usr/bin/pypy3compile pypy3: /usr/lib/libpypy3-c.so pypy3: /usr/lib/pypy3/bin/libpypy3-c.so pypy3: /usr/lib/pypy3/bin/pypy3-c pypy3: /usr/lib/pypy3/include/pypy_decl.h pypy3: /usr/lib/pypy3/include/pypy_macros.h pypy3: /usr/lib/pypy3/include/pypy_marshal_decl.h pypy3: /usr/lib/pypy3/include/pypy_structmember_decl.h pypy3: /usr/lib/pypy3/lib_pypy/_audioop_cffi.pypy36-pp73-x86_64-linux-gnu.so pypy3: /usr/lib/pypy3/lib_pypy/_blake2/_blake2b_cffi.pypy36-pp73-x86_64-lin= ux-gnu.so pypy3: /usr/lib/pypy3/lib_pypy/_blake2/_blake2s_cffi.pypy36-pp73-x86_64-lin= ux-gnu.so pypy3: /usr/lib/pypy3/lib_pypy/_curses_cffi.pypy36-pp73-x86_64-linux-gnu.so pypy3: /usr/lib/pypy3/lib_pypy/_decimal_cffi.pypy36-pp73-x86_64-linux-gnu.so pypy3: /usr/lib/pypy3/lib_pypy/_gdbm_cffi.pypy36-pp73-x86_64-linux-gnu.so pypy3: /usr/lib/pypy3/lib_pypy/_lzma_cffi.pypy36-pp73-x86_64-linux-gnu.so pypy3: /usr/lib/pypy3/lib_pypy/_pwdgrp_cffi.pypy36-pp73-x86_64-linux-gnu.so pypy3: /usr/lib/pypy3/lib_pypy/_pypy_openssl.pypy36-pp73-x86_64-linux-gnu.so pypy3: /usr/lib/pypy3/lib_pypy/_resource_cffi.pypy36-pp73-x86_64-linux-gnu.= so pypy3: /usr/lib/pypy3/lib_pypy/_sha3/_sha3_cffi.pypy36-pp73-x86_64-linux-gn= u.so pypy3: /usr/lib/pypy3/lib_pypy/_sqlite3_cffi.pypy36-pp73-x86_64-linux-gnu.so pypy3: /usr/lib/pypy3/lib_pypy/_syslog_cffi.pypy36-pp73-x86_64-linux-gnu.so pypy3: /usr/share/doc/pypy3/TODO.Debian pypy3: /usr/share/doc/pypy3/changelog.Debian.gz pypy3: /usr/share/doc/pypy3/copyright pypy3: /usr/share/lintian/overrides/pypy3 pypy3: /usr/share/man/man1/pypy3.1.gz --8<---------------cut here---------------end--------------->8--- > + (native-search-paths > + (list (search-path-specification > + (variable "PYTHONPATH") > + (files '("lib/pypy3.6/site-packages"))))) About this search path, how it is supposed to work? The version is wrong (3.6) and the package doesn't include this directory, and we do not have a pypy build system or other pypy packages that would make use of it. Am I missing something? Thank you! Maxim From unknown Sat Jun 21 10:35:20 2025 MIME-Version: 1.0 X-Mailer: MIME-tools 5.505 (Entity 5.505) X-Loop: help-debbugs@gnu.org From: help-debbugs@gnu.org (GNU bug Tracking System) To: Lars-Dominik Braun Subject: bug#44656: closed (Re: bug#44656: [PATCH] Upgrade pypy3) Message-ID: References: <877dgz96i0.fsf_-_@gmail.com> <20201115123911.GA1956@noor.fritz.box> X-Gnu-PR-Message: they-closed 44656 X-Gnu-PR-Package: guix-patches X-Gnu-PR-Keywords: patch Reply-To: 44656@debbugs.gnu.org Date: Thu, 05 Aug 2021 16:56:02 +0000 Content-Type: multipart/mixed; boundary="----------=_1628182562-11487-1" This is a multi-part message in MIME format... ------------=_1628182562-11487-1 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" Your bug report #44656: [PATCH] Upgrade pypy3 which was filed against the guix-patches package, has been closed. The explanation is attached below, along with your original report. If you require more details, please reply to 44656@debbugs.gnu.org. --=20 44656: http://debbugs.gnu.org/cgi/bugreport.cgi?bug=3D44656 GNU Bug Tracking System Contact help-debbugs@gnu.org with problems ------------=_1628182562-11487-1 Content-Type: message/rfc822 Content-Disposition: inline Content-Transfer-Encoding: 7bit Received: (at 44656-done) by debbugs.gnu.org; 5 Aug 2021 16:55:07 +0000 Received: from localhost ([127.0.0.1]:48266 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mBge1-0002xO-31 for submit@debbugs.gnu.org; Thu, 05 Aug 2021 12:55:07 -0400 Received: from mail-qv1-f48.google.com ([209.85.219.48]:40793) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mBgdy-0002xB-Fz for 44656-done@debbugs.gnu.org; Thu, 05 Aug 2021 12:54:55 -0400 Received: by mail-qv1-f48.google.com with SMTP id s11so3292729qvz.7 for <44656-done@debbugs.gnu.org>; Thu, 05 Aug 2021 09:54:54 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version:content-transfer-encoding; bh=qtcFmqQ9HTCo+f6qbizMSLeKIbvzkwyGmh3GoWuGcVo=; b=SNqoxCOB13SGT+MfZp0bnaS2dULBGHiWRRhJKgZB+LhivriwlYIHZRNtK4YMYvjdMX b6Y0ePgokE/Re4DdFsM6iJWHiPLpzCgTdbUW5QwUGaUvV70yqzhj91/XPKL0TrN7Od0F DJv1/IC9d+HBlNRc+TAIuBiCbhYTZ3iyHMqI8uQTWGKolqrh0J4O82D5ecKKKKWnSGn1 TBw1tZ5GiVK2Ndl9gZFfdoosmjMXixWMQ4QMA2NXyiphEJFKebSflcr6dzeqwUAyJ9cL zxXb728jtTY2QiNbrimy2qMU6KB4MkUzU5iOKUOlzES1lEu8N6Q1tUosOs1QoDLp+/Uz A4Tg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:references:date:in-reply-to :message-id:user-agent:mime-version:content-transfer-encoding; bh=qtcFmqQ9HTCo+f6qbizMSLeKIbvzkwyGmh3GoWuGcVo=; b=S9ZMnmmIJsfkVmlipZ6YHOYk8YzQU8JCj5E2es1AUmGKHfIAh/Nj885zEhcVPjWD/t Z7uajPieEJU7oqlANTmL4LzqNW1QEzbpaiN+TcX4lKZD+eh0h7HLUB4HoZUazHRf/+Yi Q030Rmr5PMpjGx9COSABTEtd19FASYAT/u8m1M5B9MND61UZ7ZmxxGTKoaLDIvJbTzqR pZwQKza6vJ24GsKhPKK4kEdmpluovUknYrlPjuQtyC2BTuwikavD0UMkdkKsyRBBwcWy BuwMrBkAA5tFoRNsyIJKyY8Ao4PmUMcIMkM7P4lzrxmmMBMjiB76Cy/oOkhGZYO7VLIy qfqA== X-Gm-Message-State: AOAM531BthUP9iagUBkymHmwuypAxljNMtnzkJ4Y2MHCOh5xmBdoSiAe bhxh5PDZhV88gXVt7Ak9tMb2SQEaZ18r3yDp X-Google-Smtp-Source: ABdhPJyZ958qWeXJuhvLHdWUdyjQCC6OacDkTBUdVHGlJ4v88qPVlhI5QKA/BLEOJRrU5BBFnzryUA== X-Received: by 2002:ad4:5fcd:: with SMTP id jq13mr6296167qvb.57.1628182488616; Thu, 05 Aug 2021 09:54:48 -0700 (PDT) Received: from raisin ([2607:fad8:4:6:235e:8579:8464:aacc]) by smtp.gmail.com with ESMTPSA id b23sm3145776qkl.113.2021.08.05.09.54.48 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 05 Aug 2021 09:54:48 -0700 (PDT) From: Maxim Cournoyer To: Lars-Dominik Braun Subject: Re: bug#44656: [PATCH] Upgrade pypy3 References: <20201115123911.GA1956@noor.fritz.box> <87eeba8ay7.fsf@gmail.com> Date: Thu, 05 Aug 2021 12:54:47 -0400 In-Reply-To: <87eeba8ay7.fsf@gmail.com> (Maxim Cournoyer's message of "Tue, 03 Aug 2021 17:39:28 -0400") Message-ID: <877dgz96i0.fsf_-_@gmail.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.2 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 44656-done Cc: 44656-done@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) Hello again, Maxim Cournoyer writes: > Hi Lars, > > Lars-Dominik Braun writes: > >> Hi, >> >> the first patch in this series upgrades pypy3 to 7.3.2 and the second >> adjusts several aspects of the package. >> >> Lars >> >> >>>>>From caf5e4bf9acd10f91de2e6a9c60185475144a1b9 Mon Sep 17 00:00:00 2001 >> From: Lars-Dominik Braun >> Date: Sun, 15 Nov 2020 10:54:26 +0100 >> Subject: [PATCH 2/2] gnu: pypy3: Various package fixes. >> >> * gnu/packages/python.scm (pypy3) [patches]: Add new patch. >> [inputs]: Remove bash-minimal and add nss-certs. >> [native-inputs]: Remove nss-certs here. > > In Guix we leave the choice of the TLS certs to the users; meaning we > don't hard-code their location in packages and instead have the users > explicitly install them (and in the case of OpenSSL, set the necessary > environment variables), the same we do for icons and other 'choosable' > things; while convenient the above goes against this tradition. > >> [arguments]: Use gdbm compat library, add 2to3 binary. >> [native-search-paths]: Add search path. >> * gnu/packages/patches/pypy3-7.3.1-ssl-paths.patch: New file. >> * gnu/local.mk: Add it. >> --- >> gnu/local.mk | 1 + >> .../patches/pypy3-7.3.1-ssl-paths.patch | 41 +++++++ >> gnu/packages/python.scm | 109 ++++++++++++------ >> 3 files changed, 116 insertions(+), 35 deletions(-) >> create mode 100644 gnu/packages/patches/pypy3-7.3.1-ssl-paths.patch >> >> diff --git a/gnu/local.mk b/gnu/local.mk >> index 91a3295e75..b644391a11 100644 >> --- a/gnu/local.mk >> +++ b/gnu/local.mk >> @@ -1536,6 +1536,7 @@ dist_patch_DATA =3D \ >> %D%/packages/patches/python-unittest2-remove-argparse.patch \ >> %D%/packages/patches/python-waitress-fix-tests.patch \ >> %D%/packages/patches/pypy3-7.3.1-fix-tests.patch \ >> + %D%/packages/patches/pypy3-7.3.1-ssl-paths.patch \ >> %D%/packages/patches/qemu-build-info-manual.patch \ >> %D%/packages/patches/qemu-glibc-2.27.patch \ >> %D%/packages/patches/qrcodegen-cpp-make-install.patch \ >> diff --git a/gnu/packages/patches/pypy3-7.3.1-ssl-paths.patch b/gnu/pack= ages/patches/pypy3-7.3.1-ssl-paths.patch >> new file mode 100644 >> index 0000000000..d21133b4ae >> --- /dev/null >> +++ b/gnu/packages/patches/pypy3-7.3.1-ssl-paths.patch >> @@ -0,0 +1,41 @@ >> +Fix default certificate search path, still allowing the user to overrid= e it >> +with environment variables. >> + >> +--- a/lib_pypy/_cffi_ssl/_stdssl/__init__.py >> ++++ b/lib_pypy/_cffi_ssl/_stdssl/__init__.py >> +@@ -1679,20 +1679,9 @@ def get_default_verify_paths(): >> + https://golang.org/src/crypto/x509/root_linux.go (for the files) >> + ''' >> + certFiles =3D [ >> +- "/etc/ssl/certs/ca-certificates.crt", # Debian/= Ubuntu/Gentoo etc. >> +- "/etc/pki/tls/certs/ca-bundle.crt", # Fedora/= RHEL 6 >> +- "/etc/ssl/ca-bundle.pem", # OpenSUSE >> +- "/etc/pki/tls/cacert.pem", # OpenELEC >> +- "/etc/pki/ca-trust/extracted/pem/tls-ca-bundle.pem", # CentOS/= RHEL 7 >> +- "/etc/ssl/cert.pem", # Alpine = Linux >> + ] >> + certDirectories =3D [ >> +- "/etc/ssl/certs", # SLES10/SLES11 >> +- "/system/etc/security/cacerts", # Android >> +- "/usr/local/share/certs", # FreeBSD >> +- "/etc/pki/tls/certs", # Fedora/RHEL >> +- "/etc/openssl/certs", # NetBSD >> +- "/var/ssl/certs", # AIX >> ++ "@GUIX_CERT_PATH@", >> + ] >> + >> + # optimization: reuse the values from a local varaible >> +@@ -1707,9 +1696,10 @@ def get_default_verify_paths(): >> + ofile =3D _cstr_decode_fs(lib.X509_get_default_cert_file()) >> + odir =3D _cstr_decode_fs(lib.X509_get_default_cert_dir()) >> + >> +- if os.path.exists(ofile) and os.path.exists(odir): >> +- get_default_verify_paths.retval =3D (ofile_env, ofile, odir_en= v, odir) >> +- return get_default_verify_paths.retval >> ++ if not os.path.exists(ofile): >> ++ ofile =3D None >> ++ if not os.path.exists(odir): >> ++ odir =3D None >> + >> + # OpenSSL didn't supply the goods. Try some other options >> + for f in certFiles: > > As mentioned above, the choice of certs should not be hard coded the in > the package definition. The correct behavior of honoring SSL_CERT_DIR > and SSL_CERT_FILE environment variables, and falling back to the system > provided location is sane, so the above patch is unwelcome, IMHO. > >> diff --git a/gnu/packages/python.scm b/gnu/packages/python.scm >> index 8ef8ae2e1d..c0bd3335e3 100644 >> --- a/gnu/packages/python.scm >> +++ b/gnu/packages/python.scm >> @@ -696,7 +696,8 @@ ease from the desktop to a microcontroller or embedd= ed system.") >> (sha256 >> (base32 >> "03f1fdw6yk2mypa9pbmgk26r8y1hhmw801l6g36zry9zsvz7aqgx")) >> - (patches (search-patches "pypy3-7.3.1-fix-tests.patch")))) >> + (patches (search-patches "pypy3-7.3.1-fix-tests.patch" >> + "pypy3-7.3.1-ssl-paths.patch")))) >> (build-system gnu-build-system) >> (native-inputs >> `(("python-2" ,python-2) >> @@ -704,13 +705,13 @@ ease from the desktop to a microcontroller or embe= dded system.") >> ("tar" ,tar) ; Required for package.py >> ("python2-pycparser" ,python2-pycparser) >> ("python2-hypothesis" ,python2-hypothesis) >> - ("nss-certs" ,nss-certs) ; For ssl tests >> ("gzip" ,gzip))) >> (inputs >> `(("libffi" ,libffi) >> ("zlib" ,zlib) >> ("ncurses" ,ncurses) >> ("openssl" ,openssl) >> + ("nss-certs" ,nss-certs) ; For ssl module > > This change is not needed without the TLS patching above. > >> ("expat" ,expat) >> ("bzip2" ,bzip2) >> ("sqlite" ,sqlite) >> @@ -718,10 +719,9 @@ ease from the desktop to a microcontroller or embed= ded system.") >> ("tcl" ,tcl) >> ("tk" ,tk) >> ("glibc" ,glibc) >> - ("bash-minimal" ,bash-minimal) ; Used as /bin/sh >> ("xz" ,xz))) ; liblzma >> (arguments >> - `(#:tests? #f ;FIXME: Disabled for now, there are many tests f= ailing. >> + `(#:tests? #f ;FIXME: Disabled for now, there are many tests faili= ng. >> #:modules ((ice-9 ftw) (ice-9 match) >> (guix build utils) (guix build gnu-build-system)) >> #:phases (modify-phases %standard-phases >> @@ -750,6 +750,11 @@ ease from the desktop to a microcontroller or embed= ded system.") >> (substitute* '("lib_pypy/_curses_build.py") >> ;; Find curses >> (("/usr/local") (assoc-ref inputs "ncurses"))) >> + (substitute* '("lib_pypy/_dbm.py") >> + ;; Use gdbm compat library, so we don=E2=80=99t= need to pull in bdb >> + (("ctypes.util.find_library\\('db'\\)") >> + (string-append "'" (assoc-ref inputs "gdbm") >> + "/lib/libgdbm_compat.so'"))) > > OK. > >> (substitute* '("lib_pypy/_sqlite3_build.py") >> ;; Always use search paths >> (("sys\\.platform\\.startswith\\('freebsd'\\)")= "True") >> @@ -761,11 +766,18 @@ ease from the desktop to a microcontroller or embe= dded system.") >> "/lib/libsqlite3.so.0'"))) >> (substitute* '("lib-python/3/subprocess.py") >> ;; Fix shell path >> - (("/bin/sh") >> - (string-append (assoc-ref inputs "bash-minimal= ") "/bin/sh"))) >> + (("/bin/sh") (which "sh"))) > > OK. > >> (substitute* '("lib-python/3/distutils/unixccompi= ler.py") >> ;; gcc-toolchain does not provide symlink cc ->= gcc >> (("\"cc\"") "\"gcc\"")) >> + (substitute* '("lib_pypy/_cffi_ssl/_stdssl/__init= __.py") >> + ;; Add nss-certs to default certificate search = path, >> + ;; otherwise every packages has to specify nss-= certs and >> + ;; openssl as input to set the proper env varia= bles. >> + ;; Depends on -ssl-paths.patch. >> + (("@GUIX_CERT_PATH@") >> + (string-append (assoc-ref inputs "nss-certs") >> + "/etc/ssl/certs"))) > > Not every package; the required SSL environment variables it should be > set in the environment by the user or by via a native search path, and > the certs manually provided (installed) by the user. > >> #t)) >> (add-after >> 'unpack 'set-source-file-times-to-1980 >> @@ -785,7 +797,8 @@ ease from the desktop to a microcontroller or embedd= ed system.") >> (string-append "--make-jobs=3D" >> (number->string (paralle= l-job-count))) >> "-Ojit" >> - "targetpypystandalone")) >> + "targetpypystandalone" >> + "--allworkingmodules")) >> ;; Build c modules and package everything, so tes= ts work. >> (with-directory-excursion "pypy/tool/release" >> (unsetenv "PYTHONPATH") ; Do not use the system= =E2=80=99s python libs: >> @@ -793,7 +806,12 @@ ease from the desktop to a microcontroller or embed= ded system.") >> ; attribute 'IntFlag' >> (invoke "python2" "package.py" >> "--archive-name" "pypy-dist" >> - "--builddir" (getcwd))))) >> + "--builddir" (getcwd)) >> + ;; install pip and setuptools into the dist dir= ectory. >> + ;; XXX: Breaks virtualenv, because it does not = set +w >> + ;; on files copied from the store. >> + ;(invoke "pypy-dist/bin/pypy3" "-m" "ensurepip") >> + ))) > > Since the above attempt to bundle pip failed and is new, I'd just leave > it out. > >> (replace 'check >> (lambda* (#:key tests? #:allow-other-keys) >> (if tests? >> @@ -811,32 +829,54 @@ ease from the desktop to a microcontroller or embe= dded system.") >> #t)) >> (replace 'install >> (lambda* (#:key inputs outputs #:allow-other-keys) >> - (with-directory-excursion "pypy/tool/release" >> - ;; Delete test data. >> - (for-each >> - (lambda (x) >> - (delete-file-recursively (string-append >> - "pypy-dist/lib-pyt= hon/3/" x))) >> - '("tkinter/test" >> - "test" >> - "sqlite3/test" >> - "lib2to3/tests" >> - "idlelib/idle_test" >> - "distutils/tests" >> - "ctypes/test" >> - "unittest/test")) >> - ;; Patch shebang referencing python2 >> - (substitute* '("pypy-dist/lib-python/3/cgi.py" >> - "pypy-dist/lib-python/3/encoding= s/rot_13.py") >> - (("#!.+/bin/python") >> - (string-append "#!" (assoc-ref outputs "out"= ) "/bin/pypy3"))) >> - (with-fluids ((%default-port-encoding "ISO-8859= -1")) >> - (substitute* '("pypy-dist/lib_pypy/_md5.py" >> - "pypy-dist/lib_pypy/_sha1.py") >> - (("#!.+/bin/python") >> - (string-append "#!" (assoc-ref outputs "ou= t") "/bin/pypy3")))) >> - (copy-recursively "pypy-dist" (assoc-ref output= s "out"))) >> - #t))))) >> + (let* ((out (assoc-ref outputs "out")) >> + (bin-pypy3 (string-append out "/bin/pypy3"= )) >> + (shebang-match-python "#!.+/bin/python") >> + (shebang-pypy3 (string-append "#!" bin-pyp= y3)) >> + (dist-dir "pypy/tool/release/pypy-dist")) >> + (with-directory-excursion dist-dir >> + ;; Delete test data. >> + (for-each >> + (lambda (x) >> + (delete-file-recursively (string-append >> + "lib-python/3/" = x))) >> + '("tkinter/test" >> + "test" >> + "sqlite3/test" >> + "lib2to3/tests" >> + "idlelib/idle_test" >> + "distutils/tests" >> + "ctypes/test" >> + "unittest/test")) >> + ;; Patch shebang referencing python2 >> + (substitute* '("lib-python/3/cgi.py" >> + "lib-python/3/encodings/rot_13= .py") >> + ((shebang-match-python) shebang-pypy3)) >> + (with-fluids ((%default-port-encoding "ISO-88= 59-1")) >> + (substitute* '("lib_pypy/_md5.py" >> + "lib_pypy/_sha1.p= y") >> + ((shebang-match-python) sheban= g-pypy3)))) >> + (copy-recursively dist-dir out) >> + ;; Make sure pypy3 is callable as python/python= 3, so we >> + ;; don=E2=80=99t have to patch every single pac= kage. >> + (symlink bin-pypy3 (string-append out "/bin/pyt= hon")) >> + (symlink bin-pypy3 (string-append out "/bin/pyt= hon3")) >> + ;; 2to3 is missing from pypy3, create it. >> + (let ((2to3 (string-append out "/bin/2to3"))) >> + (call-with-output-file 2to3 >> + (lambda (port) >> + (format port "#!~a~%" (string-append out = "/bin/pypy3")) >> + (format port " >> +import sys >> +from lib2to3.main import main >> + >> +sys.exit(main('lib2to3.fixes'))"))) >> + (chmod 2to3 #o755)) >> + #t)))))) > > I'm unconvinced about the above symlinks; it seems preferable for users > to be able to unambiguously run both pypy3 and python3 (cpython) in the > same profile without conflicts. The pypy3 package on Debian contains > the following, for example: > > $ apt-file show pypy3 > pypy3: /usr/bin/pypy3 > pypy3: /usr/bin/pypy3clean > pypy3: /usr/bin/pypy3compile > pypy3: /usr/lib/libpypy3-c.so > pypy3: /usr/lib/pypy3/bin/libpypy3-c.so > pypy3: /usr/lib/pypy3/bin/pypy3-c > pypy3: /usr/lib/pypy3/include/pypy_decl.h > pypy3: /usr/lib/pypy3/include/pypy_macros.h > pypy3: /usr/lib/pypy3/include/pypy_marshal_decl.h > pypy3: /usr/lib/pypy3/include/pypy_structmember_decl.h > pypy3: /usr/lib/pypy3/lib_pypy/_audioop_cffi.pypy36-pp73-x86_64-linux-gnu= .so > pypy3: /usr/lib/pypy3/lib_pypy/_blake2/_blake2b_cffi.pypy36-pp73-x86_64-l= inux-gnu.so > pypy3: /usr/lib/pypy3/lib_pypy/_blake2/_blake2s_cffi.pypy36-pp73-x86_64-l= inux-gnu.so > pypy3: /usr/lib/pypy3/lib_pypy/_curses_cffi.pypy36-pp73-x86_64-linux-gnu.= so > pypy3: /usr/lib/pypy3/lib_pypy/_decimal_cffi.pypy36-pp73-x86_64-linux-gnu= .so > pypy3: /usr/lib/pypy3/lib_pypy/_gdbm_cffi.pypy36-pp73-x86_64-linux-gnu.so > pypy3: /usr/lib/pypy3/lib_pypy/_lzma_cffi.pypy36-pp73-x86_64-linux-gnu.so > pypy3: /usr/lib/pypy3/lib_pypy/_pwdgrp_cffi.pypy36-pp73-x86_64-linux-gnu.= so > pypy3: /usr/lib/pypy3/lib_pypy/_pypy_openssl.pypy36-pp73-x86_64-linux-gnu= .so > pypy3: /usr/lib/pypy3/lib_pypy/_resource_cffi.pypy36-pp73-x86_64-linux-gn= u.so > pypy3: /usr/lib/pypy3/lib_pypy/_sha3/_sha3_cffi.pypy36-pp73-x86_64-linux-= gnu.so > pypy3: /usr/lib/pypy3/lib_pypy/_sqlite3_cffi.pypy36-pp73-x86_64-linux-gnu= .so > pypy3: /usr/lib/pypy3/lib_pypy/_syslog_cffi.pypy36-pp73-x86_64-linux-gnu.= so > pypy3: /usr/share/doc/pypy3/TODO.Debian > pypy3: /usr/share/doc/pypy3/changelog.Debian.gz > pypy3: /usr/share/doc/pypy3/copyright > pypy3: /usr/share/lintian/overrides/pypy3 > pypy3: /usr/share/man/man1/pypy3.1.gz > >> + (native-search-paths >> + (list (search-path-specification >> + (variable "PYTHONPATH") >> + (files '("lib/pypy3.6/site-packages"))))) > > About this search path, how it is supposed to work? The version is > wrong (3.6) and the package doesn't include this directory, and we do > not have a pypy build system or other pypy packages that would make use > of it. Am I missing something? > > Thank you! > > Maxim I've upgraded pypy to version 7.3.5 and pushed the non-controversial changes from your 'small fixes' commit above as 7e05fda6e8dd72b63009181072a282ad15c25c4f. We can fix the search path after the next core-updates merge, where we'll be able to uniformize how it works with Python (GUIX_PYTHONPATH). Thanks, Closing. Maxim ------------=_1628182562-11487-1 Content-Type: message/rfc822 Content-Disposition: inline Content-Transfer-Encoding: 7bit Received: (at submit) by debbugs.gnu.org; 15 Nov 2020 12:39:43 +0000 Received: from localhost ([127.0.0.1]:52709 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1keHJb-0001Ug-PB for submit@debbugs.gnu.org; Sun, 15 Nov 2020 07:39:43 -0500 Received: from lists.gnu.org ([209.51.188.17]:51586) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1keHJX-0001UX-H2 for submit@debbugs.gnu.org; Sun, 15 Nov 2020 07:39:30 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]:37508) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1keHJX-0000MQ-9n for guix-patches@gnu.org; Sun, 15 Nov 2020 07:39:27 -0500 Received: from mout-p-202.mailbox.org ([80.241.56.172]:36728) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_CHACHA20_POLY1305:256) (Exim 4.90_1) (envelope-from ) id 1keHJS-0003xj-4X for guix-patches@gnu.org; Sun, 15 Nov 2020 07:39:26 -0500 Received: from smtp1.mailbox.org (smtp1.mailbox.org [IPv6:2001:67c:2050:105:465:1:1:0]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-384) server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by mout-p-202.mailbox.org (Postfix) with ESMTPS id 4CYsGD653nzQkHd for ; Sun, 15 Nov 2020 13:39:16 +0100 (CET) X-Virus-Scanned: amavisd-new at heinlein-support.de DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=6xq.net; s=MBO0001; t=1605443954; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=oyJIDXJI4qiuWp2UrmXpB4Y1dFtMBJ7E18KONefv5jM=; b=iliSyyIgYdZLLP1XSXwdB0F8Q1+VTffHOBaouE1aQ2N15DCVA9roj/2S31MatTZkAbkuwk pXfkuc3cpJHB4X7J+LLJmVR2n2BUd7HTTWx0KeL5ikuvj9NGxgmTZjqcg4tzPrDYA15vKj fHCKyHN5Y9fD4EBTDrp7/mxiCmuFc5D7ZTSxkaEnp4ed4DRarAOtUVbqSWOzraqSrCavMB ycwdb94aKLmQ/oWUKsYe86tH4zNSpV5Di8QxYDNLRcDOBwqqhxzkYGyFrLBS1ag1iIiN05 o70DpI6w9tyFfOK7oF+UJCmrrH4ZIAmapDRAHqft/xHwfCMBlBH8OHWikuCkNA== Received: from smtp1.mailbox.org ([80.241.60.240]) by spamfilter06.heinlein-hosting.de (spamfilter06.heinlein-hosting.de [80.241.56.125]) (amavisd-new, port 10030) with ESMTP id d69lETnppCky for ; Sun, 15 Nov 2020 13:39:12 +0100 (CET) Date: Sun, 15 Nov 2020 13:39:11 +0100 From: Lars-Dominik Braun To: guix-patches@gnu.org Subject: [PATCH] Upgrade pypy3 Message-ID: <20201115123911.GA1956@noor.fritz.box> MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="J/dobhs11T7y2rNN" Content-Disposition: inline Content-Transfer-Encoding: 8bit X-MBO-SPAM-Probability: X-Rspamd-Score: -10.75 / 15.00 / 15.00 X-Rspamd-Queue-Id: 9687E1831 X-Rspamd-UID: c28279 Received-SPF: pass client-ip=80.241.56.172; envelope-from=lars@6xq.net; helo=mout-p-202.mailbox.org X-detected-operating-system: by eggs.gnu.org: First seen = 2020/11/15 07:39:17 X-ACL-Warn: Detected OS = Linux 2.2.x-3.x [generic] [fuzzy] X-Spam_score_int: -27 X-Spam_score: -2.8 X-Spam_bar: -- X-Spam_report: (-2.8 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_LOW=-0.7, RCVD_IN_MSPIKE_H4=-0.01, RCVD_IN_MSPIKE_WL=-0.01, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-Spam-Score: -1.7 (-) X-Debbugs-Envelope-To: submit X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -0.3 (/) --J/dobhs11T7y2rNN Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Hi, the first patch in this series upgrades pypy3 to 7.3.2 and the second adjusts several aspects of the package. Lars --J/dobhs11T7y2rNN Content-Type: text/x-diff; charset=us-ascii Content-Disposition: attachment; filename="0001-gnu-pypy3-Update-to-7.3.2.patch" >From 0669431bc4ee103cf159f5f1d64684e6db8d6bb5 Mon Sep 17 00:00:00 2001 From: Lars-Dominik Braun Date: Sat, 17 Oct 2020 13:46:21 +0200 Subject: [PATCH 1/2] gnu: pypy3: Update to 7.3.2. * gnu/packages/python.scm (pypy3): Update to 7.3.2. --- gnu/packages/python.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gnu/packages/python.scm b/gnu/packages/python.scm index 43704bccae..8ef8ae2e1d 100644 --- a/gnu/packages/python.scm +++ b/gnu/packages/python.scm @@ -688,14 +688,14 @@ ease from the desktop to a microcontroller or embedded system.") (define-public pypy3 (package (name "pypy3") - (version "7.3.1") + (version "7.3.2") (source (origin (method url-fetch) - (uri (string-append "https://bitbucket.org/pypy/pypy/downloads/" ; + (uri (string-append "https://downloads.python.org/pypy/" "pypy3.6-v" version "-src.tar.bz2")) (sha256 (base32 - "10zsk8jby8j6visk5mzikpb1cidvz27qq4pfpa26jv53klic6b0c")) + "03f1fdw6yk2mypa9pbmgk26r8y1hhmw801l6g36zry9zsvz7aqgx")) (patches (search-patches "pypy3-7.3.1-fix-tests.patch")))) (build-system gnu-build-system) (native-inputs -- 2.26.2 --J/dobhs11T7y2rNN Content-Type: text/x-diff; charset=utf-8 Content-Disposition: attachment; filename="0002-gnu-pypy3-Various-package-fixes.patch" Content-Transfer-Encoding: 8bit >From caf5e4bf9acd10f91de2e6a9c60185475144a1b9 Mon Sep 17 00:00:00 2001 From: Lars-Dominik Braun Date: Sun, 15 Nov 2020 10:54:26 +0100 Subject: [PATCH 2/2] gnu: pypy3: Various package fixes. * gnu/packages/python.scm (pypy3) [patches]: Add new patch. [inputs]: Remove bash-minimal and add nss-certs. [native-inputs]: Remove nss-certs here. [arguments]: Use gdbm compat library, add 2to3 binary. [native-search-paths]: Add search path. * gnu/packages/patches/pypy3-7.3.1-ssl-paths.patch: New file. * gnu/local.mk: Add it. --- gnu/local.mk | 1 + .../patches/pypy3-7.3.1-ssl-paths.patch | 41 +++++++ gnu/packages/python.scm | 109 ++++++++++++------ 3 files changed, 116 insertions(+), 35 deletions(-) create mode 100644 gnu/packages/patches/pypy3-7.3.1-ssl-paths.patch diff --git a/gnu/local.mk b/gnu/local.mk index 91a3295e75..b644391a11 100644 --- a/gnu/local.mk +++ b/gnu/local.mk @@ -1536,6 +1536,7 @@ dist_patch_DATA = \ %D%/packages/patches/python-unittest2-remove-argparse.patch \ %D%/packages/patches/python-waitress-fix-tests.patch \ %D%/packages/patches/pypy3-7.3.1-fix-tests.patch \ + %D%/packages/patches/pypy3-7.3.1-ssl-paths.patch \ %D%/packages/patches/qemu-build-info-manual.patch \ %D%/packages/patches/qemu-glibc-2.27.patch \ %D%/packages/patches/qrcodegen-cpp-make-install.patch \ diff --git a/gnu/packages/patches/pypy3-7.3.1-ssl-paths.patch b/gnu/packages/patches/pypy3-7.3.1-ssl-paths.patch new file mode 100644 index 0000000000..d21133b4ae --- /dev/null +++ b/gnu/packages/patches/pypy3-7.3.1-ssl-paths.patch @@ -0,0 +1,41 @@ +Fix default certificate search path, still allowing the user to override it +with environment variables. + +--- a/lib_pypy/_cffi_ssl/_stdssl/__init__.py ++++ b/lib_pypy/_cffi_ssl/_stdssl/__init__.py +@@ -1679,20 +1679,9 @@ def get_default_verify_paths(): + https://golang.org/src/crypto/x509/root_linux.go (for the files) + ''' + certFiles = [ +- "/etc/ssl/certs/ca-certificates.crt", # Debian/Ubuntu/Gentoo etc. +- "/etc/pki/tls/certs/ca-bundle.crt", # Fedora/RHEL 6 +- "/etc/ssl/ca-bundle.pem", # OpenSUSE +- "/etc/pki/tls/cacert.pem", # OpenELEC +- "/etc/pki/ca-trust/extracted/pem/tls-ca-bundle.pem", # CentOS/RHEL 7 +- "/etc/ssl/cert.pem", # Alpine Linux + ] + certDirectories = [ +- "/etc/ssl/certs", # SLES10/SLES11 +- "/system/etc/security/cacerts", # Android +- "/usr/local/share/certs", # FreeBSD +- "/etc/pki/tls/certs", # Fedora/RHEL +- "/etc/openssl/certs", # NetBSD +- "/var/ssl/certs", # AIX ++ "@GUIX_CERT_PATH@", + ] + + # optimization: reuse the values from a local varaible +@@ -1707,9 +1696,10 @@ def get_default_verify_paths(): + ofile = _cstr_decode_fs(lib.X509_get_default_cert_file()) + odir = _cstr_decode_fs(lib.X509_get_default_cert_dir()) + +- if os.path.exists(ofile) and os.path.exists(odir): +- get_default_verify_paths.retval = (ofile_env, ofile, odir_env, odir) +- return get_default_verify_paths.retval ++ if not os.path.exists(ofile): ++ ofile = None ++ if not os.path.exists(odir): ++ odir = None + + # OpenSSL didn't supply the goods. Try some other options + for f in certFiles: diff --git a/gnu/packages/python.scm b/gnu/packages/python.scm index 8ef8ae2e1d..c0bd3335e3 100644 --- a/gnu/packages/python.scm +++ b/gnu/packages/python.scm @@ -696,7 +696,8 @@ ease from the desktop to a microcontroller or embedded system.") (sha256 (base32 "03f1fdw6yk2mypa9pbmgk26r8y1hhmw801l6g36zry9zsvz7aqgx")) - (patches (search-patches "pypy3-7.3.1-fix-tests.patch")))) + (patches (search-patches "pypy3-7.3.1-fix-tests.patch" + "pypy3-7.3.1-ssl-paths.patch")))) (build-system gnu-build-system) (native-inputs `(("python-2" ,python-2) @@ -704,13 +705,13 @@ ease from the desktop to a microcontroller or embedded system.") ("tar" ,tar) ; Required for package.py ("python2-pycparser" ,python2-pycparser) ("python2-hypothesis" ,python2-hypothesis) - ("nss-certs" ,nss-certs) ; For ssl tests ("gzip" ,gzip))) (inputs `(("libffi" ,libffi) ("zlib" ,zlib) ("ncurses" ,ncurses) ("openssl" ,openssl) + ("nss-certs" ,nss-certs) ; For ssl module ("expat" ,expat) ("bzip2" ,bzip2) ("sqlite" ,sqlite) @@ -718,10 +719,9 @@ ease from the desktop to a microcontroller or embedded system.") ("tcl" ,tcl) ("tk" ,tk) ("glibc" ,glibc) - ("bash-minimal" ,bash-minimal) ; Used as /bin/sh ("xz" ,xz))) ; liblzma (arguments - `(#:tests? #f ;FIXME: Disabled for now, there are many tests failing. + `(#:tests? #f ;FIXME: Disabled for now, there are many tests failing. #:modules ((ice-9 ftw) (ice-9 match) (guix build utils) (guix build gnu-build-system)) #:phases (modify-phases %standard-phases @@ -750,6 +750,11 @@ ease from the desktop to a microcontroller or embedded system.") (substitute* '("lib_pypy/_curses_build.py") ;; Find curses (("/usr/local") (assoc-ref inputs "ncurses"))) + (substitute* '("lib_pypy/_dbm.py") + ;; Use gdbm compat library, so we don’t need to pull in bdb + (("ctypes.util.find_library\\('db'\\)") + (string-append "'" (assoc-ref inputs "gdbm") + "/lib/libgdbm_compat.so'"))) (substitute* '("lib_pypy/_sqlite3_build.py") ;; Always use search paths (("sys\\.platform\\.startswith\\('freebsd'\\)") "True") @@ -761,11 +766,18 @@ ease from the desktop to a microcontroller or embedded system.") "/lib/libsqlite3.so.0'"))) (substitute* '("lib-python/3/subprocess.py") ;; Fix shell path - (("/bin/sh") - (string-append (assoc-ref inputs "bash-minimal") "/bin/sh"))) + (("/bin/sh") (which "sh"))) (substitute* '("lib-python/3/distutils/unixccompiler.py") ;; gcc-toolchain does not provide symlink cc -> gcc (("\"cc\"") "\"gcc\"")) + (substitute* '("lib_pypy/_cffi_ssl/_stdssl/__init__.py") + ;; Add nss-certs to default certificate search path, + ;; otherwise every packages has to specify nss-certs and + ;; openssl as input to set the proper env variables. + ;; Depends on -ssl-paths.patch. + (("@GUIX_CERT_PATH@") + (string-append (assoc-ref inputs "nss-certs") + "/etc/ssl/certs"))) #t)) (add-after 'unpack 'set-source-file-times-to-1980 @@ -785,7 +797,8 @@ ease from the desktop to a microcontroller or embedded system.") (string-append "--make-jobs=" (number->string (parallel-job-count))) "-Ojit" - "targetpypystandalone")) + "targetpypystandalone" + "--allworkingmodules")) ;; Build c modules and package everything, so tests work. (with-directory-excursion "pypy/tool/release" (unsetenv "PYTHONPATH") ; Do not use the system’s python libs: @@ -793,7 +806,12 @@ ease from the desktop to a microcontroller or embedded system.") ; attribute 'IntFlag' (invoke "python2" "package.py" "--archive-name" "pypy-dist" - "--builddir" (getcwd))))) + "--builddir" (getcwd)) + ;; install pip and setuptools into the dist directory. + ;; XXX: Breaks virtualenv, because it does not set +w + ;; on files copied from the store. + ;(invoke "pypy-dist/bin/pypy3" "-m" "ensurepip") + ))) (replace 'check (lambda* (#:key tests? #:allow-other-keys) (if tests? @@ -811,32 +829,54 @@ ease from the desktop to a microcontroller or embedded system.") #t)) (replace 'install (lambda* (#:key inputs outputs #:allow-other-keys) - (with-directory-excursion "pypy/tool/release" - ;; Delete test data. - (for-each - (lambda (x) - (delete-file-recursively (string-append - "pypy-dist/lib-python/3/" x))) - '("tkinter/test" - "test" - "sqlite3/test" - "lib2to3/tests" - "idlelib/idle_test" - "distutils/tests" - "ctypes/test" - "unittest/test")) - ;; Patch shebang referencing python2 - (substitute* '("pypy-dist/lib-python/3/cgi.py" - "pypy-dist/lib-python/3/encodings/rot_13.py") - (("#!.+/bin/python") - (string-append "#!" (assoc-ref outputs "out") "/bin/pypy3"))) - (with-fluids ((%default-port-encoding "ISO-8859-1")) - (substitute* '("pypy-dist/lib_pypy/_md5.py" - "pypy-dist/lib_pypy/_sha1.py") - (("#!.+/bin/python") - (string-append "#!" (assoc-ref outputs "out") "/bin/pypy3")))) - (copy-recursively "pypy-dist" (assoc-ref outputs "out"))) - #t))))) + (let* ((out (assoc-ref outputs "out")) + (bin-pypy3 (string-append out "/bin/pypy3")) + (shebang-match-python "#!.+/bin/python") + (shebang-pypy3 (string-append "#!" bin-pypy3)) + (dist-dir "pypy/tool/release/pypy-dist")) + (with-directory-excursion dist-dir + ;; Delete test data. + (for-each + (lambda (x) + (delete-file-recursively (string-append + "lib-python/3/" x))) + '("tkinter/test" + "test" + "sqlite3/test" + "lib2to3/tests" + "idlelib/idle_test" + "distutils/tests" + "ctypes/test" + "unittest/test")) + ;; Patch shebang referencing python2 + (substitute* '("lib-python/3/cgi.py" + "lib-python/3/encodings/rot_13.py") + ((shebang-match-python) shebang-pypy3)) + (with-fluids ((%default-port-encoding "ISO-8859-1")) + (substitute* '("lib_pypy/_md5.py" + "lib_pypy/_sha1.py") + ((shebang-match-python) shebang-pypy3)))) + (copy-recursively dist-dir out) + ;; Make sure pypy3 is callable as python/python3, so we + ;; don’t have to patch every single package. + (symlink bin-pypy3 (string-append out "/bin/python")) + (symlink bin-pypy3 (string-append out "/bin/python3")) + ;; 2to3 is missing from pypy3, create it. + (let ((2to3 (string-append out "/bin/2to3"))) + (call-with-output-file 2to3 + (lambda (port) + (format port "#!~a~%" (string-append out "/bin/pypy3")) + (format port " +import sys +from lib2to3.main import main + +sys.exit(main('lib2to3.fixes'))"))) + (chmod 2to3 #o755)) + #t)))))) + (native-search-paths + (list (search-path-specification + (variable "PYTHONPATH") + (files '("lib/pypy3.6/site-packages"))))) (home-page "https://www.pypy.org/") (synopsis "Python implementation with just-in-time compilation") (description "PyPy is a faster, alternative implementation of the Python @@ -849,4 +889,3 @@ Python code natively, including C extensions.") license:bsd-3 ; lib_pypy/cffi/_pycparser/ply/ (license:non-copyleft "http://www.unicode.org/copyright.html"))))) - -- 2.26.2 --J/dobhs11T7y2rNN-- ------------=_1628182562-11487-1-- From unknown Sat Jun 21 10:35:20 2025 X-Loop: help-debbugs@gnu.org Subject: [bug#44656] [PATCH] Upgrade pypy3 Resent-From: Lars-Dominik Braun Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Fri, 06 Aug 2021 07:31:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 44656 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: Maxim Cournoyer Cc: 44656@debbugs.gnu.org Received: via spool by 44656-submit@debbugs.gnu.org id=B44656.162823504632043 (code B ref 44656); Fri, 06 Aug 2021 07:31:01 +0000 Received: (at 44656) by debbugs.gnu.org; 6 Aug 2021 07:30:46 +0000 Received: from localhost ([127.0.0.1]:49005 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mBuJa-0008Kl-3z for submit@debbugs.gnu.org; Fri, 06 Aug 2021 03:30:46 -0400 Received: from mout-p-101.mailbox.org ([80.241.56.151]:20762) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mBuJX-0008KV-4w for 44656@debbugs.gnu.org; Fri, 06 Aug 2021 03:30:44 -0400 Received: from smtp2.mailbox.org (smtp2.mailbox.org [IPv6:2001:67c:2050:105:465:1:2:0]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-384) server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by mout-p-101.mailbox.org (Postfix) with ESMTPS id 4GgxwD56cDzQk9c; Fri, 6 Aug 2021 09:30:36 +0200 (CEST) X-Virus-Scanned: amavisd-new at heinlein-support.de DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=6xq.net; s=MBO0001; t=1628235035; 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: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=A66bCkmfcfRj2aGAd9Br/fE/7UuIu8aYNTgDENRvk3Q=; b=Vvn+bQrO8K2vEOXByb8vzEf907Am0XEnrhg4h4h8uAOSbKipnRl1zpHl9iZccXp0wnc4BG dDGJWsyRGuIK0ju2tSxSP/2+OQthJIIdmxmUKzjy6V1wyRJjHiE8+NJOtIn61O0D66saXH kw8eNchzE0InutWHbSx5JAv5IAGve0xRJrHdBLROuy5ClFZNlnoLDY+KDGe5k09rkFRwN+ kKJqScW/ftytgOuHubHogXxwjK6DMOITAqtSbSZ594IKQZgqHwos61xYyFJuka3pTqvbXu Jf7A1j8nmRiGRbPhgRg8SUuwvJUvOshsy+mqGaXy0eszJza4szmKdI/7SAgbWw== Received: from smtp2.mailbox.org ([80.241.60.241]) by spamfilter06.heinlein-hosting.de (spamfilter06.heinlein-hosting.de [80.241.56.125]) (amavisd-new, port 10030) with ESMTP id xESajohKJ6K5; Fri, 6 Aug 2021 09:30:34 +0200 (CEST) Date: Fri, 6 Aug 2021 09:30:32 +0200 From: Lars-Dominik Braun Message-ID: References: <20201115123911.GA1956@noor.fritz.box> <87eeba8ay7.fsf@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <87eeba8ay7.fsf@gmail.com> X-Rspamd-Queue-Id: E123F183B X-Rspamd-UID: c304b2 X-Spam-Score: -0.7 (/) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) Hi Maxim, I realize I’m late, so only one comment: > > + (native-search-paths > > + (list (search-path-specification > > + (variable "PYTHONPATH") > > + (files '("lib/pypy3.6/site-packages"))))) > About this search path, how it is supposed to work? The version is > wrong (3.6) and the package doesn't include this directory, and we do > not have a pypy build system or other pypy packages that would make use > of it. Am I missing something? No, the the version is not wrong. pypy tracks CPython’s development (features, standard library) and thus implements a certain “Python version”, in this case 3.6, even though pypy’s own version says something else. But, as you said, pypy in Guix is not really useful anyway right now without any packages. (That was the idea of the symlinks by the way, providing pypy as a drop-in replacement for python-wrapper in python-build-system.) Cheers, Lars From unknown Sat Jun 21 10:35:20 2025 X-Loop: help-debbugs@gnu.org Subject: [bug#44656] [PATCH] Upgrade pypy3 Resent-From: Maxim Cournoyer Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Fri, 06 Aug 2021 14:24:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 44656 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: Lars-Dominik Braun Cc: 44656@debbugs.gnu.org Received: via spool by 44656-submit@debbugs.gnu.org id=B44656.162825978513237 (code B ref 44656); Fri, 06 Aug 2021 14:24:01 +0000 Received: (at 44656) by debbugs.gnu.org; 6 Aug 2021 14:23:05 +0000 Received: from localhost ([127.0.0.1]:51148 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mC0kb-0003RR-35 for submit@debbugs.gnu.org; Fri, 06 Aug 2021 10:23:05 -0400 Received: from mail-qv1-f53.google.com ([209.85.219.53]:35619) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mC0kZ-0003Qk-C4 for 44656@debbugs.gnu.org; Fri, 06 Aug 2021 10:23:03 -0400 Received: by mail-qv1-f53.google.com with SMTP id 3so4951843qvd.2 for <44656@debbugs.gnu.org>; Fri, 06 Aug 2021 07:23:03 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version:content-transfer-encoding; bh=ZYfLN00J9miXMyyJdqEFBcmWssnCKakQ/uEP7vpCUJM=; b=N4uTPbEnIlC+CkI89lsTn13Bl10FumP1LIeBENG6nqtrQmlsHLXlH9vjuu75dNddzc 35OQ3M7ad8Of9mu5IRGX2Enos1zaube736ox8W7eIlRzg3DdD4ZYDbHCqYTeqegEAHu/ +Xk4HweiOuDxx8OtzEYzRVEyPgeI2tKD9kKeMaxb2J8GGSSMJX8i3ocQJAhBDLwoa6Kh 6X4vN69WCA5YOtcFyx1Bk1g876EIEIMHz0NJ7cSJDMr55nyMVXCo9mPM8c/Z+spIJYof 4g/Z3w+D2MR0PXfNEzBwL/AucdV/rKXuN5ZI72gvpxvFVe/zOWb66Ym2kpkCkRwFq2jG e4Dg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:references:date:in-reply-to :message-id:user-agent:mime-version:content-transfer-encoding; bh=ZYfLN00J9miXMyyJdqEFBcmWssnCKakQ/uEP7vpCUJM=; b=Z0usvSsovCXHfle5Ntw9Ze//rynUrt+3D88AxjgbxBEOoUPQCur5dMqLBg711zAz36 fJuBAzXqMMlRM/5lUZ1zbSZyQty3UxSYSm57gBumuTaq0InMl/R8AUBEkIGQX3IxPTY3 +sULex2tz8rh559P9dNaeQohrwvLEmVIMViZgNbTtdUC6LUdEDm7EsASk9cuyA4vbj1t oIXZJcg+yfgNTSmO1HHeYumgdH9CxOkMk40oTKutljdCtyQyywP/OiOp87eRkvveq++T tV4ywOBltlj4UmimDbltvYrkHozY6L9UwWgwhEaKw5aC132o/4NSKMOP6iPjVyIp2Gc3 KuKg== X-Gm-Message-State: AOAM531t6GyxfwLN+wBVkxtNBGxR1Klro6Y7ifLkD3MNHLYFI11NUW75 fnpFeDtyZnnQQkIYhdjHxHYiDgyA5ucHrFD2 X-Google-Smtp-Source: ABdhPJxtnSnRqzymVkAtuOLvw+NEFoRGf4W9KwDLn5ywkxlNVCulPR+/75Q889XhW0PEJlbIIGSKGA== X-Received: by 2002:ad4:4eaf:: with SMTP id ed15mr11482049qvb.11.1628259776326; Fri, 06 Aug 2021 07:22:56 -0700 (PDT) Received: from raisin ([2607:fad8:4:6:235e:8579:8464:aacc]) by smtp.gmail.com with ESMTPSA id q10sm3603915qti.68.2021.08.06.07.22.54 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 06 Aug 2021 07:22:55 -0700 (PDT) From: Maxim Cournoyer References: <20201115123911.GA1956@noor.fritz.box> <87eeba8ay7.fsf@gmail.com> Date: Fri, 06 Aug 2021 10:22:54 -0400 In-Reply-To: (Lars-Dominik Braun's message of "Fri, 6 Aug 2021 09:30:32 +0200") Message-ID: <87k0ky7iv5.fsf@gmail.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.2 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Spam-Score: 0.0 (/) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) Hello Lars-Dominik, Lars-Dominik Braun writes: > Hi Maxim, > > I realize I=E2=80=99m late, so only one comment: > >> > + (native-search-paths >> > + (list (search-path-specification >> > + (variable "PYTHONPATH") >> > + (files '("lib/pypy3.6/site-packages"))))) >> About this search path, how it is supposed to work? The version is >> wrong (3.6) and the package doesn't include this directory, and we do >> not have a pypy build system or other pypy packages that would make use >> of it. Am I missing something? > No, the the version is not wrong. pypy tracks CPython=E2=80=99s developme= nt > (features, standard library) and thus implements a certain =E2=80=9CPython > version=E2=80=9D, in this case 3.6, even though pypy=E2=80=99s own versio= n says > something else. But, as you said, pypy in Guix is not really useful > anyway right now without any packages. > > (That was the idea of the symlinks by the way, providing pypy as a > drop-in replacement for python-wrapper in python-build-system.) > > Cheers, > Lars Thanks for taking the time to explain! It makes sense, but I'd need to educate myself better about how Pypy can be used along our current Python version library (as in, does it require its own .pyc files? Does it dismiss CPython's produced ones? Can we not point it to consume our existing Python libraries (it's different sys.path suggest differently), etc.) Maxim From unknown Sat Jun 21 10:35:20 2025 X-Loop: help-debbugs@gnu.org Subject: [bug#44656] [PATCH] Upgrade pypy3 Resent-From: Lars-Dominik Braun Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Fri, 06 Aug 2021 14:45:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 44656 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: Maxim Cournoyer Cc: 44656@debbugs.gnu.org Received: via spool by 44656-submit@debbugs.gnu.org id=B44656.162826105515245 (code B ref 44656); Fri, 06 Aug 2021 14:45:02 +0000 Received: (at 44656) by debbugs.gnu.org; 6 Aug 2021 14:44:15 +0000 Received: from localhost ([127.0.0.1]:51154 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mC154-0003xp-TF for submit@debbugs.gnu.org; Fri, 06 Aug 2021 10:44:15 -0400 Received: from mout-p-201.mailbox.org ([80.241.56.171]:48320) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mC150-0003xZ-Mj for 44656@debbugs.gnu.org; Fri, 06 Aug 2021 10:44:13 -0400 Received: from smtp1.mailbox.org (smtp1.mailbox.org [IPv6:2001:67c:2050:105:465:1:1:0]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-384) server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by mout-p-201.mailbox.org (Postfix) with ESMTPS id 4Gh7XN1JGhzQk3T; Fri, 6 Aug 2021 16:44:04 +0200 (CEST) X-Virus-Scanned: amavisd-new at heinlein-support.de DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=6xq.net; s=MBO0001; t=1628261042; 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: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=0UqAaRe+hMiHzxnqFYjZvvNda3KXEAi5tJz+FF6S/OE=; b=RHo/oMvXCZzpUga/fhoiXF2q3v1xgnxy9PcXQ65MsqYFxqqaeRswQP7XJJS3gyAGIJwGtm EqHWaRhG5VyowwPSumNrBqtyveoOZwbCdPQr0VT5DrRatIauVmn7CjLxcZhT42eN+zaEWx he4TnJqZjmMRmdwYKSfr+hkY3yTlm10yKRbumSn5NqVDWI+P53wD5IRRJMBrQqV8QaN6tq xO1aOAmy7xgZeQsfiF1aYVahn9Pl0aMVc35sBe/43BYDby09UpwNdz40xWBatpRmlWco91 wBkp0Gj31sh8bfW0ySKN5PNuzDJg0OmkVT9ytAvMEP46PsLQz17P9/+5lnLWJg== Received: from smtp1.mailbox.org ([80.241.60.240]) by spamfilter03.heinlein-hosting.de (spamfilter03.heinlein-hosting.de [80.241.56.117]) (amavisd-new, port 10030) with ESMTP id vH6j5MJ7KyXh; Fri, 6 Aug 2021 16:44:01 +0200 (CEST) Date: Fri, 6 Aug 2021 16:43:59 +0200 From: Lars-Dominik Braun Message-ID: References: <20201115123911.GA1956@noor.fritz.box> <87eeba8ay7.fsf@gmail.com> <87k0ky7iv5.fsf@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <87k0ky7iv5.fsf@gmail.com> X-Rspamd-Queue-Id: 330AD1899 X-Rspamd-UID: 6b04ed X-Spam-Score: -0.7 (/) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) Hello Maxim, that’s answered quickly: > does it require its own .pyc files? Yes, .pyc files are implementation-dependent, as their name suggests (module.implementation-version.pyc). > Does it dismiss CPython's produced ones? It won’t look at them. > Can we not point it to consume our existing Python libraries (it's > different sys.path suggest differently), etc.) Technically plain Python modules should “just work”, but C extensions must be recompiled, so usually it’s safer to run setup.py using PyPy and install into a PyPy-specific site-modules. Cheers, Lars From unknown Sat Jun 21 10:35:20 2025 X-Loop: help-debbugs@gnu.org Subject: [bug#44656] [PATCH] Upgrade pypy3 Resent-From: Maxim Cournoyer Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Sat, 07 Aug 2021 01:30:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 44656 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: Lars-Dominik Braun Cc: 44656@debbugs.gnu.org Received: via spool by 44656-submit@debbugs.gnu.org id=B44656.162829977220103 (code B ref 44656); Sat, 07 Aug 2021 01:30:02 +0000 Received: (at 44656) by debbugs.gnu.org; 7 Aug 2021 01:29:32 +0000 Received: from localhost ([127.0.0.1]:51624 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mCB9X-0005EB-V2 for submit@debbugs.gnu.org; Fri, 06 Aug 2021 21:29:32 -0400 Received: from mail-qt1-f177.google.com ([209.85.160.177]:39672) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mCB9W-0005Dy-2w for 44656@debbugs.gnu.org; Fri, 06 Aug 2021 21:29:31 -0400 Received: by mail-qt1-f177.google.com with SMTP id d2so7876959qto.6 for <44656@debbugs.gnu.org>; Fri, 06 Aug 2021 18:29:30 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version:content-transfer-encoding; bh=oorEzy+ah6bggA59O1Sr/yfypY48fEY150EL/U2bWsg=; b=Vke/z7NQehKotm8g+CvyjYjpir9EemR9IzNFzR9IU5jTsWAMTG84lUpWvdJq3LF5ry ekSnY66iDD1Du+MqGnkbY95KXkZUQmCDbmyrOJg6I0/61Ilms1fEaY1MmfilaakDAJnk 2bk9ByEfWK+1jqR5Hx03wejiZ+WASnKv0DHg3nkNZoTsT8aFU3AdEa9pxlTf+/4GLZZo 0aJz0yEqtuFhXOurkpw3qgNlhmVgEhXlht+Gd/3se06P5sm6zWai1p6S2bTKvMyfwG8C ldl6isWrc5BXxvBfdhjqhTuiIP57OwuvPJ0E9eclfuUZVNIjhe6Ndin7kZ7LPJ4lRBw9 eWqg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:references:date:in-reply-to :message-id:user-agent:mime-version:content-transfer-encoding; bh=oorEzy+ah6bggA59O1Sr/yfypY48fEY150EL/U2bWsg=; b=mZcYYYU7SKBu7g5AreqUAmQB0tSROOLlSnSTsRzTlA86cbpHJ3erkZA72qrO8Vgnnr URWKDeUddth0jMxZeTOMi+I0H+QnA3819vZYDtroSUY2JJBkX1mkWp9Qrd5gRqYqtDfm I4yHtejHBfWJPlYT+ZDfH2rAe/onKlIC1aopgy4kqsR1sSWn/lyB+3C717lqQ+mEoM5G V86/LVqsXpY1dEjg7zZAR/6Ow0ZTwkDCfRyqNu/6YspyXi6hfixtIkq+ajZrGixRTkn+ jL/yWfEhFou5IH1rji5P0eFa6hRQokLvTD5WpqVXyP5+T4MjBRt/oL+66pbYwMls1vWM SKyg== X-Gm-Message-State: AOAM531GnP2Kea/Rgw6/AM8LcCW8DskCCMHDD8gW81EwcKuJfGcCBmb/ ZkNNl2MMA0d8A9Fm0EuwdrgksZJuXiD4t2ox X-Google-Smtp-Source: ABdhPJzUlbeOctHcxGq/bG8Tz1ja03py+H3aw9V4RIitGBbkX7U7QeB1TdRJ1DqFuDnk9kpJrWgPFg== X-Received: by 2002:ac8:548a:: with SMTP id h10mr11104490qtq.89.1628299764272; Fri, 06 Aug 2021 18:29:24 -0700 (PDT) Received: from hurd (dsl-151-109.b2b2c.ca. [66.158.151.109]) by smtp.gmail.com with ESMTPSA id c27sm4686400qkp.5.2021.08.06.18.29.23 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 06 Aug 2021 18:29:23 -0700 (PDT) From: Maxim Cournoyer References: <20201115123911.GA1956@noor.fritz.box> <87eeba8ay7.fsf@gmail.com> <87k0ky7iv5.fsf@gmail.com> Date: Fri, 06 Aug 2021 21:29:22 -0400 In-Reply-To: (Lars-Dominik Braun's message of "Fri, 6 Aug 2021 16:43:59 +0200") Message-ID: <87h7g2jb4d.fsf@gmail.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.2 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Spam-Score: -0.0 (/) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) Hi Lars-Dominik, Lars-Dominik Braun writes: > Hello Maxim, > > that=E2=80=99s answered quickly: > >> does it require its own .pyc files? > Yes, .pyc files are implementation-dependent, as their name suggests > (module.implementation-version.pyc). > >> Does it dismiss CPython's produced ones? > It won=E2=80=99t look at them. > >> Can we not point it to consume our existing Python libraries (it's >> different sys.path suggest differently), etc.) > Technically plain Python modules should =E2=80=9Cjust work=E2=80=9D, but = C extensions > must be recompiled, so usually it=E2=80=99s safer to run setup.py using P= yPy and > install into a PyPy-specific site-modules. Thanks for the insights. I guess one way it could work was if we had some transformation option to rebuild the Python collection against Pypy (do we have something to do this already?). Thanks, Maxim From unknown Sat Jun 21 10:35:20 2025 X-Loop: help-debbugs@gnu.org Subject: [bug#44656] [PATCH] Upgrade pypy3 Resent-From: Lars-Dominik Braun Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Sat, 07 Aug 2021 07:00:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 44656 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: Maxim Cournoyer Cc: 44656@debbugs.gnu.org Received: via spool by 44656-submit@debbugs.gnu.org id=B44656.16283195593678 (code B ref 44656); Sat, 07 Aug 2021 07:00:02 +0000 Received: (at 44656) by debbugs.gnu.org; 7 Aug 2021 06:59:19 +0000 Received: from localhost ([127.0.0.1]:51868 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mCGIh-0000xG-50 for submit@debbugs.gnu.org; Sat, 07 Aug 2021 02:59:19 -0400 Received: from mout-p-202.mailbox.org ([80.241.56.172]:35756) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mCGId-0000wz-30 for 44656@debbugs.gnu.org; Sat, 07 Aug 2021 02:59:17 -0400 Received: from smtp1.mailbox.org (smtp1.mailbox.org [IPv6:2001:67c:2050:105:465:1:1:0]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-384) server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by mout-p-202.mailbox.org (Postfix) with ESMTPS id 4GhY9S3ndwzQkF8; Sat, 7 Aug 2021 08:59:08 +0200 (CEST) X-Virus-Scanned: amavisd-new at heinlein-support.de DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=6xq.net; s=MBO0001; t=1628319546; 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: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=11VlvCru3xdWjpmBo7Qf0KtxAwA5Ozbnc6jk2kxKhW4=; b=e+SA1e4pVJY2UaPQiOjhsT3T2oFtdXJuQI+oaKLXPTYqg7tosammobw5rpjOz9wl7H9d8/ D22ctV1T/IimNeeC470Vr60xDcW6Qd0toZ19lFVf70ORRMqx0hCt1rG5LGNJ2j+fnjObjf Yk2CSozwG3Fkm2PcERfNaFF/UR4KQytRQr80DGCI6uxYpb4L+OjueOPr6T0jQRpDPc1kvf wfY1rrY34gB6GmnZMUl+QntbE9Oa6Yf6s5tQK+i0u9nbt5VgCQSd0GCtNhm66EyQFeTvua LiJ4yxMXHcK9ndyCPTpJcvcOmu6KHL4tflupa2FD6rWGDF+KzZt5/nDQV7PApA== Received: from smtp1.mailbox.org ([80.241.60.240]) by spamfilter03.heinlein-hosting.de (spamfilter03.heinlein-hosting.de [80.241.56.117]) (amavisd-new, port 10030) with ESMTP id n2144zpYDQZ7; Sat, 7 Aug 2021 08:59:05 +0200 (CEST) Date: Sat, 7 Aug 2021 08:59:03 +0200 From: Lars-Dominik Braun Message-ID: References: <20201115123911.GA1956@noor.fritz.box> <87eeba8ay7.fsf@gmail.com> <87k0ky7iv5.fsf@gmail.com> <87h7g2jb4d.fsf@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <87h7g2jb4d.fsf@gmail.com> X-Rspamd-Queue-Id: 9110A1899 X-Rspamd-UID: abf75b X-Spam-Score: -0.7 (/) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) Hi Maxim, > I guess one way it could work was if we had some transformation option > to rebuild the Python collection against Pypy (do we have something to > do this already?). yes, there is package-with-explicit-python in (guix build-system python), but you’ll need transform every single existing Python package with it to make it usable with PyPy (just like Python 2). There’s also --with-input=python=pypy3, but I think it will rewrite too much (i.e. not just packages using python-build-system, but *every* package in the graph using Python in any way). Cheers, Lars From unknown Sat Jun 21 10:35:20 2025 X-Loop: help-debbugs@gnu.org Subject: [bug#44656] [PATCH] Upgrade pypy3 Resent-From: zimoun Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Fri, 20 Aug 2021 11:03:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 44656 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: Lars-Dominik Braun , Maxim Cournoyer Cc: 44656@debbugs.gnu.org Received: via spool by 44656-submit@debbugs.gnu.org id=B44656.162945735423292 (code B ref 44656); Fri, 20 Aug 2021 11:03:01 +0000 Received: (at 44656) by debbugs.gnu.org; 20 Aug 2021 11:02:34 +0000 Received: from localhost ([127.0.0.1]:33030 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mH2I9-00063X-PX for submit@debbugs.gnu.org; Fri, 20 Aug 2021 07:02:33 -0400 Received: from mail-wm1-f49.google.com ([209.85.128.49]:37736) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mH2I3-00063G-TU for 44656@debbugs.gnu.org; Fri, 20 Aug 2021 07:02:28 -0400 Received: by mail-wm1-f49.google.com with SMTP id c8-20020a7bc008000000b002e6e462e95fso8834499wmb.2 for <44656@debbugs.gnu.org>; Fri, 20 Aug 2021 04:02:23 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:in-reply-to:references:date:message-id :mime-version:content-transfer-encoding; bh=nKlP8/82PW6C1Tt9r3XqoYXLMdQrHapOU2fkMQxtXGk=; b=lOh8Drw3X/qAqCB9LnKtoVvgdwkwEHoH1TpADKYLn+C0Tzq8bcYBeS6q2zydDA3dC9 mLtWWPVl5u/JwwSAXRneSlFbuE4LW/4RRUMVpIHSC7UPyjC+nqkDX+nOJkwDDZx7V3+C DICOE55f2ZcIlri69F3GL0tWLD/ku9HIHuNzdsHsBGLBUxJyWVbyNu2EaT3EeFgZoaBn tspFS1CbDnNZ5Ug2wKSlALfcfdWIIBjYvZWz9bleX9dlczqtiBp7NZ772dsCQhT96PQ1 5y6iHSLxS4CxmfBQ3mOCMpLXsByPlEEszwRsEu46frkYg6JHu3VDmU7U0ZahfgiXlifz RgXw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:in-reply-to:references:date :message-id:mime-version:content-transfer-encoding; bh=nKlP8/82PW6C1Tt9r3XqoYXLMdQrHapOU2fkMQxtXGk=; b=oRKSXHSdHrC5tr2DAxoNDpvFRxBpLygwzjirZLFptF2GDvGAqWnnn/zxMdGFOe21qW aTx0DuzejEP/sHZ92Fjg61pu8CeQWPcg/NzeZtlkpN5ZyKgB+hvA6dhB9ikN1FpiuqV3 HxcQkGa4W464N4v1+22lfm8f0HDwsAKM1QKKZaMGHCsJTS4zZCeX2/ycCcU+HO6h+uRr unRK1YkEBDTG9gY1bqbDk7iKMfGP9KhCXKmZDlmozlnALta2FwsZcdwhDkQlNa4l/8u8 2qmZJlOFdla10h8TMwp+4sCdQyQXoa5TuKrz7K7FrW06DbEty42UHDqN86G+oMzPvP6N +yOQ== X-Gm-Message-State: AOAM530BItLcmT9Bf59ee3DFXKS4jSprX73fbjjBkRKsNeW51iOwTJ5P o7OqRbHj02P9rMorYvJ2E1P3KfDagc/Pww== X-Google-Smtp-Source: ABdhPJyGHT0KnhK4QvLi9hSuV+KcUXn+ZMQt6PWMD7Nh1DBVJ7rmS8jniFwmuNWdbv3+zLTe6+hQHQ== X-Received: by 2002:a05:600c:4fcc:: with SMTP id o12mr3398148wmq.0.1629457338004; Fri, 20 Aug 2021 04:02:18 -0700 (PDT) Received: from lili ([2a01:e0a:59b:9120:65d2:2476:f637:db1e]) by smtp.gmail.com with ESMTPSA id x19sm4755228wmi.30.2021.08.20.04.02.17 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 20 Aug 2021 04:02:17 -0700 (PDT) From: zimoun In-Reply-To: References: <20201115123911.GA1956@noor.fritz.box> <87eeba8ay7.fsf@gmail.com> <87k0ky7iv5.fsf@gmail.com> <87h7g2jb4d.fsf@gmail.com> Date: Fri, 20 Aug 2021 12:39:20 +0200 Message-ID: <86tujko0x3.fsf@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Spam-Score: 0.0 (/) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) Hi, On Sat, 07 Aug 2021 at 08:59, Lars-Dominik Braun wrote: > Hi Maxim, > >> I guess one way it could work was if we had some transformation option >> to rebuild the Python collection against Pypy (do we have something to >> do this already?). > yes, there is package-with-explicit-python in (guix build-system > python), but you=E2=80=99ll need transform every single existing Python p= ackage > with it to make it usable with PyPy (just like Python 2). There=E2=80=99s= also What do you mean? Using =E2=80=99package-with-explicit-python=E2=80=99 on = a package will replace the Python used by the =E2=80=99python-build-system=E2=80=99 f= or all the dependencies. Modulo the issues what C extension, if one wants the Python packages bytecompiled with PyPy, using a manifest containing: --8<---------------cut here---------------start------------->8--- (define package-with-pypy (package-with-explicit-python (delay pypy3 "python-" "pypy-"))) (packages->manifest (map (compose package-with-pypy specification->package)=20=20=20=20 (list "python-foo" "python-bar"))) --8<---------------cut here---------------end--------------->8--- would be the somehow thing I would do. Well, something in the spirit of =C2=ABDefining Package Vaiants=C2=BB. ;-) However=E2=80=A6 > --with-input=3Dpython=3Dpypy3, but I think it will rewrite too much (i.e. > not just packages using python-build-system, but *every* package in the > graph using Python in any way). =E2=80=A6similarly as replacing the Emacs VM [0], I guess some packages will be broken. Well, for instance if some packages use =E2=80=99python-minimal=E2=80=99 instead of =E2=80=99python=E2=80=99, the r= eplacement will not happen. Last, is it an issue to rewrite too much? Cheers, simon 0: From unknown Sat Jun 21 10:35:20 2025 X-Loop: help-debbugs@gnu.org Subject: [bug#44656] [PATCH] Upgrade pypy3 Resent-From: Lars-Dominik Braun Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Fri, 20 Aug 2021 14:26:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 44656 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: zimoun Cc: 44656@debbugs.gnu.org, Maxim Cournoyer Received: via spool by 44656-submit@debbugs.gnu.org id=B44656.16294695425089 (code B ref 44656); Fri, 20 Aug 2021 14:26:02 +0000 Received: (at 44656) by debbugs.gnu.org; 20 Aug 2021 14:25:42 +0000 Received: from localhost ([127.0.0.1]:35233 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mH5So-0001K1-JO for submit@debbugs.gnu.org; Fri, 20 Aug 2021 10:25:42 -0400 Received: from mout-p-102.mailbox.org ([80.241.56.152]:51018) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mH5Sm-0001Jm-6n for 44656@debbugs.gnu.org; Fri, 20 Aug 2021 10:25:41 -0400 Received: from smtp1.mailbox.org (smtp1.mailbox.org [IPv6:2001:67c:2050:105:465:1:1:0]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-384) server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by mout-p-102.mailbox.org (Postfix) with ESMTPS id 4GrkSZ05nNzQk25; Fri, 20 Aug 2021 16:25:34 +0200 (CEST) X-Virus-Scanned: amavisd-new at heinlein-support.de DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=6xq.net; s=MBO0001; t=1629469532; 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: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=l2O9JlBjdWfjBxh6VhJQXgoHOOJYbcNjTshwpj5eRbU=; b=z5GqNJiCoTVX/Kb+kYj715tynfCgOghNKt9QK0MERunW/KITaOwneXixt7g9yrsdMgkZRF XtbSUXAgtR4M10f3nsIRApPeirv6qeiGLtE7IwzGvn+Eaq7mx8rNrw3XaD1YrUZhFvqxeT WHebMcdTaeJhcs9FlcfC+CvbsxOMlUipqTyFEgS/0BJg90kenLrA7ZspjIUWbON7OMouSs hAz6oOCFxoH4AEoAzTlviS3RXIl+1bwLIjLlOOlGvZFQrrHK2EGq8VMSNXM+WO/qXvRgqY hzlxZMTZIv9Mnoacjo9eIe2jBGF/xF/V9seXecaN91WsSE4LpU0eAuzG7UmoBQ== Received: from smtp1.mailbox.org ([80.241.60.240]) by spamfilter03.heinlein-hosting.de (spamfilter03.heinlein-hosting.de [80.241.56.117]) (amavisd-new, port 10030) with ESMTP id kb8Bu-4YtCYz; Fri, 20 Aug 2021 16:25:31 +0200 (CEST) Date: Fri, 20 Aug 2021 16:25:29 +0200 From: Lars-Dominik Braun Message-ID: References: <20201115123911.GA1956@noor.fritz.box> <87eeba8ay7.fsf@gmail.com> <87k0ky7iv5.fsf@gmail.com> <87h7g2jb4d.fsf@gmail.com> <86tujko0x3.fsf@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <86tujko0x3.fsf@gmail.com> X-Rspamd-Queue-Id: 31FB01898 X-Rspamd-UID: 307406 X-Spam-Score: -0.7 (/) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) Hi zimoun, > What do you mean? Using ’package-with-explicit-python’ on a package > will replace the Python used by the ’python-build-system’ for all the > dependencies. Modulo the issues what C extension, if one wants the > Python packages bytecompiled with PyPy, using a manifest containing: true, that’s what I meant and why I mentioned Python 2 (we used to do it for every single Python 2 package, so they are installable on their own). > …similarly as replacing the Emacs VM [0], I guess some packages > will be broken. Well, for instance if some packages use > ’python-minimal’ instead of ’python’, the replacement will not happen. > Last, is it an issue to rewrite too much? Yes, rewriting too much is a problem, because Python is used alot you end up rebuilding everything, starting from the bootstrap binaries. And then it’s not even sure you’ll be able to build all the way up to the package you actually want, because our Python and PyPy packages actually implement different versions of the Python language/standard library (3.8 vs 3.7). Cheers, Lars