fix compiling with --lua-dir on linux