I had sucsesfully built an project based on pocketsphinx for home voice controle.
Now I'm trying to cross compile my project to work on OpenWRT Rt3883.
So is theire any one that had already cross compile the pocketsphinx and sphinxbase librarys for OpenWRT RT3883?
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
I still have problem with the compiling toolchaine. cause it break at the end. just after compiling all codes it sucssed at creating the .o of all .c files but when creating the package it fail :/
I'm using OpenWRT SDK for cross-compiling. it provide a tool chaine with all prerecuired configuration.
If you can help me on telling me what is the source of the error I will be so thunkfull :)
In the future you can just look for files containing --disable-nls, it will give you the exact location for a trouble. If you know how to search inside files it can help you a lot.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
configure: WARNING: Disabling python since development headers were not found
install: omitting directory `/home/amir/Bureau/openwrt/build_dir/target-mipsel_r2_uClibc-0.9.32/sphinxbase-0.8'
make[2]: [/home/amir/Bureau/openwrt/bin/ramips/packages/sphinxbase-0.8_0.8-1_ramips.ipk] Error 1
make[1]: [package/sphinxbase-0.8/compile] Error 2
make: *** [package/sphinxbase-0.8/compile] Error 2
//for the first warning it's normal even when I compile the project for my PC it show and it end with succes.
when I excute { $./configure } manualy for my PC configuration this script show error and telling me
./configure: line 2116: config.log: Permission denied
./configure: line 2126: config.log: Permission denied
unless I excute it with root : { $sudo ./configure }
any way I don't think that this is the source of problem cause what is done in my pc when I excute the configure script with root is maked when the configure is excuted by the OpenWRT SDK.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
$(PKG_BUILD_DIR) don't contain the sared libraries ".so" that had been cross-compiled.
infact the .so files are palced in the src directorie incide lib folders.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
At this stage I succeed implementing the recognition program on my target "RT3883" OS OpenWRT, I installed pulse-audio deamon 5.0 and the tow libraries sphinxbase-0.8 and pocketsphinx-0.8.
the problem is that the program return error :
Error opening audio device alsa_input.0.analog-mono for capture: Connection refused
FATAL_ERROR: "fr-recognizer.c", line 117: Failed to open audio device
I get the name of the device by using this command :
searching for the source of the problem I noticed that pulseaudio is automatically killed when the program try to execute this line witch open the audio source device :
if ((ad = ad_open_dev(mic_name, (int)cmd_ln_float32_r(config, "-samprate"))) == NULL)
E_FATAL("Failed to open audio device\n");
when I cross-compiled pulse-audio I used this set of preconfiguration :
I also tried to use alsalib without pulseaudio support to access to my device and it had succeed to get into it without the need of pulseaudio but the program it wasn't able to configure the sample Rate.
Does any one have an idea how to fix this ?
Last edit: Louwi 2014-05-05
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Hello everyone,
I had sucsesfully built an project based on pocketsphinx for home voice controle.
Now I'm trying to cross compile my project to work on OpenWRT Rt3883.
So is theire any one that had already cross compile the pocketsphinx and sphinxbase librarys for OpenWRT RT3883?
Yes, it's pretty straightforward, there is no specific issue. You can compile pocketpshinx and sphinxbase just like any automake-based project.
Should I execute the commands :
for Sphinxs base
./autogen.sh
./configure
for pocketsphinx
./configure
before running the cross-compilation chain-tool ?
Yes, and you need to specify the target architecture:
./configure --build=arm-something
I suggest you to check any manual on cross-compilation first
I notced that the makefile produced by the cros-compiling tool chaine and the one produced in my pc don't use the same libraries !
in my PC :
the one pruduced by the crosscompiling toolchaine :
How can I force the toolchaine to considerate thoses non used libraries -lpulse -lpulse-simple and other related changes ?
Last edit: Louwi 2014-04-07
That's ok, you probably don't need to use pulseaudio on your device. Is it supported at all there?
I don't understand "is it supported at all there?" !
Does pulseaudio run on your device?
no I didn't installed it yet !
I still have problem with the compiling toolchaine. cause it break at the end. just after compiling all codes it sucssed at creating the .o of all .c files but when creating the package it fail :/
I'm using OpenWRT SDK for cross-compiling. it provide a tool chaine with all prerecuired configuration.
If you can help me on telling me what is the source of the error I will be so thunkfull :)
here is my log file :
I get the log file by tupping this commade :
That command is supported by the OpenWRT SDK.
The log file don't containe any error or warning I chekked it.
the error and warning are showed on the Terminal :
In your sphinxbase openwrt package you have additional --disable-nls option to configure. You need to remove that option to not confuse configure.
In the future you can just look for files containing --disable-nls, it will give you the exact location for a trouble. If you know how to search inside files it can help you a lot.
thunk you a lot.
I will post how to fix this as soon as it work. may be some one else need it one day.
So I succed to remove that option "--disable-nls"
by modificate the file : "~/openwrt/rules.mk"
in fact I changed those lignes :
ifeq ($(CONFIG_ENABLE_LOCALE),true)
DISABLE_NLS:=--enable-nls
else
DISABLE_NLS:=--disable-nls
endif
to be ;
ifeq ($(CONFIG_ENABLE_LOCALE),true)
DISABLE_NLS:=
else
DISABLE_NLS:=
endif
so the worning " configure: WARNING: unrecognized options: --disable-nls" don't appear any more.
but the excution of
$make package/sphinxbase-0.8/compile V=99 > logfile.txt
always end with the same error.
here is the log file :
http://speedy.sh/hvFYP/logfile.txt
& here is the messages showed in the Terminal :
configure: WARNING: Disabling python since development headers were not found
install: omitting directory `/home/amir/Bureau/openwrt/build_dir/target-mipsel_r2_uClibc-0.9.32/sphinxbase-0.8'
make[2]: [/home/amir/Bureau/openwrt/bin/ramips/packages/sphinxbase-0.8_0.8-1_ramips.ipk] Error 1
make[1]: [package/sphinxbase-0.8/compile] Error 2
make: *** [package/sphinxbase-0.8/compile] Error 2
//for the first warning it's normal even when I compile the project for my PC it show and it end with succes.
when I excute { $./configure } manualy for my PC configuration this script show error and telling me
./configure: line 2116: config.log: Permission denied
./configure: line 2126: config.log: Permission denied
unless I excute it with root : { $sudo ./configure }
any way I don't think that this is the source of problem cause what is done in my pc when I excute the configure script with root is maked when the configure is excuted by the OpenWRT SDK.
problem had been solved.
it was this line in the makefile
$(PKG_BUILD_DIR) don't contain the sared libraries ".so" that had been cross-compiled.
infact the .so files are palced in the src directorie incide lib folders.
Hello everyone,
At this stage I succeed implementing the recognition program on my target "RT3883" OS OpenWRT, I installed pulse-audio deamon 5.0 and the tow libraries sphinxbase-0.8 and pocketsphinx-0.8.
the problem is that the program return error :
I get the name of the device by using this command :
searching for the source of the problem I noticed that pulseaudio is automatically killed when the program try to execute this line witch open the audio source device :
when I cross-compiled pulse-audio I used this set of preconfiguration :
I also tried to use alsalib without pulseaudio support to access to my device and it had succeed to get into it without the need of pulseaudio but the program it wasn't able to configure the sample Rate.
Does any one have an idea how to fix this ?
Last edit: Louwi 2014-05-05