我关注这个网站:http ://cmusphinx.sourceforge.net/2011/05/building-pocketsphinx-on-android/ 。起初它工作正常。但是当我在文件 /jni/ 上 cmd ndk-build 时。错误显示如下:
Compile thumb : sphinxutil <= sbthread.c
Compile thumb : sphinxutil <= utf8.c
StaticLibrary : libsphinxutil.a
SharedLibrary : libpocketsphinx_jni.so
/home/tian/develop/android-ndk-r8c/toolchains/arm-linux-androideabi-4.6/
prebuilt/linux-x86/bin/../lib/gcc/arm-linux-androideabi/4.6/../../../../arm-linux-androideabi/bin/ld: /home/tian/桌面/PocketSphinxAndroidDemo/obj/local/armeabi/objs-debug/pocketsphinx_jni/pocketsphinx_wrap.o: in function nbest_s_hyp:/home/tian/桌面/PocketSphinxAndroidDemo/jni/pocketsphinx_wrap.c:793: error: undefined reference to 'new_Hypothesis'
/home/tian/develop/android-ndk-r8c/toolchains/arm-linux-androideabi-4.6/prebuilt/linux-x86/bin/../lib/gcc/arm-linux-androideabi/4.6/../../../../arm-linux-androideabi/bin/ld: /home/tian/桌面/PocketSphinxAndroidDemo/obj/local/armeabi/objs-debug/pocketsphinx_jni/pocketsphinx_wrap.o: in function ps_decoder_s_getHyp:/home/tian/桌面/PocketSphinxAndroidDemo/jni/pocketsphinx_wrap.c:847: error: undefined reference to 'new_Hypothesis'
collect2: ld returned 1 exit status
make: *** [/home/tian/桌面/PocketSphinxAndroidDemo/obj/local/armeabi/libpocketsphinx_jni.so] Error 1