Using virtualenv with PyPy ========================== Thanks to the work that was recently done on the `sys-prefix`_ branch, it is now possible to use virtualenv_ with PyPy. To try it, you need: - a recent version of PyPy: PyPy 1.3 does not contain the necessary logic to work with virtualenv, so you need a more recent PyPy from subversion trunk. You can either `build it by yourself`_ or download one of our precompiled `nightly builds`_ - a copy of `virtualenv-pypy`_: this is a fork of virtualenv that contains all the patches needed to work with PyPy, and hopefully will be `merged back`_ at some point. It should be totally compatible with the official version of virtualenv, so it is safe to use it even to create non-PyPy environments. If you notice some weird behavior that does not happen with the standard virtualenv, please let us know. .. _`sys-prefix`: http://codespeak.net/pipermail/pypy-svn/2010-June/041686.html .. _virtualenv: http://pypi.python.org/pypi/virtualenv .. _`build it by yourself`: http://codespeak.net/pypy/dist/pypy/doc/getting-started-python.html#translating-the-pypy-python-interpreter .. _`nightly builds`: http://buildbot.pypy.org/nightly/trunk/ .. _`virtualenv-pypy`: http://bitbucket.org/antocuni/virtualenv-pypy/ .. _`merged back`: http://bitbucket.org/ianb/virtualenv/issue/53/virtualenv-with-pypy The directory layout has been redesigned in a way that it is possible to use virtualenv to install a PyPy both from a precompiled tarball or from an svn checkout:: # from a tarball $ virtualenv -p /opt/pypy-c-jit-76426-linux/bin/pypy my-pypy-env # from the svn checkout $ virtualenv -p /path/to/pypy-trunk/pypy/translator/goal/pypy-c my-pypy-env Once the environment has been created, you can enter it as usual. Note that ``bin/python`` is now a symlink to ``bin/pypy``. Enjoy it :-)