Skip to content

HowToCompileInterpreter

Bystroushaak edited this page Sep 20, 2019 · 4 revisions

Edit: Alternatively you can also use Docker.

You will need:

  • mercurial
  • pypy
  • gcc
  • python

Start with standard dev tools:

sudo apt install libffi-dev libffi6 pkg-config build-essential

PYPY with PIP

You can install pypy from your repositories. For example:

sudo apt install pypy libffi-dev libffi6 pkg-config build-essential

PIP for pypy

You will also need PIP configured to install packages into your pypy paths. Easiest way how to do it is to run the PIP install script:

curl https://bootstrap.pypa.io/get-pip.py | pypy - --user

rpython

Get newest version of the rpython, which is part of the pypy project repository:

hg clone https://bitbucket.org/pypy/pypy

(If you already have the repository cloned, just run hg pull.)

Last tested working revision is 97567 (this is actually important):

hg update 97567

rply

Newest version of the rply (parser):

pypy -m pip install --user -U git+https://github.com/alex/rply.git

requirements.txt

Stuff from the requirements.txt:

pip install --user -r requirements.txt

Compilation

After installation of all requirements, run

./compile.py

from the root of the project. You should get binary named tSelf.

Clone this wiki locally