0

我在尝试编译cmu sphinx 工具包的 sphinx3 模块时遇到以下错误消息

Making all in programs
make[2]: Entering directory `/cygdrive/c/Downloads/src/cmusphinx-code/sphinx3/src/programs'
/bin/sh ../../libtool --tag=CC    --mode=link gcc  -g -O2 -Wall -fvisibility=hidden    -o sphinx3_decode.exe main_decode.o ../../src/libs3decoder/libs3decoder.la  -lsphinxbase -lsphinxad -lm 
libtool: link: gcc -g -O2 -Wall -fvisibility=hidden -o .libs/sphinx3_decode.exe main_decode.o  ../../src/libs3decoder/.libs/libs3decoder.a -lsphinxbase -lsphinxad
/usr/local/lib/libsphinxbase.a(matrix.o): In function `determinant':
/cygdrive/c/Downloads/src/cmusphinx-code/sphinxbase/src/libsphinxbase/util/matrix.c:196: undefined reference to `_spotrf_'
/usr/local/lib/libsphinxbase.a(matrix.o): In function `solve':
/cygdrive/c/Downloads/src/cmusphinx-code/sphinxbase/src/libsphinxbase/util/matrix.c:226: undefined reference to `_sposv_'
/usr/local/lib/libsphinxbase.a(matrix.o): In function `invert':
/cygdrive/c/Downloads/src/cmusphinx-code/sphinxbase/src/libsphinxbase/util/matrix.c:254: undefined reference to `_sposv_'
/usr/local/lib/libsphinxbase.a(matrix.o): In function `matrixmultiply':
/cygdrive/c/Downloads/src/cmusphinx-code/sphinxbase/src/libsphinxbase/util/matrix.c:272: undefined reference to `_ssymm_'
collect2: ld returned 1 exit status
Makefile:420: recipe for target `sphinx3_decode.exe' failed
make[2]: *** [sphinx3_decode.exe] Error 1
make[2]: Leaving directory `/cygdrive/c/Downloads/src/cmusphinx-code/sphinx3/src/programs'
Makefile:284: recipe for target `all-recursive' failed
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/cygdrive/c/Downloads/src/cmusphinx-code/sphinx3/src'
Makefile:407: recipe for target `all-recursive' failed
make: *** [all-recursive] Error 1

问题似乎不是找不到 cmu sphinx 库liblsphinxbase.a。而是该库有问题。我已经nm在这个库上运行了命令,这就是我所得到的(似乎相当空)。

nm libsphinxbase.a | grep _spotrf_
U _spotrf_

是否应该将标志-llapack添加到链接步骤?

4

1 回答 1

0

我已经测试了失败的步骤llapack并且它有效。看来-llapack需要添加到链接命令中。

于 2013-08-04T15:19:11.450 回答