LuaPbIntf
LuaPbIntf copied to clipboard
Binding Protobuf 3 to Lua 5.3
本人在 ubuntu 和 windows10 下都遇到 无法编译 按照这个: Build with conan Install conan. Add conan repositories conan remote add remote_bintray_bincrafters https://api.bintray.com/conan/bincrafters/public-conan conan remote add remote_bintray_jinq0123 https://api.bintray.com/conan/jinq0123/test conan create . user/channel --build...
how to build to .so not .dylib on macOS .dylib. can't read
It describes Binding Protobuf 3 to Lua 5.3
上次是在skynet中测试。发现在skynet.start中无法正常解码 然后经过一段时间的观察。并且问了skynet的作者。结论是你这边在协程中的绑定lua时的问题。 测试代码如下 pb.import_proto_file("login.proto") local pbstr = pb.encode("login.login", {account="king",password="111111"}) print("encode") local pbmsg=pb.decode("login.login",pbstr) print(tool.dump(pbmsg)) print("=========================") local cor=coroutine.create(function() local msg= pb.decode("login.login", pbstr) print("decode") print(tool.dump(msg)) end) coroutine.resume(cor) 打印结果如下 encode { ["password"] = "111111",...
协议体 syntax = "proto3"; package login; message login { string account = 1 ; string password = 2 ; int32 sdkid = 3 ; } 发送下面这个包,客户端发完后直接解包是正常解出来的 send pbstr:0A 04 6B...
would be great if we could use this library from luajit
would be great if this awesome lib could be added to luarocks