Why does PocketSphinx Android demo require cygwin

2020-03-26 08:37发布

I am trying to develop a speech recognition program in android and so far I have seen that themost popular option seems to be CMU sphinx, with pocketsphinx being used for android. From what I have understood the source code for CMU Sphinx has been provided in Java for running on a computer, so will not directly run on an android phone. So I will first have to compile the CMu sphinx code into a sort of library (something like creating a dll out a code I need to share if I was working in C), then build an interface in android and call the classes from cmusphinx. So fr I have found this post and this tutorial seems to be the most popular one which everyone is referring to. It provides a link for windows users which point here. In this page at the beginning the poster states that the tutorial may or may not work on all machines (which is a worry for a beginner), but more importantly, it needs me to download Eclipse, NDK, Cygwin and all sorts of things. I understand that NDK might be a necessity and I should get it, but I already do all my development in the Android SDK.

Is it possible to do this without having to install cygwin and Eclipse, by just using the Android SDK that I use to write all my programs? What exactly do I need cygwin and eclipse for? Can't I do whatever eclipse is supposed to do in that tutorial, using the Android SDK?

1条回答
手持菜刀,她持情操
2楼-- · 2020-03-26 09:01

Is it possible to do this without having to install cygwin and Eclipse, by just using the Android SDK that I use to write all my programs?

Yes, it's perfectly possible with the latest version. Development has never been easier, you can just checkout project with subversion from here:

https://svn.code.sf.net/p/cmusphinx/code/trunk cmusphinx-code

Subversion plugin is part of the Eclipse.

Once you checkout the project, you can just build it for your device and it will work. A good updated manual for this will be released soon on the website (wait for 2 weeks).

What exactly do I need cygwin and eclipse for?

Eclipse is the IDE to give you access to SDK features through the graphical user interface.

You do not need Cygwin, this is a misconception of the author of the blog post.

For old version you also need NDK which is used to compile native code into binary. Pocketsphinx uses native code for more efficient decoding with a limited resources of mobile system.

Can't I do whatever eclipse is supposed to do in that tutorial, using the Android SDK?

You can.

查看更多
登录 后发表回答