We use lua 5.1's source codes as a replacement of luajit's source codes.
virtualvenv venv
and switch to the virtual enviornmentpip install cython
git clone https://github.com/scoder/lupa.git
cd lupa/
, copy lua 5.1 source tarball here andtar zxf
it.- go to
lua-5.1.5/src
thenmake macosx
- Back to lupa's root directory, open
setup.py
, change the following lines:
# from
if not filename.lower().startswith('luajit'):
continue
# =>
if not filename.lower().startswith('lua'):
continue
# from
libfile = os_path.join(filepath, 'libluajit.a')
# to
libfile = os_path.join(filepath, 'liblua.a')
Finally python setup.py install