User:Aslantis/Luajit on PPC64

From Gentoo Wiki
Jump to:navigation Jump to:search

Simple guide for getting luajit running on PPC64.


While the required fork of luajit runs, it does not actually have the JIT functionality, so it will still be slow. It also has not been updated for 6 years as of writing this. That said, upstream luajit does support PPC32 big endian, complete with JIT functionality: so if you're running big endian ppc64, you might get the best performance running the 32 bit build of upstream luajit. I plan to write a PPC64 multilib guide soon(ish).

Debian, RHEL, and Suse package this fork of luajit on PPC64. All of the tests that pass on upstream ppc32 pass on this fork (or should).

How to install

First off, there's no live ebuild of luajit in ::gentoo. But, there is one in mva's overlay. So lets merge that now:

root #eselect repository enable mva
root #emerge --sync mva

Then, we need to specify the fork we want to build:

FILE /etc/portage/env/luajit-live
FILE /etc/portage/package.env
*/luajit luajit-live
FILE /etc/portage/package.accept_keywords
dev-lang/luajit **

Now, we should be able to just compile luajit:

root #emerge -va luajit
root #luajit --version

Set systemwide

As you can guess this could potentially be (and probably is) a bad idea. So I guess I'm supposed to be discouraging this. :)
FILE /etc/portage/profile/package.use.mask/ppc
*/* -lua_single_target_luajit
FILE /etc/portage/make.conf
root #emerge -va --deep --changed-use @world