I m trying to setup a c++ console application with lua. For whatever reason, I can t get it to build. I think it is some issue with the .lib file.
我发现的错误是:
1>------ Build started: Project: testLua, Configuration: Debug Win32 ------
1> testLua.cpp
1>testLua.obj : error LNK2019: unresolved external symbol _luaL_newstate referenced in function _wmain
1>C:UsersBMillekDesktopTestLua estLuaDebug estLua.exe : fatal error LNK1120: 1 unresolved externals
========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========
这里,我的主要工作是:
extern "C" {
#include "lua.h"
#include "lualib.h"
#include "lauxlib.h"
}
lua_State* L;
int _tmain(int argc, _TCHAR* argv[])
{
L = lua_open();
while(true)
;
return 0;
}
I did not compile lua myself. I got lua5_1_4_Win64_vc10_lib.zip off of SourceForge. I am running Windows 7, 64 bit.
For Linker->Input I have lua5.1.lib
For VC ++ Directores->Include Directories I have C:Program Fileslua5.1include
For VC ++ Reference Directories, Library Directories I have C:Program Fileslua5.1
试图将校正改写为无效档案名称,给我留下了一个错误,因此,我认为这是看到的。
我的数字必须是我失踪的,但我不知道什么。 任何想法?