speechd-discuss
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: How to migrate from module_speak to module_speak_sync?


From: Cameron Wong
Subject: Re: How to migrate from module_speak to module_speak_sync?
Date: Wed, 1 Dec 2021 13:36:34 +0800

Hello Samuel,

Your fix works! My module runs fine now. Thank you very much!

Cameron

Samuel Thibault <samuel.thibault@ens-lyon.org> 于2021年12月1日周三 上午8:12写道:
Cameron Wong, le lun. 29 nov. 2021 09:50:12 +0800, a ecrit:
>                  w module_speak
>                  w module_speak_sync
> 00000000002600c0 T _Z12module_speakPcm14SPDMessageType
> 0000000000209bc5 t _Z12module_speakPcm14SPDMessageType.cold

Ok, that's the kind of thing I was thinking of.

And indeed with C++, the new prototype

  int module_speak(const char *data, size_t bytes, SPDMessageType msgtype);

doesn't match the old prototype that you still use:

  int module_speak(gchar *data, size_t bytes, SPDMessageType msgtype) {

In C they are compatible, but in C++ they are different. And
unfortunately it seems that C++ insists on making your function a C++
function, not a C function, thus with name mangling, and thus the
missing weak reference to module_speak.

I have now fixed this in the master tree, please retry.

Samuel

reply via email to

[Prev in Thread] Current Thread [Next in Thread]