I am building a static go binary with the following command:
go build -tags "luaa lua54 yara_static" -o behavior-svc cmd/behavior/behavior.go
Compilation works fine, except that when my Lua file try to require a module (require 'rapidjson' or lua-cjson that I installed via luarocks, it fails with:
{"level":"error","ts":1730523563.6323617,"caller":"behavior/behavior.go:41","msg":"failed to run the server: error loading module 'cjson' from file 'cjson.so' undefined symbol: lua_checkstack",}
Running the lua script though lua interpreter directly works fine.
Hello @aarzilli
Environment:
I am building a static go binary with the following command:
Compilation works fine, except that when my Lua file try to
require
a module (require 'rapidjson' orlua-cjson
that I installed via luarocks, it fails with:Running the lua script though lua interpreter directly works fine.
Do you know why this is failing ?
Cheers.