[asterisk-users] app_swift w/ Asterisk 14
Brent Davidson
brent at texascountrytitle.com
Fri Feb 3 14:16:26 CST 2017
Trying to compile app_swift with Asterisk 14.2.1 and getting the
following. Can anybody tell me what I'm missing?:
[root at localhost app_swift-master]# make
_ ___
(_) / __) _
_____ ____ ____ ___ _ _ _ _ _| |__ _| |_
(____ | _ \| _ \ /___) | | | (_ __|_ _)
/ ___ | |_| | |_| | ____ |___ | | | | | | | | |_
\_____| __/| __/ (____) |___/ \___/|_| |_| \__)
|_| |_|
gcc -I/opt/swift/include -I/usr/include -g -Wall -fPIC -D_SWIFT_VER_6
-D_AST_VER_14 -c -o app_swift.o app_swift.c
In file included from app_swift.c:33:0:
/usr/include/asterisk.h:300:2: error: #error "Externally compiled
modules must declare AST_MODULE_SELF_SYM."
#error "Externally compiled modules must declare AST_MODULE_SELF_SYM."
^
app_swift.c:34:1: error: expected declaration specifiers or ‘...’ before
string constant
ASTERISK_FILE_VERSION(__FILE__, "$Revision: 304000 $")
^
app_swift.c:34:33: error: expected declaration specifiers or ‘...’
before string constant
ASTERISK_FILE_VERSION(__FILE__, "$Revision: 304000 $")
^
In file included from app_swift.c:36:0:
/opt/swift/include/swift.h:392:1: error: unknown type name ‘swift_voice’
swift_voice * SWIFT_CALLCONV
^
/opt/swift/include/swift.h:405:1: error: unknown type name ‘swift_voice’
swift_voice * SWIFT_CALLCONV swift_port_find_next_voice(swift_port *port);
^
/opt/swift/include/swift.h:415:1: error: unknown type name ‘swift_voice’
swift_voice * SWIFT_CALLCONV swift_port_rewind_voices(swift_port *port);
^
/opt/swift/include/swift.h:426:52: error: unknown type name ‘swift_voice’
swift_voice *voice);
^
/opt/swift/include/swift.h:437:1: error: unknown type name ‘swift_voice’
swift_voice * SWIFT_CALLCONV swift_port_set_voice_by_name(swift_port
*port,
^
/opt/swift/include/swift.h:448:1: error: unknown type name ‘swift_voice’
swift_voice * SWIFT_CALLCONV swift_port_set_voice_from_dir(swift_port
*port,
^
/opt/swift/include/swift.h:459:1: error: unknown type name ‘swift_voice’
swift_voice * SWIFT_CALLCONV swift_port_get_current_voice(swift_port
*port);
^
/opt/swift/include/swift.h:486:55: error: unknown type name ‘swift_voice’
const char * SWIFT_CALLCONV swift_voice_get_attribute(swift_voice *voice,
^
/opt/swift/include/swift.h:502:28: error: unknown type name ‘swift_voice’
swift_voice_get_attributes(swift_voice *voice, swift_params *out_params);
^
/opt/swift/include/swift.h:517:56: error: unknown type name ‘swift_voice’
swift_result_t SWIFT_CALLCONV swift_voice_load_lexicon(swift_voice *voice,
^
app_swift.c:296:1: error: expected identifier or ‘(’ before ‘{’ token
{
^
app_swift.c:461:2: warning: data definition has no type or storage class
[enabled by default]
res = 0;
^
app_swift.c:461:2: warning: type defaults to ‘int’ in declaration of
‘res’ [-Wimplicit-int]
app_swift.c:467:2: warning: data definition has no type or storage class
[enabled by default]
next = ast_tvadd(ast_tvnow(), ast_tv(0, 100000));
^
app_swift.c:467:2: warning: type defaults to ‘int’ in declaration of
‘next’ [-Wimplicit-int]
app_swift.c:467:9: error: incompatible types when initializing type
‘int’ using type ‘struct timeval’
next = ast_tvadd(ast_tvnow(), ast_tv(0, 100000));
^
app_swift.c:469:2: error: expected identifier or ‘(’ before ‘while’
while (swift_generator_running(ps)) {
^
app_swift.c:596:2: error: expected identifier or ‘(’ before ‘if’
if (alreadyran == 0 && timeout > 0 && max_digits > 0) {
^
app_swift.c:605:2: error: expected identifier or ‘(’ before ‘if’
if (max_digits >= 1 && results != NULL) {
^
app_swift.c:632:2: error: expected identifier or ‘(’ before ‘}’ token
}
^
app_swift.c:634:11: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or
‘__attribute__’ before ‘:’ token
exception:
^
app_swift.c:639:2: error: expected identifier or ‘(’ before ‘if’
if (engine != NULL) {
^
app_swift.c:642:2: error: expected identifier or ‘(’ before ‘if’
if (ps && ps->q) {
^
app_swift.c:646:2: error: expected identifier or ‘(’ before ‘if’
if (ps) {
^
app_swift.c:664:2: warning: parameter names (without types) in function
declaration [enabled by default]
ast_module_user_remove(u);
^
In file included from app_swift.c:45:0:
app_swift.c:664:2: error: conflicting types for ‘__ast_module_user_remove’
ast_module_user_remove(u);
^
/usr/include/asterisk/module.h:342:6: note: previous declaration of
‘__ast_module_user_remove’ was here
void __ast_module_user_remove(struct ast_module *, struct
ast_module_user *);
^
app_swift.c:665:2: error: expected identifier or ‘(’ before ‘return’
return res;
^
app_swift.c:666:1: error: expected identifier or ‘(’ before ‘}’ token
}
^
In file included from app_swift.c:45:0:
app_swift.c: In function ‘unload_module’:
app_swift.c:673:2: error: ‘AST_MODULE_SELF’ undeclared (first use in
this function)
ast_module_user_hangup_all();
^
app_swift.c:673:2: note: each undeclared identifier is reported only
once for each function it appears in
app_swift.c: In function ‘load_module’:
app_swift.c:700:29: warning: statement with no effect [-Wunused-value]
AST_MODULE_LOAD_DECLINE : AST_MODULE_LOAD_SUCCESS;
^
app_swift.c:700:3: warning: label ‘AST_MODULE_LOAD_DECLINE’ defined but
not used [-Wunused-label]
AST_MODULE_LOAD_DECLINE : AST_MODULE_LOAD_SUCCESS;
^
make: *** [app_swift.o] Error 1
[root at localhost app_swift-master]#
More information about the asterisk-users
mailing list