From 1b41795b2f455df4a5773c050253c26279595ba7 Mon Sep 17 00:00:00 2001 From: Miro Hrončok Date: Apr 15 2018 13:26:16 +0000 Subject: [PATCH 1/3] Fix shebangs (reported mangled by taskotron) --- diff --git a/pypy3.spec b/pypy3.spec index bf093ac..0aa26f8 100644 --- a/pypy3.spec +++ b/pypy3.spec @@ -2,7 +2,7 @@ Name: pypy3 Version: %{basever}.1 %global pyversion 3.5 -Release: 7%{?dist} +Release: 8%{?dist} Summary: Python 3 implementation with a Just-In-Time compiler # LGPL and another free license we'd need to ask spot about are present in some @@ -185,14 +185,14 @@ Patch11: 011-no-faulthandler.patch # pypy3 can only be build with pypy2 BuildRequires: pypy2 # no pypy-pycparser available ATM -%global bootstrap_python_interp pypy +%global bootstrap_python_interp pypy2 %else # pypy3 can only be build with python2 BuildRequires: python2-devel BuildRequires: python2-pycparser -%global bootstrap_python_interp python +%global bootstrap_python_interp python2 %endif @@ -289,10 +289,10 @@ Build of PyPy3 with support for micro-threads for massive concurrency %prep %autosetup -n pypy3-v%{version}-src -p1 -S git -# Replace /usr/local/bin/python shebangs with /usr/bin/python: +# Replace /usr/local/bin/python or /usr/bin/env python shebangs with /usr/bin/python2 or pypy2: find -name "*.py" -exec \ sed \ - -i -e "s|/usr/local/bin/python|/usr/bin/python|" \ + -i -r -e "s@/usr/(local/)?bin/(env )?python(2|3)?@/usr/bin/%{bootstrap_python_interp}@" \ "{}" \ \; @@ -303,9 +303,9 @@ for f in rpython/translator/goal/bpnn.py ; do chmod a-x $f done -# Replace all lib-python python shebangs with pypy -find lib-python/%{pylibver} -name "*.py" -exec \ - sed -r -i '1s|^#!\s*/usr/bin.*python.*|#!/usr/bin/%{name}|' \ +# Replace all lib-python and lib_pypy python shebangs with pypy3 (those will be shipped with pypy3-libs) +find lib-python/%{pylibver} lib_pypy -name "*.py" -exec \ + sed -r -i '1s@^#!\s*/usr/bin.*(python|pypy).*@#!/usr/bin/%{name}@' \ "{}" \ \; @@ -823,6 +823,9 @@ CheckPyPy %{name}-stackless %changelog +* Sat Apr 14 2018 Miro Hrončok - 5.10.1-8 +- Fix failing taskotron check + * Wed Apr 11 2018 Miro Hrončok - 5.10.1-7 - Provide pypy3(abi) = 5.10 From b70eb98951063c00fb114a91f935d8991ca0e927 Mon Sep 17 00:00:00 2001 From: Miro Hrončok Date: Apr 25 2018 17:21:59 +0000 Subject: [PATCH 2/3] Remove Windows bat file --- diff --git a/pypy3.spec b/pypy3.spec index 0aa26f8..a14b96d 100644 --- a/pypy3.spec +++ b/pypy3.spec @@ -309,6 +309,9 @@ find lib-python/%{pylibver} lib_pypy -name "*.py" -exec \ "{}" \ \; +# Not needed on Linux +rm lib-python/3/idlelib/idle.bat + %ifarch %{ix86} x86_64 %{arm} sed -i -r 's/\$\(LDFLAGSEXTRA\)/& -fuse-ld=gold/' ./rpython/translator/platform/posix.py %endif From 18c888e5f5972bd6391a59f77794b317c359cec1 Mon Sep 17 00:00:00 2001 From: Miro Hrončok Date: Apr 25 2018 17:22:07 +0000 Subject: [PATCH 3/3] New release 6.0.0 (#1571489) Fix multiprocessing regression on newer glibcs (#1569933) --- diff --git a/.gitignore b/.gitignore index 67b6ee0..2025c8c 100644 --- a/.gitignore +++ b/.gitignore @@ -5,3 +5,4 @@ /pypy3-v5.9.0-src.tar.bz2 /pypy3-v5.10.0-src.tar.bz2 /pypy3-v5.10.1-src.tar.bz2 +/pypy3-v6.0.0-src.tar.bz2 diff --git a/302-fix-multiprocessing-regression-on-newer-glibcs.patch b/302-fix-multiprocessing-regression-on-newer-glibcs.patch new file mode 100644 index 0000000..db723a8 --- /dev/null +++ b/302-fix-multiprocessing-regression-on-newer-glibcs.patch @@ -0,0 +1,35 @@ +# HG changeset patch +# User Miro Hrončok +# Date 1524655710 -7200 +# Wed Apr 25 13:28:30 2018 +0200 +# Branch issue33329 +# Node ID 6501fdc3a80fa2bc3b8c70bfaf94a31c3b3432c0 +# Parent a07f07034d281bec8c776f9e1ee7c5b9aea74007 +Fix multiprocessing regression on newer glibcs + +Starting with glibc 2.27.9000-xxx, sigaddset() can return EINVAL for some +reserved signal numbers between 1 and NSIG. The `range(1, NSIG)` idiom +is commonly used to select all signals for blocking with `pthread_sigmask`. +So we ignore the sigaddset() return value until we expose sigfillset() +to provide a better idiom. + +Co-authored-by: Antoine Pitrou + +diff -r a07f07034d28 -r 6501fdc3a80f pypy/module/signal/interp_signal.py +--- a/pypy/module/signal/interp_signal.py Tue Apr 24 10:00:00 2018 +0200 ++++ b/pypy/module/signal/interp_signal.py Wed Apr 25 13:28:30 2018 +0200 +@@ -379,10 +379,10 @@ + for w_signum in space.unpackiterable(self.w_signals): + signum = space.int_w(w_signum) + check_signum_in_range(space, signum) +- err = c_sigaddset(self.mask, signum) +- if err: +- raise oefmt(space.w_ValueError, +- "signal number %d out of range", signum) ++ # bpo-33329: ignore c_sigaddset() return value as it can fail ++ # for some reserved signals, but we want the `range(1, NSIG)` ++ # idiom to allow selecting all valid signals. ++ c_sigaddset(self.mask, signum) + return self.mask + + def __exit__(self, *args): diff --git a/pypy3.spec b/pypy3.spec index a14b96d..b1add4a 100644 --- a/pypy3.spec +++ b/pypy3.spec @@ -1,8 +1,8 @@ -%global basever 5.10 +%global basever 6.0 Name: pypy3 -Version: %{basever}.1 +Version: %{basever}.0 %global pyversion 3.5 -Release: 8%{?dist} +Release: 1%{?dist} Summary: Python 3 implementation with a Just-In-Time compiler # LGPL and another free license we'd need to ask spot about are present in some @@ -164,6 +164,12 @@ Patch9: 009-add-libxcrypt-support.patch # It seems ppc64 has no faulthandler Patch11: 011-no-faulthandler.patch +# Fix multiprocessing regression on newer glibcs +# See: https://bugzilla.redhat.com/show_bug.cgi?id=1569933 +# and: https://bugs.python.org/issue33329 +# and: https://bitbucket.org/pypy/pypy/pull-requests/607 +Patch302: 302-fix-multiprocessing-regression-on-newer-glibcs.patch + # Build-time requirements: # pypy's can be rebuilt using itself, rather than with CPython; doing so @@ -826,8 +832,10 @@ CheckPyPy %{name}-stackless %changelog -* Sat Apr 14 2018 Miro Hrončok - 5.10.1-8 +* Wed Apr 25 2018 Miro Hrončok - 6.0.0-1 - Fix failing taskotron check +- New release 6.0.0 (#1571489) +- Fix multiprocessing regression on newer glibcs (#1569933) * Wed Apr 11 2018 Miro Hrončok - 5.10.1-7 - Provide pypy3(abi) = 5.10 diff --git a/sources b/sources index afb3c83..2a76651 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (pypy3-v5.10.1-src.tar.bz2) = 91b0ed25130bdbb46d5e577136b5fe63d5162917dcc2d0b69f5cac2a283ece9d0bfd3c7c8dc61ff391e0550fa1603326f6edeb2df3159d71617fefe6c07439f5 +SHA512 (pypy3-v6.0.0-src.tar.bz2) = ea406c4dd1837a6ab13026de01330790f3c18f6e2bfb83e8553e52acf78b43dfb559ce75c2d91395055c771db359356c8183ed950da6f01a21bf09128935af5e