我已经有这个问题好几个小时了,但仍然没有解决,几乎尝试了一切尝试 python 3.10 和 3.8,这是我通常得到的错误:
Collecting aubio
Downloading aubio-0.4.9.tar.gz (479 kB)
---------------------------------------- 479.0/479.0 KB 652.0 kB/s eta 0:00:00
Preparing metadata (setup.py) ... done
Requirement already satisfied: numpy in c:\users\admin\appdata\local\programs\python\python310\lib\site-packages (from aubio) (1.21.4)
Using legacy 'setup.py install' for aubio, since package 'wheel' is not installed.
WARNING: Ignoring invalid distribution -pencv-contrib-python (c:\users\admin\appdata\local\programs\python\python310\lib\site-packages)
Installing collected packages: aubio
Running setup.py install for aubio ... error
error: subprocess-exited-with-error
× Running setup.py install for aubio did not run successfully.
│ exit code: 1
╰─> [32 lines of output]
running install
running build
running build_py
creating build
creating build\lib.win-amd64-3.10
creating build\lib.win-amd64-3.10\aubio
copying python\lib\aubio\cmd.py -> build\lib.win-amd64-3.10\aubio
copying python\lib\aubio\cut.py -> build\lib.win-amd64-3.10\aubio
copying python\lib\aubio\midiconv.py -> build\lib.win-amd64-3.10\aubio
copying python\lib\aubio\slicing.py -> build\lib.win-amd64-3.10\aubio
copying python\lib\aubio\__init__.py -> build\lib.win-amd64-3.10\aubio
running build_ext
error: Microsoft Visual C++ 14.0 or greater is required. Get it with "Microsoft C++ Build Tools": https://visualstudio.microsoft.com/visual-cpp-build-tools/
checking for aubio = 0.4.9
Running "pkg-config --libs --cflags aubio = 0.4.9" failed: FileNotFoundError(2, 'The system cannot find the file specified', None, 2, None)
Info: aubio 0.4.9 was not found by pkg-config
Info: looking for *optional* additional packages
checking for libavcodec
Running "pkg-config --libs --cflags libavcodec" failed: FileNotFoundError(2, 'The system cannot find the file specified', None, 2, None)
checking for libavformat
Running "pkg-config --libs --cflags libavformat" failed: FileNotFoundError(2, 'The system cannot find the file specified', None, 2, None)
checking for libavutil
Running "pkg-config --libs --cflags libavutil" failed: FileNotFoundError(2, 'The system cannot find the file specified', None, 2, None)
checking for libswresample
Running "pkg-config --libs --cflags libswresample" failed: FileNotFoundError(2, 'The system cannot find the file specified', None, 2, None)
checking for libavresample
Running "pkg-config --libs --cflags libavresample" failed: FileNotFoundError(2, 'The system cannot find the file specified', None, 2, None)
checking for sndfile
Running "pkg-config --libs --cflags sndfile" failed: FileNotFoundError(2, 'The system cannot find the file specified', None, 2, None)
checking for samplerate
Running "pkg-config --libs --cflags samplerate" failed: FileNotFoundError(2, 'The system cannot find the file specified', None, 2, None)
Info: libaubio was not installed or built locally with waf, adding src/
[end of output]
note: This error originates from a subprocess, and is likely not a problem with pip.
error: legacy-install-failure
× Encountered error while trying to install package.
╰─> aubio
注意:这是上面提到的包的问题,而不是 pip。提示:有关失败的输出,请参见上文。