[asterisk-dev] Asterisk API

José Pablo Fernández pablo.fernandez at rs.com.ar
Mon Jan 15 11:35:22 MST 2007


Hello,
There's an Asterisk function to copy strings, ast_strdup which I tried to use. 
It is actually a macro that calls the real function which is _ast_strdup, 
both declared and defined on include/asterisk/utils.h around line 412.
The function _ast_strdup is defined inside AST_INLINE_API which according to 
its documentation:

 there must _always_ be a non-inlined version of the function available for 
modules compiled out of the tree to link to

but it seems there isn't a non-inlined version in the asterisk binary:

pupeno at plab:~/asterisk/asterisk-1.4$ nm main/asterisk | grep ast_strdup
080739b3 T __ast_strdup

Am I missing something ? My module ends up with this error:

asterisk: symbol lookup error: /usr//lib/asterisk/modules/account.so: 
undefined symbol: _ast_strdup

Thank you.
-- 
José Pablo Fernández
pablo.fernandez at rs.com.ar


More information about the asterisk-dev mailing list