Compatibility with lua 5.2 without LUA_COMPAT_ALL

* Issues with `module()`/`unpack` resolved
* Fixed a bug: `luarocks.fs.lua.get_md5(file)` could raise a strange error when opening the file failed
* Fixed `path` command not having help message(it was left in the library part of `path.lua`)
* Removed some unused variables

It installs and runs on Lua 5.2.3 without LUA_COMPAT_ALL flag fine. At least I could install important modules such as `luaposix` and `luasocket`. All the commands seem to work, too. 

Most of the core modules use `package.reloaded` trick to avoid issues with circular dependencies. For some of them it can be removed. 

One remaining issue is with `install.bat` script appending old site_config to the new one when installing on Windows. It will break now that the config uses `local site_config = {}; ...; return site_config` scheme. I don't know if I should do something with this and can't test it on Windows. Maybe instead of being a module the config should be a list of assignments, like a rockspec.