lua-users home
lua-l archive

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

On 18/05/2013 22.57, Lorenzo Donati wrote:
On 18/05/2013 22.04, Paul K wrote:
Hi Lorenzo,

unfortunately I have no bash nor any kind of *NIX environment
available (I just double checked and realized I typed TDM-mingw
instead of TDM-GCC - my bad, sorry for the misunderstanding).

Right; I assumed you have mingw that usually comes with bash and
similar tools that run on Windows. You actually don't need to have
that as you can download and unzip sources manually and then just run
gcc commands you see in the shell script.

BTW, is zerobranestudio distributed in binary form?

Yes, you can get Windows binaries here:
(luasocket is in clibs/ subfolder).

If it is, maybe I may try to reuse the included dll

You should be able to. I've tried with various lua environments on
windows and it worked without problems. The dlls are compiled against


It works, at least with the following basic test, thanks!!!

local socket = require 'socket'
print( socket._VERSION )

local http = require("socket.http")

Just one quirk: socket._VERSION returns 2.0.2 instead of 2.0.3.
A typo in the source?

-- Lorenzo

Maybe I should mention that to make it work I had to copy also the file headers.lua in parallel with ftp.lua.

In other words, I had to "replace" (virtually, in the manual procedure I followed to mimick the script behaviour) the following line in the bash script (line 173):

cp src/{ftp.lua,http.lua,smtp.lua,tp.lua,url.lua} "$INSTALL_DIR/share/lua/5.1/socket"

with the following one:

cp src/{headers.lua,ftp.lua,http.lua,smtp.lua,tp.lua,url.lua} "$INSTALL_DIR/share/lua/5.1/socket"

Did I miss something? Without this "change" I get an error when running the simple test I mentioned.

-- Lorenzo