2012-03-25 61 views
1

我試圖在我的Windows 7上使用Cygwin安裝sphinxbase以運行pocketsphinx android演示。 但我得到了以下錯誤執行令後:在cygwin中編譯sphinxbase時出錯

gcc -shared -Wl,--enable-auto-image-base build/temp.cygwin-1.7.11-i686-2.6/sphinxbase.o -L../src/libsphinxbase/.libs -L/usr/lib/python2.6/config -lsphinxbase -liconv -lpython2.6 -o build/lib.cygwin-1.7.11-i686-2.6/sphinxbase.dll 
/usr/lib/gcc/i686-pc-cygwin/4.5.3/../../../../i686-pc-cygwin/bin/ld: cannot find -liconv 
collect2: ld returned 1 exit status 
error: command 'gcc' failed with exit status 1 
Makefile:471: recipe for target `pymod-build-stamp' failed 
make[1]: *** [pymod-build-stamp] Error 1 
make[1]: Leaving directory `/cygdrive/c/psph/sphinxbase/python' 
Makefile:330: recipe for target `all-recursive' failed 
make: *** [all-recursive] Error 1. 

我參觀了鏈接http://www.cs.columbia.edu/~ecooper/CS4706/ps-cygwin.html和遵循的步驟,但相同的結果。 我在上面的情況中使用了pocketsphinx-0.7和sphinxbase-0.7。

+0

這是整個錯誤嗎?我想,在粘貼日誌之前應該有其他的東西。 – 2012-03-25 17:36:16

+0

以下是完整的日誌: – rahulserver 2012-03-26 08:23:06

回答

2

錯誤:

ld: cannot find -liconv 

意味着,你沒有安裝的iconv。在包管理器中查找名稱爲libiconv-dev或類似的包。

+0

在附帶的說明中還有簡短的提及。在問這裏之前,您是否閱讀過指令和錯誤日誌? – 2012-03-26 08:29:55

+0

這意味着你已經將libiconv作爲Cygwin軟件包安裝,並將setup.py中的行修改爲:'libraries = ['pocketsphinx','sphinxbase','iconv']'? – 2012-03-26 11:47:54

+0

如果您在安裝過程中遇到錯誤,您爲什麼認爲該軟件包已安裝? – 2012-03-26 11:51:00