Windows:致命错误C1083:无法打开包含文件:'lua.h':没有这样的文件或目录

我试图在Windows中使用pip安装-r requirements.txt一个python项目的一些要求,但是这仍然失败。 经过一番调查,我发现因为lupa而失败了。 运行“pip install lupa”会显示与我尝试安装以下堆栈跟踪所示的要求相同的错误:

Collecting lupa Using cached lupa-1.2.tar.gz Building wheels for collected packages: lupa Running setup.py bdist_wheel for lupa: started Running setup.py bdist_wheel for lupa: finished with status 'error' Complete output from command d:\development\tools\python\python.exe -u -c "import setuptools, tokenize;__file__='C:\\Users\\Achiraaz\\AppData\\Local\\Temp\\pip-build-g477k1jp\\lupa\\setup.py';exec(compile(getattr(tokenize, 'open', open)(__file__).read().replace('\r\n', '\n'), __file__, 'exec'))" bdist_wheel -d C:\Users\Achiraaz\AppData\Local\Temp\tmped2hn2icpip-wheel- --python-tag cp35: No local build of LuaJIT2 found in lupa directory Checking for installed luajit library using pkg-config pkg-config found luajit version 2.0.4 building without Cython running bdist_wheel running build running build_py creating build creating build\lib.win32-3.5 creating build\lib.win32-3.5\lupa copying lupa\version.py -> build\lib.win32-3.5\lupa copying lupa\__init__.py -> build\lib.win32-3.5\lupa running build_ext building 'lupa._lupa' extension creating build\temp.win32-3.5 creating build\temp.win32-3.5\Release creating build\temp.win32-3.5\Release\lupa D:\Development\IDE\Microsoft Visual Studio 14.0\VC\BIN\cl.exe /c /nologo /Ox /W3 /GL /DNDEBUG /MD -DLUA_COMPAT_ALL -I/usr/include/luajit-2.0 -Id:\development\tools\python\include -Id:\development\tools\python\include "-ID:\Development\IDE\Microsoft Visual Studio 14.0\VC\INCLUDE" "-ID:\Development\IDE\Microsoft Visual Studio 14.0\VC\ATLMFC\INCLUDE" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.10586.0\ucrt" "-IC:\Program Files (x86)\Windows Kits\NETFXSDK\4.6.1\include\um" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.10586.0\shared" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.10586.0\um" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.10586.0\winrt" "-ID:\Development\IDE\Microsoft Visual Studio 14.0\VC\INCLUDE" "-ID:\Development\IDE\Microsoft Visual Studio 14.0\VC\ATLMFC\INCLUDE" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.10586.0\ucrt" "-IC:\Program Files (x86)\Windows Kits\NETFXSDK\4.6.1\include\um" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.10586.0\shared" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.10586.0\um" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.10586.0\winrt" /Tclupa/_lupa.c /Fobuild\temp.win32-3.5\Release\lupa/_lupa.obj _lupa.c lupa/_lupa.c(265): fatal error C1083: Cannot open include file: 'lua.h': No such file or directory error: command 'D:\\Development\\IDE\\Microsoft Visual Studio 14.0\\VC\\BIN\\cl.exe' failed with exit status 2 ---------------------------------------- Running setup.py clean for lupa Failed to build lupa Installing collected packages: lupa Running setup.py install for lupa: started Running setup.py install for lupa: finished with status 'error' Complete output from command d:\development\tools\python\python.exe -u -c "import setuptools, tokenize;__file__='C:\\Users\\Achiraaz\\AppData\\Local\\Temp\\pip-build-g477k1jp\\lupa\\setup.py';exec(compile(getattr(tokenize, 'open', open)(__file__).read().replace('\r\n', '\n'), __file__, 'exec'))" install --record C:\Users\Achiraaz\AppData\Local\Temp\pip-5d7gkihi-record\install-record.txt --single-version-externally-managed --compile: No local build of LuaJIT2 found in lupa directory Checking for installed luajit library using pkg-config pkg-config found luajit version 2.0.4 building without Cython running install running build running build_py creating build creating build\lib.win32-3.5 creating build\lib.win32-3.5\lupa copying lupa\version.py -> build\lib.win32-3.5\lupa copying lupa\__init__.py -> build\lib.win32-3.5\lupa running build_ext building 'lupa._lupa' extension creating build\temp.win32-3.5 creating build\temp.win32-3.5\Release creating build\temp.win32-3.5\Release\lupa D:\Development\IDE\Microsoft Visual Studio 14.0\VC\BIN\cl.exe /c /nologo /Ox /W3 /GL /DNDEBUG /MD -DLUA_COMPAT_ALL -I/usr/include/luajit-2.0 -Id:\development\tools\python\include -Id:\development\tools\python\include "-ID:\Development\IDE\Microsoft Visual Studio 14.0\VC\INCLUDE" "-ID:\Development\IDE\Microsoft Visual Studio 14.0\VC\ATLMFC\INCLUDE" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.10586.0\ucrt" "-IC:\Program Files (x86)\Windows Kits\NETFXSDK\4.6.1\include\um" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.10586.0\shared" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.10586.0\um" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.10586.0\winrt" "-ID:\Development\IDE\Microsoft Visual Studio 14.0\VC\INCLUDE" "-ID:\Development\IDE\Microsoft Visual Studio 14.0\VC\ATLMFC\INCLUDE" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.10586.0\ucrt" "-IC:\Program Files (x86)\Windows Kits\NETFXSDK\4.6.1\include\um" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.10586.0\shared" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.10586.0\um" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.10586.0\winrt" /Tclupa/_lupa.c /Fobuild\temp.win32-3.5\Release\lupa/_lupa.obj _lupa.c lupa/_lupa.c(265): fatal error C1083: Cannot open include file: 'lua.h': No such file or directory error: command 'D:\\Development\\IDE\\Microsoft Visual Studio 14.0\\VC\\BIN\\cl.exe' failed with exit status 2 ---------------------------------------- 

我首先尝试编译和安装luajit,使用http://luajit.org/install.html上描述的方法,但这并没有解决问题。

然后,我设法使用hererocks来安装luajit(至less我想我是这样做的),但由于某种原因,即使文件位于luajit / include库中,也不会使用lua.h,所以最终结果是一样的。

我发现这篇文章: build立Lua for Windows的luafilesystem ,我试图玩弄所描述的环境variables,但没有运气..

在我看来,该文件是由于某种原因没有包括在构build中,我不能解决这个问题。

所有或任何帮助和build议表示赞赏。

我正在使用Visual Studio Express版本运行Windows 10。 我已经安装了cygwin和mingw,但如果可能的话,我想坚持使用SDK。