unispeech / asterisk-unimrcp

UniMRCP modules for Asterisk
http://www.unimrcp.org/asterisk
GNU General Public License v2.0
48 stars 36 forks source link

asterisk module 1.5.1 not working for asterisk 16 #27

Closed DRoet closed 5 years ago

DRoet commented 5 years ago

Hi Arsen,

edit: sorry I just realised I posted this in the wrong repo (I think), so feel free to move the issue using the new github feature if possible

Any plans to support asterisk 16 anytime soon? I tried installing the asterisk module (1.5.1) with asterisk 16 and got the following error stack:

****************************** REPORT ******************************

Asterisk version.............. : 16.0.0
UniMRCP version............... : 1.5.0
UniMRCP modules version....... : 1.5.1

Compiler...................... : gcc
Compiler flags................ : -g -O2
Preprocessor definitions...... :
Linker flags.................. :

Modules install path...........: /usr/lib/asterisk/modules
Configuration install path.....: /etc/asterisk
XML doc install path...........: /var/lib/asterisk/documentation/thirdparty

Speech resource module.........: yes
Application module.............: yes

********************************************************************
Making all in res-speech-unimrcp
make[1]: Entering directory '/tmp/asterisk-unimrcp-1.5.1/res-speech-unimrcp'
  CC       res_speech_unimrcp.lo
In file included from /usr/include/asterisk.h:23:0,
                 from ../include/ast_compat_defs.h:30,
                 from res_speech_unimrcp.c:28:
res_speech_unimrcp.c: In function 'uni_recog_speech_result_build':
res_speech_unimrcp.c:778:27: error: 'Do_not_use_strdup__use_ast_strdup' undeclared (first use in this function)
     speech_result->text = strdup(text);
                           ^
res_speech_unimrcp.c:778:27: note: each undeclared identifier is reported only once for each function it appears in
Makefile:434: recipe for target 'res_speech_unimrcp.lo' failed
make[1]: Leaving directory '/tmp/asterisk-unimrcp-1.5.1/res-speech-unimrcp'
make[1]: *** [res_speech_unimrcp.lo] Error 1
Makefile:409: recipe for target 'all-recursive' failed
make: *** [all-recursive] Error 1

note: I tried the same thing on asterisk 15.6.1 and everything is working correctly

thank you,

Daan

achaloyan commented 5 years ago

Hi Daan,

This issue is addressed in https://github.com/unispeech/asterisk-unimrcp/commit/0d08443566a139bb9c735d62a889ad2340fb300b by using ast_strdup() instead of strdup(). The former is consistently available since Asterisk 1.8 at least.

UniMRCP modules now can be compiled as usual with Asterisk 16 too. I have not tried yet to run any tests, though.

Thanks,

DRoet commented 5 years ago

Hi Arsen,

I've tested the patch and it works! for what it is worth I've also used it together with the google dialogflow plugin and everything still works as expected.

Can we expect a patch release (1.5.2) soonish? I would rather use the tarball instead of pulling in the source directly

achaloyan commented 5 years ago

Hi Daan,

As you may have noticed, unimrcp-deps-1.6.0 was release yesterday. A new unimrcp-1.6.0 is coming up soon.

There are some changes that would need to be implemented in the Asterisk modules before publishing a new release. I cannot provide any strict timelines, but expect the release to be available sometime in December.

DRoet commented 5 years ago

Hi Arsen,

Thank you for the update, I appreciate the effort you put into this project

achaloyan commented 5 years ago

This issue has been addressed in Asterisk modules 1.5.2