lua: fix build on Tiger

Fixes #260.
Fixes #245.