Git Product home page Git Product logo

portable-pypy's People

Contributors

johnthagen avatar josephfrazier avatar mathieu-aubin avatar ninpo avatar qudongfang avatar rogererens avatar samureus avatar semenmartynov avatar squeaky-pl avatar xecycle avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

portable-pypy's Issues

`os.statvfs`

I'm tried use pypy-portable with CoreOS and Ansible. But I get following:

  File "/home/core/.ansible/tmp/ansible-tmp-1423477177.38-68083321344021/setup", line 2292, in populate
    self.get_mount_facts()
  File "/home/core/.ansible/tmp/ansible-tmp-1423477177.38-68083321344021/setup", line 1772, in wrapper
    result = func(*args, **kwargs)
  File "/home/core/.ansible/tmp/ansible-tmp-1423477177.38-68083321344021/setup", line 2432, in get_mount_facts
    statvfs_result = os.statvfs(fields[1])
AttributeError: 'module' object has no attribute 'statvfs'

But when I use official PyPy (LD_LIBRARY_PATH pain) - all OK.

error loading shared library on Ubuntu 16.04 Xenial

Unpacking pypy-5.1.1-linux_i686-portable and running pypy results in pypy: error while loading shared libraries: libbz2.so.1: cannot open shared object file: No such file or directory on Ubuntu 16.04 Xenial.

missing -dev? (Python.h)

I d/l pypy3.5-5.7-beta-linux_x86_64-portable.tar.bz2, but it doesn't seem to include Python.h

ssh to Resource Manager on Hadoop 2

Hadoop 2 (YARN) doesn't have a "Job Tracker"; it has a "Resource Manager". This performs much the same function, but it's on a different default port, and formats the page differently.

We need to:

  • detect which version of Hadoop we're using
  • connect to the correct port
  • correctly parse out Map/Reduce %

Missing fonts in tkinter...

I notice that i have much less fonts available with PyPy portable (PyPy 2.3.1 with GCC 4.8.2) than with origin PyPy...

Have made a simple test script:

try:
    # Python 3
    import tkinter
except ImportError:
    # Python 2
    import Tkinter as tkinter

root = tkinter.Tk()
font_families = root.tk.call("font", "families")
print("There are %i font families:" % len(font_families))
for font_family in font_families:
    print("\t%s" % font_family)

Output with PyPy portable:

There are 21 font families:
    fangsong ti
    fixed
    clearlyu alternate glyphs
    courier 10 pitch
    open look glyph
    bitstream charter
    song ti
    open look cursor
    newspaper
    clearlyu ligature
    mincho
    clearlyu devangari extra
    clearlyu pua
    clearlyu
    clean
    nil
    clearlyu arabic
    clearlyu devanagari
    standard symbols l
    gothic
    clearlyu arabic extra

But the origin PyPy (PyPy 2.3.1 with GCC 4.6.3) listed the same fonts as CPython (95 font families) tested on Linux Mint 17

See also: https://bitbucket.org/pypy/pypy/issue/1866/tkinter-missing-fonts

Missing libbz2

Great work! I ran into this on a pretty bare bones system, though:

# bin/pypy
bin/pypy: error while loading shared libraries: libbz2.so.1: cannot open shared object file: No such file or directory

I copied the library over from an Ubuntu system and it worked.

can not install pillow

This is error log,can anyone tell me why?
In same machine,i can success install pillow use python 2.6 or 2.7

./bin/pypy -m pip install pillow                                                                                                                                                                                                            [197/4369]
Collecting pillow
  Using cached https://pypi.tuna.tsinghua.edu.cn/packages/8d/80/eca7a2d1a3c2dafb960f32f844d570de988e609f5fd17de92e1cf6a01b0a/Pillow-4.0.0.tar.gz
Requirement already satisfied (use --upgrade to upgrade): olefile in ./site-packages (from pillow)
Installing collected packages: pillow
  Running setup.py install for pillow ... error
    Complete output from command /opt/pypy-5.6-linux_x86_64-portable/bin/pypy -u -c "import setuptools, tokenize;__file__='/tmp/pip-build-aL_PPQ/pillow/setup.py';exec(compile(getattr(tokenize, 'open', open)(__file__).read().replace('\r\n', '\n'), __file__, 'exec'))" instal$
 --record /tmp/pip-p477bP-record/install-record.txt --single-version-externally-managed --compile:
    running install
    running build
    running build_py
    creating build
    creating build/lib.linux-x86_64-2.7
    creating build/lib.linux-x86_64-2.7/PIL
    copying PIL/GbrImagePlugin.py -> build/lib.linux-x86_64-2.7/PIL
    copying PIL/IcnsImagePlugin.py -> build/lib.linux-x86_64-2.7/PIL
    copying PIL/PaletteFile.py -> build/lib.linux-x86_64-2.7/PIL
    copying PIL/SgiImagePlugin.py -> build/lib.linux-x86_64-2.7/PIL
    copying PIL/ImageFilter.py -> build/lib.linux-x86_64-2.7/PIL
    copying PIL/PcfFontFile.py -> build/lib.linux-x86_64-2.7/PIL
    copying PIL/JpegPresets.py -> build/lib.linux-x86_64-2.7/PIL
    copying PIL/GimpGradientFile.py -> build/lib.linux-x86_64-2.7/PIL
    copying PIL/PalmImagePlugin.py -> build/lib.linux-x86_64-2.7/PIL
    copying PIL/_util.py -> build/lib.linux-x86_64-2.7/PIL
    copying PIL/WmfImagePlugin.py -> build/lib.linux-x86_64-2.7/PIL
    copying PIL/WalImageFile.py -> build/lib.linux-x86_64-2.7/PIL
    copying PIL/GifImagePlugin.py -> build/lib.linux-x86_64-2.7/PIL
    copying PIL/DcxImagePlugin.py -> build/lib.linux-x86_64-2.7/PIL
    copying PIL/IptcImagePlugin.py -> build/lib.linux-x86_64-2.7/PIL
    copying PIL/PsdImagePlugin.py -> build/lib.linux-x86_64-2.7/PIL
    copying PIL/ImageStat.py -> build/lib.linux-x86_64-2.7/PIL
    copying PIL/MpoImagePlugin.py -> build/lib.linux-x86_64-2.7/PIL
    copying PIL/BmpImagePlugin.py -> build/lib.linux-x86_64-2.7/PIL
    copying PIL/ImageDraw2.py -> build/lib.linux-x86_64-2.7/PIL
    copying PIL/MspImagePlugin.py -> build/lib.linux-x86_64-2.7/PIL
    copying PIL/ContainerIO.py -> build/lib.linux-x86_64-2.7/PIL
    copying PIL/PcdImagePlugin.py -> build/lib.linux-x86_64-2.7/PIL
    copying PIL/OleFileIO.py -> build/lib.linux-x86_64-2.7/PIL
    copying PIL/SpiderImagePlugin.py -> build/lib.linux-x86_64-2.7/PIL
    copying PIL/ImImagePlugin.py -> build/lib.linux-x86_64-2.7/PIL
    copying PIL/ImageGrab.py -> build/lib.linux-x86_64-2.7/PIL
    copying PIL/GribStubImagePlugin.py -> build/lib.linux-x86_64-2.7/PIL
    copying PIL/EpsImagePlugin.py -> build/lib.linux-x86_64-2.7/PIL
    copying PIL/FpxImagePlugin.py -> build/lib.linux-x86_64-2.7/PIL
    copying PIL/ImageMorph.py -> build/lib.linux-x86_64-2.7/PIL
    copying PIL/DdsImagePlugin.py -> build/lib.linux-x86_64-2.7/PIL
    copying PIL/ImageEnhance.py -> build/lib.linux-x86_64-2.7/PIL
    copying PIL/JpegImagePlugin.py -> build/lib.linux-x86_64-2.7/PIL
    copying PIL/features.py -> build/lib.linux-x86_64-2.7/PIL
    copying PIL/ImageWin.py -> build/lib.linux-x86_64-2.7/PIL
    copying PIL/BdfFontFile.py -> build/lib.linux-x86_64-2.7/PIL
    copying PIL/BufrStubImagePlugin.py -> build/lib.linux-x86_64-2.7/PIL
    copying PIL/TiffTags.py -> build/lib.linux-x86_64-2.7/PIL
    copying PIL/MicImagePlugin.py -> build/lib.linux-x86_64-2.7/PIL
    copying PIL/TgaImagePlugin.py -> build/lib.linux-x86_64-2.7/PIL
    copying PIL/ImageFont.py -> build/lib.linux-x86_64-2.7/PIL
    copying PIL/ImageTransform.py -> build/lib.linux-x86_64-2.7/PIL
    copying PIL/ImageShow.py -> build/lib.linux-x86_64-2.7/PIL
    copying PIL/SunImagePlugin.py -> build/lib.linux-x86_64-2.7/PIL
    copying PIL/ExifTags.py -> build/lib.linux-x86_64-2.7/PIL
    copying PIL/ImageCms.py -> build/lib.linux-x86_64-2.7/PIL
    copying PIL/XpmImagePlugin.py -> build/lib.linux-x86_64-2.7/PIL
    copying PIL/ImageFile.py -> build/lib.linux-x86_64-2.7/PIL
    copying PIL/ImagePalette.py -> build/lib.linux-x86_64-2.7/PIL
    copying PIL/ImageSequence.py -> build/lib.linux-x86_64-2.7/PIL
    copying PIL/GimpPaletteFile.py -> build/lib.linux-x86_64-2.7/PIL
    copying PIL/PcxImagePlugin.py -> build/lib.linux-x86_64-2.7/PIL
    copying PIL/ImageOps.py -> build/lib.linux-x86_64-2.7/PIL
    copying PIL/ImageMath.py -> build/lib.linux-x86_64-2.7/PIL
    copying PIL/ImageChops.py -> build/lib.linux-x86_64-2.7/PIL
    copying PIL/FtexImagePlugin.py -> build/lib.linux-x86_64-2.7/PIL
    copying PIL/TiffImagePlugin.py -> build/lib.linux-x86_64-2.7/PIL
    copying PIL/PyAccess.py -> build/lib.linux-x86_64-2.7/PIL
    copying PIL/PpmImagePlugin.py -> build/lib.linux-x86_64-2.7/PIL
    copying PIL/PdfImagePlugin.py -> build/lib.linux-x86_64-2.7/PIL
    copying PIL/WebPImagePlugin.py -> build/lib.linux-x86_64-2.7/PIL
    copying PIL/ImageTk.py -> build/lib.linux-x86_64-2.7/PIL
    copying PIL/TarIO.py -> build/lib.linux-x86_64-2.7/PIL
    copying PIL/ImagePath.py -> build/lib.linux-x86_64-2.7/PIL
    copying PIL/PixarImagePlugin.py -> build/lib.linux-x86_64-2.7/PIL
    copying PIL/Image.py -> build/lib.linux-x86_64-2.7/PIL
    copying PIL/Jpeg2KImagePlugin.py -> build/lib.linux-x86_64-2.7/PIL
    copying PIL/FontFile.py -> build/lib.linux-x86_64-2.7/PIL
    copying PIL/ImageColor.py -> build/lib.linux-x86_64-2.7/PIL
    copying PIL/ImageDraw.py -> build/lib.linux-x86_64-2.7/PIL
    copying PIL/FitsStubImagePlugin.py -> build/lib.linux-x86_64-2.7/PIL
    copying PIL/IcoImagePlugin.py -> build/lib.linux-x86_64-2.7/PIL
    copying PIL/CurImagePlugin.py -> build/lib.linux-x86_64-2.7/PIL
    copying PIL/ImageQt.py -> build/lib.linux-x86_64-2.7/PIL
    copying PIL/MpegImagePlugin.py -> build/lib.linux-x86_64-2.7/PIL
    copying PIL/_binary.py -> build/lib.linux-x86_64-2.7/PIL
    copying PIL/XbmImagePlugin.py -> build/lib.linux-x86_64-2.7/PIL
    copying PIL/PngImagePlugin.py -> build/lib.linux-x86_64-2.7/PIL
    copying PIL/_tkinter_finder.py -> build/lib.linux-x86_64-2.7/PIL
    copying PIL/Hdf5StubImagePlugin.py -> build/lib.linux-x86_64-2.7/PIL
    copying PIL/McIdasImagePlugin.py -> build/lib.linux-x86_64-2.7/PIL
    copying PIL/ImtImagePlugin.py -> build/lib.linux-x86_64-2.7/PIL
    copying PIL/XVThumbImagePlugin.py -> build/lib.linux-x86_64-2.7/PIL
    copying PIL/PSDraw.py -> build/lib.linux-x86_64-2.7/PIL
    copying PIL/ImageMode.py -> build/lib.linux-x86_64-2.7/PIL
    copying PIL/FliImagePlugin.py -> build/lib.linux-x86_64-2.7/PIL
    copying PIL/GdImageFile.py -> build/lib.linux-x86_64-2.7/PIL
    copying PIL/__init__.py -> build/lib.linux-x86_64-2.7/PIL
    running egg_info
    writing Pillow.egg-info/PKG-INFO
    writing dependency_links to Pillow.egg-info/dependency_links.txt
    writing requirements to Pillow.egg-info/requires.txt
    writing top-level names to Pillow.egg-info/top_level.txt
    warning: manifest_maker: standard file '-c' not found

    reading manifest file 'Pillow.egg-info/SOURCES.txt'
    reading manifest template 'MANIFEST.in'
    warning: no files found matching '*.sh'
    no previously-included directories found matching 'docs/_static'
    warning: no previously-included files found matching '.coveragerc'
    warning: no previously-included files found matching '.editorconfig'
    warning: no previously-included files found matching '.landscape.yaml'
    warning: no previously-included files found matching 'appveyor.yml'
    warning: no previously-included files found matching 'build_children.sh'
    warning: no previously-included files found matching 'tox.ini'
    warning: no previously-included files matching '.git*' found anywhere in distribution
    warning: no previously-included files matching '*.pyc' found anywhere in distribution
    warning: no previously-included files matching '*.so' found anywhere in distribution
    writing manifest file 'Pillow.egg-info/SOURCES.txt'
    running build_ext


    The headers or library files could not be found for zlib,
    a required dependency when compiling Pillow from source.

    Please see the install instructions at:
       http://pillow.readthedocs.io/en/latest/installation.html

    Traceback (most recent call last):
      File "<module>", line 1, in <module>
      File "/tmp/pip-build-aL_PPQ/pillow/setup.py", line 791, in <module>
        raise RequiredDependencyException(msg)
    RequiredDependencyException:

    The headers or library files could not be found for zlib,
    a required dependency when compiling Pillow from source.

    Please see the install instructions at:
       http://pillow.readthedocs.io/en/latest/installation.html



    ----------------------------------------
Command "/opt/pypy-5.6-linux_x86_64-portable/bin/pypy -u -c "import setuptools, tokenize;__file__='/tmp/pip-build-aL_PPQ/pillow/setup.py';exec(compile(getattr(tokenize, 'open', open)(__file__).read().replace('\r\n', '\n'), __file__, 'exec'))" install --record /tmp/pip-p477b
P-record/install-record.txt --single-version-externally-managed --compile" failed with error code 1 in /tmp/pip-build-aL_PPQ/pillow/

Binaries not compatible with "manylinux1"

I am trying to build PyPy binary wheels of some packages. The official way of making "manylinux1" packages is to build them using a specific docker image based on CENTOS 5:
https://github.com/pypa/manylinux

I see that pypy portable binaries are based on CENTOS 6 instead: as a consequence, pypy doesn't work on such a docker image:

[root@79006327716b bin]# ./pypy 
./pypy: /lib64/libc.so.6: version `GLIBC_2.9' not found (required by /pypy-wheels/pypy-5.8-linux_x86_64-portable/bin/libpypy-c.so)
./pypy: /lib64/libc.so.6: version `GLIBC_2.7' not found (required by /pypy-wheels/pypy-5.8-linux_x86_64-portable/bin/../lib/libcrypto.so.1.1)
./pypy: /lib64/libc.so.6: version `GLIBC_2.7' not found (required by /pypy-wheels/pypy-5.8-linux_x86_64-portable/bin/../lib/libffi.so.6)

How hard would it be to base the build on centos 5 instead of 6?

Portable debug builds

Would it be possible to also do debug builds of the portable pypys?

My use case:

I'm using the portable pypys (via pyenv) as the basis for the pypy runner in my CI build.

Unfortunately my build triggers intermittent segfaults in pypy. These are very hard to debug with the normal release builds, so I'd like to run a parallel version of the build with a debug version of pypy, but there's currently no remotely convenient way to do that.

2.5+ missing third party library headers - cryptography compiling error

I first noticed this while continuing to investigate pyca/pyopenssl#135 (originally motivated by #2; see also this).

Here's how to reproduce:

# rm -fr /opt/site
# mkdir /opt/site
# .../pypy-2.5.1-linux_x86_64-portable/bin/virtualenv-pypy /opt/site
...
# /opt/site/bin/pip install pyOpenSSL
You are using pip version 6.0.8, however version 6.1.1 is available.
You should consider upgrading via the 'pip install --upgrade pip' command.
Collecting pyOpenSSL
  Downloading pyOpenSSL-0.14.tar.gz (128kB)
    100% |################################| 131kB 617kB/s
Collecting cryptography>=0.2.1 (from pyOpenSSL)
  Downloading cryptography-0.8.1.tar.gz (268kB)
    100% |################################| 270kB 579kB/s
Collecting six>=1.5.2 (from pyOpenSSL)
  Downloading six-1.9.0-py2.py3-none-any.whl
Collecting pyasn1 (from cryptography>=0.2.1->pyOpenSSL)
  Downloading pyasn1-0.1.7.tar.gz (68kB)
    100% |################################| 69kB 820kB/s
Requirement already satisfied (use --upgrade to upgrade): setuptools in /opt/site/site-packages (from cryptography>=0.2.1->pyOpenSSL)
Collecting enum34 (from cryptography>=0.2.1->pyOpenSSL)
  Downloading enum34-1.0.4.tar.gz
Installing collected packages: enum34, pyasn1, six, cryptography, pyOpenSSL
  Running setup.py install for enum34
  Running setup.py install for pyasn1

  Running setup.py install for cryptography
    building '_Cryptography_cffi_f3e4673fx399b1113' extension
    cc -O2 -fPIC -Wimplicit -I/opt/site/include -c src/cryptography/hazmat/bindings/__pycache__/_Cryptography_cffi_f3e4673fx399b1113.c -o build/temp.linux-x86_64-2.7/src/cryptography/hazmat/bindings/__pycache__/_Cryptography_cffi_f3e4673fx399b1113.o
    cc -shared build/temp.linux-x86_64-2.7/src/cryptography/hazmat/bindings/__pycache__/_Cryptography_cffi_f3e4673fx399b1113.o -lssl -lcrypto -o build/lib.linux-x86_64-2.7/cryptography/_Cryptography_cffi_f3e4673fx399b1113.pypy-25.so
    building '_Cryptography_cffi_590da19fxffc7b1ce' extension
    cc -O2 -fPIC -Wimplicit -I/opt/site/include -c src/cryptography/hazmat/bindings/__pycache__/_Cryptography_cffi_590da19fxffc7b1ce.c -o build/temp.linux-x86_64-2.7/src/cryptography/hazmat/bindings/__pycache__/_Cryptography_cffi_590da19fxffc7b1ce.o
    cc -shared build/temp.linux-x86_64-2.7/src/cryptography/hazmat/bindings/__pycache__/_Cryptography_cffi_590da19fxffc7b1ce.o -o build/lib.linux-x86_64-2.7/cryptography/_Cryptography_cffi_590da19fxffc7b1ce.pypy-25.so
    building '_Cryptography_cffi_26cb75b8x62b488b1' extension
    cc -O2 -fPIC -Wimplicit -I/opt/site/include -c src/cryptography/hazmat/bindings/__pycache__/_Cryptography_cffi_26cb75b8x62b488b1.c -o build/temp.linux-x86_64-2.7/src/cryptography/hazmat/bindings/__pycache__/_Cryptography_cffi_26cb75b8x62b488b1.o
    cc -shared build/temp.linux-x86_64-2.7/src/cryptography/hazmat/bindings/__pycache__/_Cryptography_cffi_26cb75b8x62b488b1.o -o build/lib.linux-x86_64-2.7/cryptography/_Cryptography_cffi_26cb75b8x62b488b1.pypy-25.so
  Running setup.py install for pyOpenSSL
Successfully installed cryptography-0.8.1 enum34-1.0.4 pyOpenSSL-0.14 pyasn1-0.1.7 six-1.9.0
# /opt/site/bin/pypy
Python 2.7.9 (af9d5af2e8e35e39a6dd7266becb8eb08926cab4, Mar 30 2015, 17:13:10)
[PyPy 2.5.1 with GCC 4.9.2] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>>> import OpenSSL.SSL
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/opt/site/site-packages/OpenSSL/__init__.py", line 8, in <module>
    from OpenSSL import rand, crypto, SSL
  File "/opt/site/site-packages/OpenSSL/rand.py", line 11, in <module>
    from OpenSSL._util import (
  File "/opt/site/site-packages/OpenSSL/_util.py", line 4, in <module>
    binding = Binding()
  File "/opt/site/site-packages/cryptography/hazmat/bindings/openssl/binding.py", line 113, in __init__
    self._ensure_ffi_initialized()
  File "/opt/site/site-packages/cryptography/hazmat/bindings/openssl/binding.py", line 123, in _ensure_ffi_initialized
    cls._modules,
  File "/opt/site/site-packages/cryptography/hazmat/bindings/utils.py", line 31, in load_library_for_binding
    lib = ffi.verifier.load_library()
  File ".../files/pypy-2.5.1-linux_x86_64-portable/lib_pypy/cffi/verifier.py", line 97, in load_library
    return self._load_library()
  File ".../files/pypy-2.5.1-linux_x86_64-portable/lib_pypy/cffi/verifier.py", line 207, in _load_library
    return self._vengine.load_library()
  File ".../files/pypy-2.5.1-linux_x86_64-portable/lib_pypy/cffi/vengine_gen.py", line 66, in load_library
    module = backend.load_library(filename, flags)
OSError: Cannot load library /opt/site/site-packages/cryptography/_Cryptography_cffi_f3e4673fx399b1113.pypy-25.so: /opt/site/site-packages/cryptography/_Cryptography_cffi_f3e4673fx399b1113.pypy-25.so: symbol EC_GFp_nistp521_method, version OPENSSL_1.0.1 not defined in file libcrypto.so.1.0.0 with link time reference

Note this does not happen with 2.3.1:

# rm -fr /opt/site
# mkdir /opt/site
# .../pypy-2.3.1-linux_x86_64-portable/bin/virtualenv-pypy /opt/site
...
# /opt/site/bin/pip install pyOpenSSL
...
# /opt/site/bin/pypy
Python 2.7.6 (32f35069a16d819b58c1b6efb17c44e3e53397b2, Jun 10 2014, 00:42:27)
[PyPy 2.3.1 with GCC 4.8.2] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>>> import OpenSSL.SSL
>>>> '{:x}'.format(OpenSSL.SSL.OPENSSL_VERSION_NUMBER)
'1000105f'
>>>> exit()

portable pypy 5.4.1 doesn't have socket.SO_REUSEPORT

stock pypy 5.4.1

Python 2.7.10 (5.4.1+dfsg-1~ppa1~ubuntu14.04, Sep 06 2016, 23:11:48)
[PyPy 5.4.1 with GCC 4.8.4] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>>> import socket
>>>> socket.SO_REUSEADDR
2
>>>> socket.SO_REUSEPORT
15

portable pypy 5.4.1

Python 2.7.10 (0e2d9a73f5a1818d0245d75daccdbe21b2d5c3ef, Sep 07 2016, 14:23:17)
[PyPy 5.4.1 with GCC 4.9.2] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>>> import socket
>>>> socket.SO_REUSEADDR
2
>>>> socket.SO_REUSEPORT
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
AttributeError: 'module' object has no attribute 'SO_REUSEPORT'
>>>> 

Cannot import _posixsubprocess

using pypy-5.6-linux_x86_64-portable in a virtualenv:

>>>> import _posixsubprocess
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
ImportError: unable to load extension module '/data/wombat/home/fhr/silkthread/env27-pypy/site-packages/_posixsubprocess.pypy-41.so': /data/wombat/home/fhr/silkthread/env27-pypy/site-packages/_posixsubprocess.pypy-41.so: undefined symbol: _PyImport_ReleaseLock

pep8 segmentation fault

Running pypy for Python 3.5 compatible I'm running into an issue with pep8:
It's to mention that PYTHON_VERSION for py27, py33, py34, py35, py36 and pypy is working fine;
of course pypy representing the Python 2.7 compatible version (see script).

# assume you have Docker installed
git clone https://github.com/Nachtfeuer/concept-py.git
cd concept-py
PYTHON_VERSION=pypy3 scripts/run_python.sh

You can verify the installation instructions in the switch ... case for pypy3.
The pep8 tool is basically running; when I do it manually with the defaults I see the line length warnings but the tool finally crashes with a segmentation fault. I tried different versions of pep8 without success.

Included OpenSSL/libffi barfs with Twisted 14.0 on RSA cert with CA bundle

I'm running Twisted 14 from a portable pypy virtualenv instance in /opt/site/... which was installed by running .../pypy-2.3.1-linux_x86_64-portable/bin/virtualenv-pypy --quiet /opt/site. Here's the stack trace:

          File "/opt/site/site-packages/twisted/internet/posixbase.py", line 614, in _doReadOrWrite
            why = selectable.doRead()
          File "/opt/site/site-packages/twisted/internet/tcp.py", line 214, in doRead
            return self._dataReceived(data)
          File "/opt/site/site-packages/twisted/internet/tcp.py", line 220, in _dataReceived
            rval = self.protocol.dataReceived(data)
          File "/opt/site/site-packages/twisted/protocols/tls.py", line 422, in dataReceived
            self._flushReceiveBIO()
          File "/opt/site/site-packages/twisted/protocols/tls.py", line 360, in _flushReceiveBIO
            bytes = self._tlsConnection.recv(2 ** 15)
          File "/opt/site/site-packages/OpenSSL/SSL.py", line 995, in recv
            self._raise_ssl_error(self._ssl, result)
          File "/opt/site/site-packages/OpenSSL/SSL.py", line 871, in _raise_ssl_error
            _raise_current_error()
          File "/opt/site/libexec/pypy-2.3.1-linux_x86_64-portable/lib_pypy/_functools.py", line 22, in __call__
            return self.func(*(self.args + fargs), **fkeywords)
          File "/opt/site/site-packages/OpenSSL/_util.py", line 19, in exception_from_error_queue
            text(lib.ERR_func_error_string(error)),
          File "/opt/site/site-packages/OpenSSL/_util.py", line 10, in text
            return native(ffi.string(charp))
          File "/opt/site/libexec/pypy-2.3.1-linux_x86_64-portable/lib_pypy/cffi/api.py", line 253, in string
            return self._backend.string(cdata, maxlen)
        exceptions.RuntimeError: cannot use string() on <cdata 'char *' NULL>

I can only reproduce this with portable pypy and a signed key (PEM), cert, and CA bundle. UPDATE: I can reproduce this with any RSA key pair. (See pyca/pyopenssl#135.) If I replace the RSA key pair with a self-signed ECDSA key, cert, and CA bundle, it works fine.

SSL Certificate Bundles Aren't Found?

I know very little about the mechanisms here, so apologies if I've got this very wrong, but since portable PyPy vendors OpenSSL, and compiles it looking at /opt/prefix, it appears that at runtime no certificates are actually found from the system bundle, because that directory obviously will not exist on machines that use Portable PyPy.

I.e.,

>>> import ssl; ssl.get_default_verify_paths()
DefaultVerifyPaths(cafile=None, capath=None, openssl_cafile_env='SSL_CERT_FILE', openssl_cafile='/opt/prefix/ssl/cert.pem', openssl_capath_env='SSL_CERT_DIR', openssl_capath='/opt/prefix/ssl/certs')

whereas the system certs are not there (this is CentOS 6, so they're in /etc/ssl/certs/ca-bundle.crt).

Setting SSL_CERT_FILE appears to be one way to fix the issue, but what's the actual recommendation for that?

Come up with a security related updates strategy

Since OpenSSL is bundled and I already found out that it is impossible to deliver a binary that links cleanly against all the supported OSes I should come up with a security updates strategy.

I could for example maintain the last version of PyPy against all known security related problems and rebuild each time that happens. I could include versions of bundled libraries inside interactive Python banner prompt.

The open question for me is how do I communicate that updates to downstream users and what is the best way to watch vulnerabilities in all bundled software.

How can I compile pypy3?

Hello!

I have some trouble with pre-compiled version of pypy3, so I want to evaluate that through portable-pypy.

My OS version is CentOS Linux release 7.2.1511 and kernel version 3.10.0-327.28.2.el7.x86_64. If I want to compile pypy3, How can I get it?

Example step in BUILD.rst is only handled pypy version. (cpython2)
Please some advice to me!

musl-based version

Add binaries compiled with musl instead of glibc, so they could be used in NodeOS and other systems.

Tkinter doesn't detect all the fonts installed in the system

With portable-pypy 5.4.1:

$ python
Python 2.7.10 (0e2d9a73f5a1818d0245d75daccdbe21b2d5c3ef, Sep 07 2016, 14:23:17)
[PyPy 5.4.1 with GCC 4.9.2] on linux2
Type "help", "copyright", "credits" or "license" for more information.
And now for something completely different: ``"let's not be obscure, unless we
really need to"''
>>>> import Tkinter, tkFont
>>>> app = Tkinter.Tk()
>>>> tkFont.families()
('newcenturyschlbk', 'free courier', 'nimbus roman no9 l', 'clearlyu devangari extra', 'teams', 'clearlyu arabic', 'dingbats', 'standard symbols l', 'clearlyu arabic extra', 'urw chancery l', 'fixed', 'urw palladio l', 'luxi_mono', 'courier 10 pitch', 'open look glyph', 'bitstream charter', 'avantgarde', 'free schoolbook', 'clearlyu pua', 'urw gothic l', 'oldslavic', 'century schoolbook l', 'urw bookman l', 'free helvetian', 'avant garde gothic', 'clean', 'free helvetian condensed', 'zapf chancery', 'gothic', 'new century schoolbook', 'bookman', 'computer modern concrete', 'free avant garde', 'clearlyu alternate glyphs', 'luxi_serif', 'song ti', 'computer modern', 'latin modern typewriter', 'zapf dingbats', 'helvetica', 'open look cursor', 'mincho', 'nimbus sans l', 'palatino', 'clearlyu', 'courier', 'latin modern sans', 'latin modern typewriter variable width', 'itc avant garde gothic', 'clearlyu devanagari', 'nil', 'free times', 'itc zapf chancery', 'latin modern sansquotation', 'itc bookman', 'free chancery', 'fangsong ti', 'times', 'latin modern roman', 'itc zapf dingbats', 'newspaper', 'clearlyu ligature', 'free bookman', 'free paladin', 'nimbus mono l', 'computer modern bright', 'zapfdingbats', 'symbol', 'luxi_sans')

With pypy 5.4.1 downloaded from pypy.org:

 $ ./pypy
Python 2.7.10 (c95650101a99, Sep 06 2016, 11:10:29)
[PyPy 5.4.1 with GCC 4.8.2] on linux2
Type "help", "copyright", "credits" or "license" for more information.
And now for something completely different: ``and now for something completely
different''
>>>> import Tkinter, tkFont
>>>> app = Tkinter.Tk()
>>>> tkFont.families()
('STIXIntegralsUp', 'False Positive BRK', 'World of Water', 'DB Layer 2 BRK', 'Electorate Blue', 'Kirsty', 'BPG Nateli GPL&GNU', 'Noto Sans Gurmukhi', ..... # all the fonts installed
>>>> 

I think it's because the CentOS 5 image is missing libXft-devel. I'm testing a change to the Dockerfile, but it's still building.

Unable to build pypy 3.5 and 3.6

Attempting to build pypy from either of the py3.5 or py3.6 branches using the provided docker container fails with the following error.

[platform:Error] /src/usession-py3.5-0/platcheck_89.c: In function 'dump_section_EPOLL_CLOEXEC':
[platform:Error] /src/usession-py3.5-0/platcheck_89.c:270:7: error: 'EPOLL_CLOEXEC' undeclared (first use in this function)
[platform:Error]   if ((EPOLL_CLOEXEC) <= 0) {
[platform:Error]        ^~~~~~~~~~~~~
[platform:Error] /src/usession-py3.5-0/platcheck_89.c:270:7: note: each undeclared identifier is reported only once for each function it appears in
[translation:info] Error:
   File "/src/pypy/rpython/translator/goal/translate.py", line 284, in main
    default_goal='compile')
   File "/src/pypy/rpython/translator/driver.py", line 566, in from_targetspec
    spec = target(driver, args)
   File "pypy/goal/targetpypystandalone.py", line 330, in target
    return self.get_entry_point(config)
   File "pypy/goal/targetpypystandalone.py", line 361, in get_entry_point
    space = make_objspace(config)
   File "/src/pypy/pypy/tool/option.py", line 35, in make_objspace
    return Space(config)
   File "/src/pypy/pypy/interpreter/baseobjspace.py", line 432, in __init__
    self.initialize()
   File "/src/pypy/pypy/objspace/std/objspace.py", line 105, in initialize
    self.make_builtins()
   File "/src/pypy/pypy/interpreter/baseobjspace.py", line 617, in make_builtins
    self.install_mixedmodule(mixedname, installed_builtin_modules)
   File "/src/pypy/pypy/interpreter/baseobjspace.py", line 656, in install_mixedmodule
    modname = self.setbuiltinmodule(mixedname)
   File "/src/pypy/pypy/interpreter/baseobjspace.py", line 495, in setbuiltinmodule
    None, None, ["Module"]).Module
   File "/src/pypy/pypy/module/select/__init__.py", line 8, in <module>
    class Module(MixedModule):
   File "/src/pypy/pypy/module/select/__init__.py", line 22, in Module
    from pypy.module.select.interp_epoll import public_symbols
   File "/src/pypy/pypy/module/select/interp_epoll.py", line 47, in <module>
    cconfig = rffi_platform.configure(CConfig)
   File "/src/pypy/rpython/rtyper/tool/rffi_platform.py", line 230, in configure
    ignore_errors=ignore_errors))
   File "/src/pypy/rpython/rtyper/tool/rffi_platform.py", line 746, in run_example_code
    output = build_executable_cache(files, eci, ignore_errors=ignore_errors)
   File "/src/pypy/rpython/tool/gcc_cache.py", line 28, in build_executable_cache
    result = platform.execute(platform.compile(c_files, eci))
   File "/src/pypy/rpython/translator/platform/__init__.py", line 54, in compile
    ofiles = self._compile_o_files(cfiles, eci, standalone)
   File "/src/pypy/rpython/translator/platform/__init__.py", line 76, in _compile_o_files
    ofiles.append(self._compile_c_file(self.cc, cfile, compile_args))
   File "/src/pypy/rpython/translator/platform/posix.py", line 41, in _compile_c_file
    cwd=str(cfile.dirpath()))
   File "/src/pypy/rpython/translator/platform/__init__.py", line 140, in _execute_c_compiler
    self._handle_error(returncode, stdout, stderr, outname)
   File "/src/pypy/rpython/translator/platform/__init__.py", line 152, in _handle_error
    raise CompilationError(stdout, stderr)
[translation:ERROR] CompilationError: CompilationError(err="""
	/src/usession-py3.5-0/platcheck_89.c: In function 'dump_section_EPOLL_CLOEXEC':
	/src/usession-py3.5-0/platcheck_89.c:270:7: error: 'EPOLL_CLOEXEC' undeclared (first use in this function)
	  if ((EPOLL_CLOEXEC) <= 0) {
	       ^~~~~~~~~~~~~
	/src/usession-py3.5-0/platcheck_89.c:270:7: note: each undeclared identifier is reported only once for each function it appears in
	""")
[translation] start debugger...
Traceback (most recent call last):
  File "rpython/bin/rpython", line 20, in <module>
> /src/pypy/rpython/translator/platform/__init__.py(152)_handle_error()
-> raise CompilationError(stdout, stderr)
    main()
  File "/src/pypy/rpython/translator/goal/translate.py", line 325, in main
    debug(True)
  File "/src/pypy/rpython/translator/goal/translate.py", line 278, in debug
    pdb_plus_show.start(tb)
  File "/src/pypy/rpython/translator/tool/pdbplus.py", line 442, in start
    fn(*args)
  File "/src/pypy/rpython/translator/tool/pdbplus.py", line 25, in post_mortem
    self.interaction(t.tb_frame, t)
  File "/opt/prefix/cpython-2.7/lib/python2.7/pdb.py", line 210, in interaction
    self.cmdloop()
  File "/opt/prefix/cpython-2.7/lib/python2.7/cmd.py", line 109, in cmdloop
    self.preloop()
  File "/src/pypy/rpython/translator/tool/pdbplus.py", line 29, in preloop
    raise NoTTY("Cannot start the debugger when stdout is captured.")
rpython.translator.tool.pdbplus.NoTTY: Cannot start the debugger when stdout is captured.

Posible Portable PyPy issues with Ubuntu Precise 12.04, libbz2 requires glibc >= GLIBC_2.3

Hi, it was reported at the pyenv issue tracker that PyPy3 5.7.1 no longer works in Ubuntu Precise (12.04):

pyenv/pyenv#925 (comment)

(pasting relevant comments below)

$ /opt/python/pypy3.5-5.7.1-beta/bin/python -c 'import bz2'
/opt/python/pypy3.5-5.7.1-beta/bin/python: /lib/x86_64-linux-gnu/libc.so.6: version `GLIBC_2.17' not found (required by /opt/python/pypy3.5-5.7.1-beta/bin/libpypy3-c.so)

The version of libc on Precise is 2.15:

$ dpkg -l | grep -w libc6
ii  libc6                               2.15-0ubuntu10.18                                   Embedded GNU C Library: Shared libraries
ii  libc6-dev                           2.15-0ubuntu10.18                                   Embedded GNU C Library: Development Libraries and Header Files

When I ran ldd -v on libpypy-c.so and libpypy3-c.so for the latest Portable PyPy release (5.8) it seems to have the same issue?:

	/lib/x86_64-linux-gnu/libbz2.so.1.0:
		libc.so.6 (GLIBC_2.3) => /lib/x86_64-linux-gnu/libc.so.6
		libc.so.6 (GLIBC_2.3.4) => /lib/x86_64-linux-gnu/libc.so.6
		libc.so.6 (GLIBC_2.4) => /lib/x86_64-linux-gnu/libc.so.6
		libc.so.6 (GLIBC_2.2.5) => /lib/x86_64-linux-gnu/libc.so.6

I know that Ubuntu Precise is considered end of life since April of this year

https://lists.ubuntu.com/archives/ubuntu-announce/2017-March/000218.html

and I imagine it would be more of a hassle to bundle yet another library into your build process. Just wanted to let you know.

Thank you for Portable-pypy

This just works ! works without needing to recompile across deployments of Gentoo , Sabayon , Debian , Ubuntu and Openshift! (RedHat) Without any rebuild requirment (different enviorment).
Official Pypy binary builds get symlink errors when i moved across different Distros!.

Error "Unexpected double format" on some machines

After

docker run --rm `ABI=64 ./runopt.sh` portable-pypy ./build_deps

I see

+ make -j4
echo @`sh  cflags "optimize='-O2'" opmini.o`  -DPERL_IS_MINIPERL -DPERL_EXTERNAL_GLOB opmini.c
@cc -c -DPERL_CORE -D__USE_XOPEN2K8 -I/opt/prefix/include -I/opt/prefix/include/ncurses -fwrapv -fno-strict-aliasing -pipe -fstack-protector-strong -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -O2 -Wall -DPERL_IS_MINIPERL -DPERL_EXTERNAL_GLOB opmini.c
In file included from op.c:103:0:
perl.h:6978:6: error: #error "Unexpected double format"
 #    error "Unexpected double format"
      ^~~~~
perl.h:7177:6: error: #error "Unexpected double format"
 #    error "Unexpected double format"
      ^~~~~
feature.h:151: confused by earlier errors, bailing out
make: *** [opmini.o] Error 1

bin/pypy: symbol lookup error: <path_to_portable_pypy>/libpypy-c.so: undefined symbol: SSL_CTX_set_alpn_protos

Hi,
thanks for your portable-pypy bundle!
I want to use the pypy-5.0.1-linux_x86_64-portable version on our RHEL6.4 server for our intranet webserver.

Except for the system's openssl version, my employer lets me choose to 'enable' either a 32 or 64 bit version of openssl 1.0.0d, of which I need the latter for other packages. So I have 'enable'd the 64 bit version.

Now, when I activate a virtualenv, created with the portable pypy's virtualenv command, and try to start the pypy in it, I get the abovementioned error and the pypy interpreter does not start up.

I don't get the error when I 'enable' the 32 bit version, or use the system's version. But that frustrates the use of other packages. :-(

Do you have an idea why this happens and what can be done about it? I had hoped that my virtualenv would use the openssl that is included in the portable pypy.

Thanks for any ideas or hints,

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.