build: add new defines in Makefile

Some info will be shared between the rockspec and the C source, so
prepare the ground by defining them in Makefile and using them in the
rockspec whenever possible.
Port to Lua 5.2 and encapsulation

Rewrite of the C source to use new Lua 5.2 APIs. Refactored C code for
easier understanding. Encapsulated Lua code to avoid globals leakage.
test.lua: check the syslog.lua porcelain
Bump to 2.0.0