I’ve compiled Lua 5.2 on Debian x86-64 with make posix, and am trying to compile the following with the command ‘gcc -ldl -llua main.c’
#include "lua.h" #include "lauxlib.h" #include "lualib.h" int main() { lua\_State \*L = luaL\_newstate(); luaL\_openlibs(L); dofile("test.lua"); return 0; }
and get unresolved references to the lua functions.