无法使用 pip3 安装 mmh3

无法使用 pip3 安装 mmh3

我已经安装了 Visual Studio。为什么这个包安装失败?

pip3 install mmh3
Collecting mmh3
  Using cached mmh3-2.5.1.tar.gz (9.8 kB)
Building wheels for collected packages: mmh3
  Building wheel for mmh3 (setup.py) ... error
  ERROR: Command errored out with exit status 1:
   command: 'C:\Users\ALECT\AppData\Local\Microsoft\WindowsApps\PythonSoftwareFoundation.Python.3.8_qbz5n2kfra8p0\python.exe' -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'C:\\Users\\ALECT\\AppData\\Local\\Temp\\pip-install-wx1yyipb\\mmh3\\setup.py'"'"'; __file__='"'"'C:\\Users\\ALECT\\AppData\\Local\\Temp\\pip-install-wx1yyipb\\mmh3\\setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' bdist_wheel -d 'C:\Users\ALECT\AppData\Local\Temp\pip-wheel-86bm0jkz'
       cwd: C:\Users\ALECT\AppData\Local\Temp\pip-install-wx1yyipb\mmh3\
  Complete output (11 lines):
  running bdist_wheel
  running build
  running build_ext
  building 'mmh3' extension
  creating build
  creating build\temp.win-amd64-3.8
  creating build\temp.win-amd64-3.8\Release
  C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.28.29333\bin\HostX86\x64\cl.exe /c /nologo /Ox /W3 /GL /DNDEBUG /MD "-IC:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.8_3.8.1776.0_x64__qbz5n2kfra8p0\include" "-IC:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.8_3.8.1776.0_x64__qbz5n2kfra8p0\include" "-IC:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.28.29333\include" "-IC:\Program Files (x86)\Windows Kits\NETFXSDK\4.8\include\um" /EHsc /Tpmmh3module.cpp /Fobuild\temp.win-amd64-3.8\Release\mmh3module.obj
  mmh3module.cpp
  mmh3module.cpp(12): fatal error C1083: Cannot open include file: 'stdio.h': No such file or directory
  error: command 'C:\\Program Files (x86)\\Microsoft Visual Studio\\2019\\Community\\VC\\Tools\\MSVC\\14.28.29333\\bin\\HostX86\\x64\\cl.exe' failed with exit status 2
  ----------------------------------------
  ERROR: Failed building wheel for mmh3
  Running setup.py clean for mmh3
Failed to build mmh3
Installing collected packages: mmh3
    Running setup.py install for mmh3 ... error
    ERROR: Command errored out with exit status 1:
     command: 'C:\Users\ALECT\AppData\Local\Microsoft\WindowsApps\PythonSoftwareFoundation.Python.3.8_qbz5n2kfra8p0\python.exe' -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'C:\\Users\\ALECT\\AppData\\Local\\Temp\\pip-install-wx1yyipb\\mmh3\\setup.py'"'"'; __file__='"'"'C:\\Users\\ALECT\\AppData\\Local\\Temp\\pip-install-wx1yyipb\\mmh3\\setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' install --record 'C:\Users\ALECT\AppData\Local\Temp\pip-record-ldyi_lw5\install-record.txt' --single-version-externally-managed --user --prefix= --compile --install-headers 'C:\Users\ALECT\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.8_qbz5n2kfra8p0\LocalCache\local-packages\Python38\Include\mmh3'
         cwd: C:\Users\ALECT\AppData\Local\Temp\pip-install-wx1yyipb\mmh3\
    Complete output (11 lines):
    running install
    running build
    running build_ext
    building 'mmh3' extension
    creating build
    creating build\temp.win-amd64-3.8
    creating build\temp.win-amd64-3.8\Release
    C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.28.29333\bin\HostX86\x64\cl.exe /c /nologo /Ox /W3 /GL /DNDEBUG /MD "-IC:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.8_3.8.1776.0_x64__qbz5n2kfra8p0\include" "-IC:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.8_3.8.1776.0_x64__qbz5n2kfra8p0\include" "-IC:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.28.29333\include" "-IC:\Program Files (x86)\Windows Kits\NETFXSDK\4.8\include\um" /EHsc /Tpmmh3module.cpp /Fobuild\temp.win-amd64-3.8\Release\mmh3module.obj
    mmh3module.cpp
    mmh3module.cpp(12): fatal error C1083: Cannot open include file: 'stdio.h': No such file or directory
    error: command 'C:\\Program Files (x86)\\Microsoft Visual Studio\\2019\\Community\\VC\\Tools\\MSVC\\14.28.29333\\bin\\HostX86\\x64\\cl.exe' failed with exit status 2
    ----------------------------------------
ERROR: Command errored out with exit status 1: 'C:\Users\ALECT\AppData\Local\Microsoft\WindowsApps\PythonSoftwareFoundation.Python.3.8_qbz5n2kfra8p0\python.exe' -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'C:\\Users\\ALECT\\AppData\\Local\\Temp\\pip-install-wx1yyipb\\mmh3\\setup.py'"'"'; __file__='"'"'C:\\Users\\ALECT\\AppData\\Local\\Temp\\pip-install-wx1yyipb\\mmh3\\setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' install --record 'C:\Users\ALECT\AppData\Local\Temp\pip-record-ldyi_lw5\install-record.txt' --single-version-externally-managed --user --prefix= --compile --install-headers 'C:\Users\ALECT\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.8_qbz5n2kfra8p0\LocalCache\local-packages\Python38\Include\mmh3' Check the logs for full command output.

相关内容