lua-users home
lua-l archive

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


Diego Nehab wrote:

Hi,

Let's assume you are right, and that compat-5.1.lua is really broken.
The polite thing to do is to ask why is it that you can't get it to work, and perhaps point out one or two possible reasons.

On the other hand, wouldn't it be surprizing if a library that gets about
20 downloads per week from Windows users didn't work at all on Windows?

Turns out are using Lua 5.1, which has not been released yet.  LuaSocket
runs out of the box with Lua 5.0.2, which is the official Lua release as
of today. The entire compat-5.1.lua business is to get Lua 5.0.2 up to
speed with the new package system that Lua 5.1 implements out of the
box.

If you want to get LuaSocket to run with Lua 5.1, you naturally don't
need compat-5.1.lua. However, since you are not using the official Lua
release, you have to do some minor adjustments to LuaSocket, as has been
described on the list. Start by reading the thread

    http://lua-users.org/lists/lua-l/2005-02/msg00174.html

and disregard the messages about Mac OS X because you are running
Windows.

If you still can't get it to work, I will be more than happy to help
you.

Regards,
Diego.


Perhaps I'm confused by this from the LuaSocket-2.0-Beta3 "installation.html" page: " LuaSocket 2.0 uses the new package proposal for Lua 5.1. All Lua library developers are encouraged to update their libraries so that all libraries can coexist peacefully and users can benefit from the standardization and flexibility of the standard."

From all I can tell, it does not in fact natively use 5.1 package/require and, instead, depends on compat. I find this cnfusing.

It also does not alter the fact that compat-5.1.lua creates default paths that are totally incorrect for Windows users (and probably Mac users too!). The code, as written, is not platform sensitive.

Lastly, sorry if I came on too strong. I've been fussing for 3 days over Lua-5.1w5, Xavante and LuaSocket and without much luck!

My current problem is that LuaSocket won't get past "require socket", yet it's in the path per the LuaSocket doc. Nor will Lua itself read LUA_INIT, which mihgt solve the LuaSocket requre problem.

Dave LeBlanc
Seattle, WA USA