0

I am trying to install lua-cjson using luarocks. I have installed mingw32 as well as set a environment variable in system. I keep getting error: I've tried re-directing my lua folder to user public (as another post suggested), however that didn't help, only to get the same error.

I've even verified that MinGW is installed by using the --version command in CMD prompt, which works.

Error: Build error: Failed compiling module cjson.dll

enter image description here

I don't know what else to do as there are absolutely no posts on stackoverflow covering this issue.

  • you're trying to compile a dll file. That doesn't make sense. explain how you got there. what did you download, where did you place the files, what did you change and do to get to this point. also you might want to improve your websearch skills. there are plenty of topics covering this error message. for example: https://stackoverflow.com/questions/60806784/dll-file-format-not-recognized – Piglet Jul 08 '22 at 09:46
  • Does this answer your question? [Luarocks error building luafilesystem](https://stackoverflow.com/questions/27841288/luarocks-error-building-luafilesystem) – Joseph Sible-Reinstate Monica Jul 09 '22 at 18:43
  • No, I tried moving my lua folder to public like the user stated there. –  Jul 10 '22 at 08:23

1 Answers1

0

lua_objlen was removed. If you want this module to be working try luarocks install lua-cjson "CFLAGS=-DLUA_COMPAT_5_3"

Output

Reference

ALEN TL
  • 96
  • 1
  • 1
  • 6
  • Thanks, turns out the issue was that since I tried installing on a Hackintosh and had the same error. –  Jul 16 '22 at 07:28