setup: do not ignore pkg-config failure
setup: reformat to make pep8 happy
setup: simplify pkgconfig() to match how it's called
setup: try multiple package names before giving up on pkg-config
setup: factor out repeated calls to pkgconfig()
Catch up with API change in Lua 5.1: luaL_openlib() -> luaL_register().
Easy changes for compatibility with Lua 5.2.

- type luaL_reg is now luaL_Reg
- define LUA_COMPAT_ALL or LUA_COMPAT_MODULE to enable some deprecated
  features

This still builds with Lua 5.1. It doesn't yet build with 5.2, but
it's closer than it was.
Test Lua's globals() and require() from Python
setup: make it easier to change Lua version
Use a simpler way to fetch Lua globals.

This is less code, and it works with Lua 5.1 and 5.2 as well. (The old
code, using LUA_GLOBALINDEX, does not work with 5.2.)
setup: switch to use Lua 5.2 by default.

It's been out for just over a year now, since Dec 2011. Lua 5.1 is
over six years old (Feb 2006).
Merge pull request #5 from gward/master

fix setup script, port to Lua 5.2