lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]


After reading all the discussion about how to statically compile Lua modules into an executable, I can only think that the amount of work required to build a Lua system (an application with Lua VM and a set of embedded libraries) is becoming too great.

In the good-old days all I had to do is read the README file of each library to check its dependencies, statically link everything, open the libraries in the correct order, maybe execute Lua code also embedded in the executable and call my main Lua script. This is not a hard thing for developers to do.

Nowadays it looks like I have to fight against the established way of doing things. While there seem to be ways of doing the above, everything sounds like a hack, which makes me feel very uncomfortable with the result.

Lua is simple, so its libraries should be. It's much more in line with Lua's philosophy to have simple libraries and make a module system *if* required than the other way around. It also saves memory. In the game industry people count bytes. Why have a module system only to have to hack it to make it behave as if it wasn't there?

I don't seem to remember the necessity that brought Lua modules to life. Was it to make life easier for the language users? Who are the language users? For me they are the ones embedding Lua inside routers, game engines or making up great batteries-included applications meant to be used for people not so versed in the world of C and make.

Lua has always been simple and easily embeddable. It still is. But its libraries aren't anymore.

Cheers,

Andre