diff options
author | dbn <dbn@FreeBSD.org> | 2015-09-01 03:38:23 +0800 |
---|---|---|
committer | dbn <dbn@FreeBSD.org> | 2015-09-01 03:38:23 +0800 |
commit | 5cef7aece3322f37a8806606f2cdd0e318e91c7e (patch) | |
tree | e38ad343bb0776e7eeb5b7e1a6d397c3b069282f /lang/pypy | |
parent | 15026c16ef00ed26ace1cf808daaf173d51b5827 (diff) | |
download | freebsd-ports-gnome-5cef7aece3322f37a8806606f2cdd0e318e91c7e.tar.gz freebsd-ports-gnome-5cef7aece3322f37a8806606f2cdd0e318e91c7e.tar.zst freebsd-ports-gnome-5cef7aece3322f37a8806606f2cdd0e318e91c7e.zip |
lang/pypy: update to 2.6.1
Changes:
- Add external cffi ports (a la python):
- databases/pypy-gdbm
- databases/pypy-sqlite3
- x11-toolkits/pypy-tkinter
- Add bsd.pypy.mk for consistency between pypy ports.
- Add bsd.pypy.cffi.mk for consistency with external cffi ports.
- Switch back to using $PREFIX/pypy-X.Y (the '-' separator is required to
differentiate between lang/pypy and lang/pypy3)
- Remove all patches (upstreamed, see announcement below)
ChangeLog:
- Bug Fixes
- Revive non-SSE2 support
- Fixes for detaching _io.Buffer*
- Clear up contention in the garbage collector between trace-me-later and
pinning
- Issues reported with our previous release were resolved after reports from
users on our issue tracker at https://bitbucket.org/pypy/pypy/issues or on
IRC at #pypy.
- New features:
- cffi was updated to version 1.3
- The python stdlib was updated to 2.7.10 from 2.7.9
- vmprof now supports multiple threads
- The translation process builds cffi import libraries for some stdlib
packages, which should prevent confusion when package.py is not used
- better support for gdb debugging
- FreeBSD should be able to translate PyPy "out of the box" with no patches
- Numpy:
- Better support for record dtypes, including the align keyword
- Implement casting and create output arrays accordingly (still missing some
corner cases)
- Support creation of unicode ndarrays
- Better support ndarray.flags
- Support axis argument in more functions
- Refactor array indexing to support ellipses
- Allow the docstrings of built-in numpy objects to be set at run-time
- Support the buffered nditer creation keyword
- Performance improvements:
- Delay recursive calls to make them non-recursive
- Skip loop unrolling if it compiles too much code
- Tweak the heapcache
- Add a list strategy for lists that store both floats and 32-bit integers.
The latter are encoded as nonstandard NaNs. Benchmarks show that the speed
of such lists is now very close to the speed of purely-int or purely-float
lists.
- Simplify implementation of ffi.gc() to avoid most weakrefs
- Massively improve the performance of map() with more than one sequence
argument
Differential Revision: https://reviews.freebsd.org/D3285
Diffstat (limited to 'lang/pypy')
-rw-r--r-- | lang/pypy/Makefile | 14 | ||||
-rw-r--r-- | lang/pypy/bsd.pypy.cffi.mk | 26 | ||||
-rw-r--r-- | lang/pypy/bsd.pypy.mk | 10 | ||||
-rw-r--r-- | lang/pypy/distinfo | 4 | ||||
-rw-r--r-- | lang/pypy/files/patch-pypy_tool_release_package.py | 11 | ||||
-rw-r--r-- | lang/pypy/files/patch-rpython_config_support.py | 28 | ||||
-rw-r--r-- | lang/pypy/files/patch-rpython_config_test_test__support.py | 44 | ||||
-rw-r--r-- | lang/pypy/files/patch-rpython_jit_backend_detect__cpu.py | 10 | ||||
-rw-r--r-- | lang/pypy/files/patch-rpython_rtyper_tool_rffi__platform.py | 13 | ||||
-rw-r--r-- | lang/pypy/pkg-message | 15 | ||||
-rw-r--r-- | lang/pypy/pkg-plist | 9 |
11 files changed, 62 insertions, 122 deletions
diff --git a/lang/pypy/Makefile b/lang/pypy/Makefile index 3b8f5fe62088..6aa63fa96607 100644 --- a/lang/pypy/Makefile +++ b/lang/pypy/Makefile @@ -2,8 +2,7 @@ # $FreeBSD$ PORTNAME= pypy -PORTVERSION= 2.6.0 -PORTREVISION= 3 +PORTVERSION= 2.6.1 CATEGORIES= lang python MASTER_SITES= https://bitbucket.org/pypy/pypy/get/ LOCAL/dbn/pypy DISTNAME= release-${DISTVERSION} @@ -12,9 +11,6 @@ DIST_SUBDIR= pypy MAINTAINER= dbn@FreeBSD.org COMMENT= Fast, compliant implementation of the Python language -LICENSE= MIT PSFL -LICENSE_COMB= multi - LIB_DEPENDS= libexpat.so:${PORTSDIR}/textproc/expat2 \ libffi.so:${PORTSDIR}/devel/libffi @@ -38,12 +34,10 @@ ALL_TARGET= pypy-c BUILD_WRKSRC= ${WRKDIR}/build/usession-release-${DISTVERSION}-0/testing_1 MAKE_ENV+= PYPY_LOCALBASE=${LOCALBASE} USE_LDCONFIG= ${PREFIX}/${PYPY_DIR}/bin -USES= compiler:c11 gettext-runtime tar:bzip2 -WRKSRC= ${WRKDIR}/pypy-pypy-295ee98b6928 -PYPY_VER= ${DISTVERSION:C|([0-9])\.([0-9]).*|\1\2|} -PYPY_DIR= pypy${PYPY_VER} -PLIST_SUB+= PYPY_VER=${PYPY_VER} PYPY_DIR=${PYPY_DIR} +USES= gettext-runtime tar:bzip2 +WRKSRC= ${WRKDIR}/pypy-pypy-f3ad1e1e1d62 +.include ".${CURDIR}/bsd.pypy.mk" .include <bsd.port.options.mk> .if ${PORT_OPTIONS:MPYPY} || defined(PYTHON_CMD) diff --git a/lang/pypy/bsd.pypy.cffi.mk b/lang/pypy/bsd.pypy.cffi.mk new file mode 100644 index 000000000000..1c699af8757f --- /dev/null +++ b/lang/pypy/bsd.pypy.cffi.mk @@ -0,0 +1,26 @@ +# $FreeBSD$ + +PKGNAMEPREFIX= ${PYTHON_PKGNAMEPREFIX} +DISTFILES= + +BUILD_DEPENDS+= pypy:${PORTSDIR}/lang/pypy +RUN_DEPENDS+= pypy:${PORTSDIR}/lang/pypy + +PLIST_FILES= %%PYPY_DIR%%/lib_pypy/${CFFI_MODULE}_cffi.pypy-%%PYPY_VER%%.so + +CFFI_MODULE?= _${PORTNAME} + +PYTHON_PORTVERSION= 2.6.1 +PYTHON_PKGNAMEPREFIX= pypy- +PYTHON_CMD= ${LOCALBASE}/bin/pypy + +.include "${.CURDIR}/../../lang/pypy/bsd.pypy.mk" + +do-build: + ${CP} ${LOCALBASE}/${PYPY_DIR}/lib_pypy/${CFFI_MODULE}_build.py ${WRKDIR}/${PORTNAME}.py + (cd ${WRKDIR}; \ + ${PYTHON_CMD} -c "from ${PORTNAME} import ${CFFI_NAME} as ffi; ffi.compile('${WRKDIR}');") + +do-install: + ${MKDIR} ${STAGEDIR}${PREFIX}/${PYPY_DIR}/lib_pypy/`dirname ${CFFI_MODULE}`/ + ${INSTALL_LIB} ${WRKDIR}/${CFFI_MODULE}_cffi.pypy-${PYPY_VER}.so ${STAGEDIR}${PREFIX}/${PYPY_DIR}/lib_pypy/`dirname ${CFFI_MODULE}`/ diff --git a/lang/pypy/bsd.pypy.mk b/lang/pypy/bsd.pypy.mk new file mode 100644 index 000000000000..1ce86441ee36 --- /dev/null +++ b/lang/pypy/bsd.pypy.mk @@ -0,0 +1,10 @@ +# $FreeBSD$ + +LICENSE= MIT PSFL +LICENSE_COMB= multi + +USES+= compiler:c11 + +PYPY_DIR= pypy-${PORTVERSION:C|([0-9])\.([0-9]).*|\1.\2|} +PYPY_VER= ${PORTVERSION:C|([0-9])\.([0-9]).*|\1\2|} +PLIST_SUB+= PYPY_DIR=${PYPY_DIR} PYPY_VER=${PYPY_VER} diff --git a/lang/pypy/distinfo b/lang/pypy/distinfo index 2f77baac95fc..fffc8c6bb7b3 100644 --- a/lang/pypy/distinfo +++ b/lang/pypy/distinfo @@ -1,2 +1,2 @@ -SHA256 (pypy/release-2.6.0.tar.bz2) = 70c5feff73a6f9002b6a156488fe5e0b3981297da5766464bfd2327290bcd577 -SIZE (pypy/release-2.6.0.tar.bz2) = 16682327 +SHA256 (pypy/release-2.6.1.tar.bz2) = cc80e04957b899fe3c5d1b0b36979a4e80b7baf98f4c660c0fca781b6f148327 +SIZE (pypy/release-2.6.1.tar.bz2) = 16828274 diff --git a/lang/pypy/files/patch-pypy_tool_release_package.py b/lang/pypy/files/patch-pypy_tool_release_package.py deleted file mode 100644 index b29e0ac0ddcf..000000000000 --- a/lang/pypy/files/patch-pypy_tool_release_package.py +++ /dev/null @@ -1,11 +0,0 @@ ---- pypy/tool/release/package.py.orig 2015-05-31 07:19:51 UTC -+++ pypy/tool/release/package.py -@@ -135,7 +135,7 @@ def create_package(basedir, options, _fa - 'not find it' % (str(libpypy_c),)) - binaries.append((libpypy_c, libpypy_name)) - # -- builddir = options.builddir -+ builddir = py.path.local(options.builddir) - pypydir = builddir.ensure(name, dir=True) - includedir = basedir.join('include') - # Recursively copy all headers, shutil has only ignore diff --git a/lang/pypy/files/patch-rpython_config_support.py b/lang/pypy/files/patch-rpython_config_support.py deleted file mode 100644 index 97521b89d49e..000000000000 --- a/lang/pypy/files/patch-rpython_config_support.py +++ /dev/null @@ -1,28 +0,0 @@ ---- rpython/config/support.py.orig 2015-05-31 07:19:51 UTC -+++ rpython/config/support.py -@@ -8,7 +8,9 @@ def detect_number_of_processors(filename - if os.environ.get('MAKEFLAGS'): - return 1 # don't override MAKEFLAGS. This will call 'make' without any '-j' option - if sys.platform == 'darwin': -- return darwin_get_cpu_count() -+ return sysctl_get_cpu_count('/usr/sbin/sysctl') -+ elif sys.platform.startswith('freebsd'): -+ return sysctl_get_cpu_count('/sbin/sysctl') - elif not sys.platform.startswith('linux'): - return 1 # implement me - try: -@@ -26,11 +28,10 @@ def detect_number_of_processors(filename - except: - return 1 # we really don't want to explode here, at worst we have 1 - --def darwin_get_cpu_count(cmd = "/usr/sbin/sysctl hw.ncpu"): -+def sysctl_get_cpu_count(cmd, name='hw.ncpu'): - try: -- proc = subprocess.Popen(cmd, stdout=subprocess.PIPE, shell=True) -- # 'hw.ncpu: 20' -- count = proc.communicate()[0].rstrip()[8:] -+ proc = subprocess.Popen([cmd, '-n', name], stdout=subprocess.PIPE) -+ count = proc.communicate()[0] - return int(count) - except (OSError, ValueError): - return 1 diff --git a/lang/pypy/files/patch-rpython_config_test_test__support.py b/lang/pypy/files/patch-rpython_config_test_test__support.py deleted file mode 100644 index 1b53f5351a74..000000000000 --- a/lang/pypy/files/patch-rpython_config_test_test__support.py +++ /dev/null @@ -1,44 +0,0 @@ ---- rpython/config/test/test_support.py.orig 2015-05-31 07:19:51 UTC -+++ rpython/config/test/test_support.py -@@ -52,25 +52,30 @@ def test_cpuinfo_linux(): - finally: - os.environ = saved - --def test_cpuinfo_darwin(): -- if sys.platform != 'darwin': -- py.test.skip('mac only') -- saved_func = support.darwin_get_cpu_count -+def test_cpuinfo_sysctl(): -+ if sys.platform != 'darwin' and not sys.platform.startswith('freebsd'): -+ py.test.skip('mac and bsd only') -+ saved_func = support.sysctl_get_cpu_count - saved = os.environ -- def count(): -+ def count(cmd): -+ if sys.platform == 'darwin': -+ assert cmd == '/usr/sbin/sysctl' -+ else: -+ assert cmd == '/sbin/sysctl' - return 42 - try: -- support.darwin_get_cpu_count = count -+ support.sysctl_get_cpu_count = count - os.environ = FakeEnviron(None) - assert support.detect_number_of_processors() == 42 - os.environ = FakeEnviron('-j2') - assert support.detect_number_of_processors() == 1 - finally: - os.environ = saved -- support.darwin_get_cpu_count = saved_func -+ support.sysctl_get_cpu_count = saved_func - --def test_darwin_get_cpu_count(): -- if sys.platform != 'darwin': -+def test_sysctl_get_cpu_count(): -+ if sys.platform != 'darwin' and not sys.platform.startswith('freebsd'): - py.test.skip('mac only') -- assert support.darwin_get_cpu_count() > 0 # hopefully -- assert support.darwin_get_cpu_count("false") == 1 -+ cmd = '/usr/sbin/sysctl' if sys.platform != 'darwin' else '/sbin/sysctl' -+ assert support.sysctl_get_cpu_count(cmd) > 0 # hopefully -+ assert support.sysctl_get_cpu_count(cmd, "false") == 1 diff --git a/lang/pypy/files/patch-rpython_jit_backend_detect__cpu.py b/lang/pypy/files/patch-rpython_jit_backend_detect__cpu.py deleted file mode 100644 index 0ad94b4ab636..000000000000 --- a/lang/pypy/files/patch-rpython_jit_backend_detect__cpu.py +++ /dev/null @@ -1,10 +0,0 @@ ---- rpython/jit/backend/detect_cpu.py.orig 2015-08-11 18:20:39 UTC -+++ rpython/jit/backend/detect_cpu.py -@@ -63,6 +63,7 @@ def detect_model_from_host_platform(): - 'AMD64': MODEL_X86, # win64 - 'armv7l': MODEL_ARM, - 'armv6l': MODEL_ARM, -+ 'arm': MODEL_ARM, # freebsd - }.get(mach) - - if result is None: diff --git a/lang/pypy/files/patch-rpython_rtyper_tool_rffi__platform.py b/lang/pypy/files/patch-rpython_rtyper_tool_rffi__platform.py deleted file mode 100644 index 1243ff31dd4c..000000000000 --- a/lang/pypy/files/patch-rpython_rtyper_tool_rffi__platform.py +++ /dev/null @@ -1,13 +0,0 @@ ---- rpython/rtyper/tool/rffi_platform.py.orig 2015-05-31 07:19:51 UTC -+++ rpython/rtyper/tool/rffi_platform.py -@@ -854,7 +854,9 @@ def configure_boehm(platform=None): - platform = None - else: - library_dir = '' -- libraries = ['gc', 'dl'] -+ libraries = ['gc'] -+ if platform.name != "freebsd": -+ libraries += ['dl'] - includes=['gc/gc.h'] - eci = ExternalCompilationInfo( - platform=platform, diff --git a/lang/pypy/pkg-message b/lang/pypy/pkg-message new file mode 100644 index 000000000000..0422546858eb --- /dev/null +++ b/lang/pypy/pkg-message @@ -0,0 +1,15 @@ +===================================================================== + +Note that some standard Python modules are provided as separate ports +as they require additional dependencies. They are available as: + +gdbm databases/pypy-gdbm +sqlite3 databases/pypy-sqlite3 +tkinter x11-toolkits/pypy-tkinter + +Note that PyPy does not implement the following module that would +have been provided as a separate port: + +bsddb databases/pypy-bsddb + +===================================================================== diff --git a/lang/pypy/pkg-plist b/lang/pypy/pkg-plist index 70c7d23cf020..bf540bf0089a 100644 --- a/lang/pypy/pkg-plist +++ b/lang/pypy/pkg-plist @@ -542,8 +542,8 @@ bin/pypy %%PYPY_DIR%%/lib-python/2.7/encodings/zlib_codec.py %%PYPY_DIR%%/lib-python/2.7/ensurepip/__init__.py %%PYPY_DIR%%/lib-python/2.7/ensurepip/__main__.py -%%PYPY_DIR%%/lib-python/2.7/ensurepip/_bundled/pip-1.5.6-py2.py3-none-any.whl -%%PYPY_DIR%%/lib-python/2.7/ensurepip/_bundled/setuptools-7.0-py2.py3-none-any.whl +%%PYPY_DIR%%/lib-python/2.7/ensurepip/_bundled/pip-6.1.1-py2.py3-none-any.whl +%%PYPY_DIR%%/lib-python/2.7/ensurepip/_bundled/setuptools-15.2-py2.py3-none-any.whl %%PYPY_DIR%%/lib-python/2.7/ensurepip/_uninstall.py %%PYPY_DIR%%/lib-python/2.7/filecmp.py %%PYPY_DIR%%/lib-python/2.7/fileinput.py @@ -663,6 +663,7 @@ bin/pypy %%PYPY_DIR%%/lib-python/2.7/idlelib/idle_test/test_grep.py %%PYPY_DIR%%/lib-python/2.7/idlelib/idle_test/test_hyperparser.py %%PYPY_DIR%%/lib-python/2.7/idlelib/idle_test/test_idlehistory.py +%%PYPY_DIR%%/lib-python/2.7/idlelib/idle_test/test_io.py %%PYPY_DIR%%/lib-python/2.7/idlelib/idle_test/test_parenmatch.py %%PYPY_DIR%%/lib-python/2.7/idlelib/idle_test/test_pathbrowser.py %%PYPY_DIR%%/lib-python/2.7/idlelib/idle_test/test_rstrip.py @@ -678,7 +679,6 @@ bin/pypy %%PYPY_DIR%%/lib-python/2.7/idlelib/rpc.py %%PYPY_DIR%%/lib-python/2.7/idlelib/run.py %%PYPY_DIR%%/lib-python/2.7/idlelib/tabbedpages.py -%%PYPY_DIR%%/lib-python/2.7/idlelib/testcode.py %%PYPY_DIR%%/lib-python/2.7/idlelib/textView.py %%PYPY_DIR%%/lib-python/2.7/ihooks.py %%PYPY_DIR%%/lib-python/2.7/imaplib.py @@ -1451,7 +1451,7 @@ bin/pypy %%PYPY_DIR%%/lib-python/2.7/test/decimaltestdata/tointegral.decTest %%PYPY_DIR%%/lib-python/2.7/test/decimaltestdata/tointegralx.decTest %%PYPY_DIR%%/lib-python/2.7/test/decimaltestdata/xor.decTest -%%PYPY_DIR%%/lib-python/2.7/test/dh512.pem +%%PYPY_DIR%%/lib-python/2.7/test/dh1024.pem %%PYPY_DIR%%/lib-python/2.7/test/doctest_aliases.py %%PYPY_DIR%%/lib-python/2.7/test/double_const.py %%PYPY_DIR%%/lib-python/2.7/test/empty.vbs @@ -1881,6 +1881,7 @@ bin/pypy %%PYPY_DIR%%/lib-python/2.7/test/test_threading_local.py %%PYPY_DIR%%/lib-python/2.7/test/test_threadsignals.py %%PYPY_DIR%%/lib-python/2.7/test/test_time.py +%%PYPY_DIR%%/lib-python/2.7/test/test_timeit.py %%PYPY_DIR%%/lib-python/2.7/test/test_timeout.py %%PYPY_DIR%%/lib-python/2.7/test/test_tk.py %%PYPY_DIR%%/lib-python/2.7/test/test_tokenize.py |