/usr/bin/ld: 找不到 -lasound

guy*_*guy 4 c makefile snowboy

在snowboy/examples/C/文件夹中的snowboy上使用make命令时,出现以下错误

/usr/bin/ld: cannot find -lf77blas
/usr/bin/ld: cannot find -lcblas
/usr/bin/ld: cannot find -llapack_atlas
/usr/bin/ld: cannot find -latlas
/usr/bin/ld: cannot find -lasound
Run Code Online (Sandbox Code Playgroud)

-lasound我已经成功地用命令解决了所有问题

sudo apt-get install libatlas-base-dev
Run Code Online (Sandbox Code Playgroud)

如何添加缺少的库-lasound

guy*_*guy 6

文件中有注释行,install_portaudio.sh其中指出

# On linux systems, we only build with ALSA, so make sure you install it using
# e.g.:
#   sudo apt-get -y install libasound2-dev
Run Code Online (Sandbox Code Playgroud)

sudo apt-get -y install libasound2-dev因此,只需在终端中运行该命令就可以了。