lua-zmq is a simple(but not complete) Lua 5.3 binding of ZeroMQ 4.x
First obtain premake5.
- Type
premake5 vs2013
on command window to generate MSVC solution files. - Use Visual Studio 2013(either Ultimate or Community version) to compile executable binaries.
- Type
./build_deps.sh
to install libzmq and libsolidum - Type
premake5 gmake && make config=release_x64
local zmq = require 'luazmq'
zmq.init()
local c = zmq.socket(zmq.REQ)
c.set_identity('node002')
while true do
c.send('hello')
local rep = c.recv()
print(rep)
end
zmq.shutdown()
zmq.terminate()