res_adsi fails to compile during make command

ktalbot
Joined: Sun 17 of Apr, 2011

res_adsi fails to compile during make command

Posted:Sun 17 of Apr, 2011 (20:09 UTC)
res_adsi.c line 362 fails to compile function ast_adsi_transmit_message_full

upgraded gcc from 4.1.2 to 4.6.0
gcc -v
Using built-in specs.
COLLECT_GCC=gcc
COLLECT_LTO_WRAPPER=/usr/local/libexec/gcc/i686-pc-linux-gnu/4.6.0/lto-wrapper
Target: i686-pc-linux-gnu
Configured with: ./configure
Thread model: posix
gcc version 4.6.0 (GCC) 
[root@asterisk ~]# 


Same error under gcc 4.1.2 as well, not a gcc problem.
The lines previous to this error complete successfully.

../res/res_adsi.o:/Asterisk/asterisk-1.8.3.2/res/res_adsi.c:362: first defined here
collect2: ld returned 1 exit status
make[1]: *** [asterisk] Error 1
make: *** [main] Error 2
[root@asterisk asterisk-1.8.3.2]# 


Installing Asterisk 1.8.3.2 from tarball 
./configure
make menuselect
                       -> application -> app_adsiprog
                       -> resource modules -> res_adsi

unselecting them or course allows the make command to complete successfully, however I used vim res_adsi.c to look at line 362, there does not appear to be a problem, but I am not a C/C++ developer so who knows except the developer or someone very good in C/C++.
make
make install
make samples
make config



The lines see up to make command failing on res_adsi are as follows, this is a snipit, far too many to list all of them.

This line of successful code for res_adsi is well before the error seen below
[CC] res_adsi.c -> res_adsi.o
In file included from res_adsi.c:45:0:
/Asterisk/asterisk-1.8.3.2/include/asterisk/module.h: In function ‘__backup_globals’:
/Asterisk/asterisk-1.8.3.2/include/asterisk/module.h:332:21: warning: taking address of expression of type ‘void’ [enabled by default]
/Asterisk/asterisk-1.8.3.2/include/asterisk/module.h:332:61: warning: taking address of expression of type ‘void’ [enabled by default]
/Asterisk/asterisk-1.8.3.2/include/asterisk/module.h:343:26: warning: taking address of expression of type ‘void’ [enabled by default]
/Asterisk/asterisk-1.8.3.2/include/asterisk/module.h: In function ‘__restore_globals’:
/Asterisk/asterisk-1.8.3.2/include/asterisk/module.h:350:21: warning: taking address of expression of type ‘void’ [enabled by default]
/Asterisk/asterisk-1.8.3.2/include/asterisk/module.h:350:61: warning: taking address of expression of type ‘void’ [enabled by default]
/Asterisk/asterisk-1.8.3.2/include/asterisk/module.h:351:20: warning: taking address of expression of type ‘void’ [enabled by default]
/Asterisk/asterisk-1.8.3.2/include/asterisk/module.h:351:59: warning: taking address of expression of type ‘void’ [enabled by default]
/Asterisk/asterisk-1.8.3.2/include/asterisk/module.h:354:10: warning: taking address of expression of type ‘void’ [enabled by default]
/Asterisk/asterisk-1.8.3.2/include/asterisk/module.h:359:9: warning: taking address of expression of type ‘void’ [enabled by default]
   [EMBED] res_adsi.o -> res_adsi.eo

************************************************************************************************************************
   [CC] recno/rec_open.c -> recno/rec_open.o
   [CC] recno/rec_put.c -> recno/rec_put.o
   [CC] recno/rec_search.c -> recno/rec_search.o
   [CC] recno/rec_seq.c -> recno/rec_seq.o
   [CC] recno/rec_utils.c -> recno/rec_utils.o
 [AR] hash/hash.o hash/hash_bigkey.o hash/hash_buf.o hash/hash_func.o hash/hash_log2.o hash/hash_page.o hash/ndbm.o btree/bt_close.o btree/bt_conv.o btree/bt_debug.o btree/bt_delete.o btree/bt_get.o btree/bt_open.o btree/bt_overflow.o btree/bt_page.o btree/bt_put.o btree/bt_search.o btree/bt_seq.o btree/bt_split.o btree/bt_utils.o db/db.o mpool/mpool.o recno/rec_close.o recno/rec_delete.o recno/rec_get.o recno/rec_open.o recno/rec_put.o recno/rec_search.o recno/rec_seq.o recno/rec_utils.o -> libdb1.a
   [LD] ../res/res_adsi.o abstract_jb.o acl.o alaw.o aoc.o app.o ast_expr2.o ast_expr2f.o asterisk.o astfd.o astmm.o astobj2.o audiohook.o autochan.o autoservice.o bridging.o callerid.o ccss.o cdr.o cel.o channel.o chanvars.o cli.o config.o data.o datastore.o db.o devicestate.o dial.o dns.o dnsmgr.o dsp.o enum.o event.o features.o file.o fixedjitterbuf.o frame.o framehook.o fskmodem.o global_datastores.o hashtab.o heap.o http.o image.o indications.o io.o jitterbuf.o loader.o lock.o logger.o manager.o md5.o netsock.o netsock2.o pbx.o plc.o poll.o privacy.o rtp_engine.o say.o sched.o security_events.o sha1.o slinfactory.o srv.o ssl.o stdtime/localtime.o strcompat.o strings.o stun.o syslog.o taskprocessor.o tcptls.o tdd.o term.o test.o threadstorage.o timing.o translate.o udptl.o ulaw.o utils.o version.o xml.o xmldoc.o editline/libedit.a db1-ast/libdb1.a ../addons/modules.link ../apps/modules.link ../bridges/modules.link ../cdr/modules.link ../channels/modules.link ../codecs/modules.link ../formats/modules.link ../funcs/modules.link ../pbx/modules.link ../res/modules.link -> asterisk
/usr/bin/ld: Dwarf Error: Abbrev offset (3112) greater than or equal to .debug_abbrev size (1358).
../res/res_adsi.eo: In function `ast_adsi_disconnect_session':
(.text+0x2fc0): multiple definition of `ast_adsi_disconnect_session'
../res/res_adsi.o:/Asterisk/asterisk-1.8.3.2/res/res_adsi.c:546: first defined here
../res/res_adsi.eo: In function `ast_adsi_get_cpeid':
(.text+0x30d0): multiple definition of `ast_adsi_get_cpeid'
../res/res_adsi.o:/Asterisk/asterisk-1.8.3.2/res/res_adsi.c:618: first defined here
../res/res_adsi.eo: In function `ast_adsi_download_connect':
(.text+0x2d50): multiple definition of `ast_adsi_download_connect'
../res/res_adsi.o:/Asterisk/asterisk-1.8.3.2/res/res_adsi.c:514: first defined here
../res/res_adsi.eo: In function `ast_adsi_transmit_message':
(.text+0x2b30): multiple definition of `ast_adsi_transmit_message'
../res/res_adsi.o:/Asterisk/asterisk-1.8.3.2/res/res_adsi.c:433: first defined here
../res/res_adsi.eo: In function `ast_adsi_load_soft_key':
(.text+0x2b70): multiple definition of `ast_adsi_load_soft_key'
../res/res_adsi.o:/Asterisk/asterisk-1.8.3.2/res/res_adsi.c:449: first defined here
../res/res_adsi.eo: In function `ast_adsi_set_keys':
(.text+0x3940): multiple definition of `ast_adsi_set_keys'
../res/res_adsi.o:/Asterisk/asterisk-1.8.3.2/res/res_adsi.c:893: first defined here
../res/res_adsi.eo: In function `ast_adsi_read_encoded_dtmf':
(.text+0x3020): multiple definition of `ast_adsi_read_encoded_dtmf'
../res/res_adsi.o:/Asterisk/asterisk-1.8.3.2/res/res_adsi.c:581: first defined here
../res/res_adsi.eo: In function `ast_adsi_get_cpeinfo':
(.text+0x3290): multiple definition of `ast_adsi_get_cpeinfo'
../res/res_adsi.o:/Asterisk/asterisk-1.8.3.2/res/res_adsi.c:649: first defined here
../res/res_adsi.eo: In function `ast_adsi_set_line':
(.text+0x39d0): multiple definition of `ast_adsi_set_line'
../res/res_adsi.o:/Asterisk/asterisk-1.8.3.2/res/res_adsi.c:909: first defined here
../res/res_adsi.eo: In function `ast_adsi_end_download':
(.text+0x2ae0): multiple definition of `ast_adsi_end_download'
../res/res_adsi.o:/Asterisk/asterisk-1.8.3.2/res/res_adsi.c:348: first defined here
../res/res_adsi.eo: In function `ast_adsi_print':
(.text+0x3b60): multiple definition of `ast_adsi_print'
../res/res_adsi.o:/Asterisk/asterisk-1.8.3.2/res/res_adsi.c:962: first defined here
../res/res_adsi.eo: In function `ast_adsi_download_disconnect':
(.text+0x3710): multiple definition of `ast_adsi_download_disconnect'
../res/res_adsi.o:/Asterisk/asterisk-1.8.3.2/res/res_adsi.c:788: first defined here
../res/res_adsi.eo: In function `ast_adsi_unload_session':
(.text+0x3fc0): multiple definition of `ast_adsi_unload_session'
../res/res_adsi.o:/Asterisk/asterisk-1.8.3.2/res/res_adsi.c:1021: first defined here
../res/res_adsi.eo: In function `ast_adsi_input_format':
(.text+0x3880): multiple definition of `ast_adsi_input_format'
../res/res_adsi.o:/Asterisk/asterisk-1.8.3.2/res/res_adsi.c:873: first defined here
../res/res_adsi.eo: In function `ast_adsi_begin_download':
(.text+0x2ea0): multiple definition of `ast_adsi_begin_download'
../res/res_adsi.o:/Asterisk/asterisk-1.8.3.2/res/res_adsi.c:326: first defined here
../res/res_adsi.eo: In function `ast_adsi_display':
(.text+0x3730): multiple definition of `ast_adsi_display'
../res/res_adsi.o:/Asterisk/asterisk-1.8.3.2/res/res_adsi.c:804: first defined here
../res/res_adsi.eo: In function `ast_adsi_query_cpeinfo':
(.text+0x3000): multiple definition of `ast_adsi_query_cpeinfo'
../res/res_adsi.o:/Asterisk/asterisk-1.8.3.2/res/res_adsi.c:571: first defined here
../res/res_adsi.eo: In function `ast_adsi_query_cpeid':
(.text+0x2fe0): multiple definition of `ast_adsi_query_cpeid'
../res/res_adsi.o:/Asterisk/asterisk-1.8.3.2/res/res_adsi.c:561: first defined here
../res/res_adsi.eo: In function `ast_adsi_input_control':
(.text+0x3810): multiple definition of `ast_adsi_input_control'
../res/res_adsi.o:/Asterisk/asterisk-1.8.3.2/res/res_adsi.c:850: first defined here
../res/res_adsi.eo: In function `ast_adsi_clear_screen':
(.text+0x36b0): multiple definition of `ast_adsi_clear_screen'
../res/res_adsi.o:/Asterisk/asterisk-1.8.3.2/res/res_adsi.c:746: first defined here
../res/res_adsi.eo: In function `ast_adsi_channel_restore':
(.text+0x3a20): multiple definition of `ast_adsi_channel_restore'
../res/res_adsi.o:/Asterisk/asterisk-1.8.3.2/res/res_adsi.c:940: first defined here
../res/res_adsi.eo: In function `ast_adsi_load_session':
(.text+0x3cf0): multiple definition of `ast_adsi_load_session'
../res/res_adsi.o:/Asterisk/asterisk-1.8.3.2/res/res_adsi.c:982: first defined here
../res/res_adsi.eo: In function `ast_adsi_data_mode':
(.text+0x3670): multiple definition of `ast_adsi_data_mode'
../res/res_adsi.o:/Asterisk/asterisk-1.8.3.2/res/res_adsi.c:716: first defined here
../res/res_adsi.eo: In function `ast_adsi_voice_mode':
(.text+0x36d0): multiple definition of `ast_adsi_voice_mode'
../res/res_adsi.o:/Asterisk/asterisk-1.8.3.2/res/res_adsi.c:770: first defined here
../res/res_adsi.eo: In function `ast_adsi_clear_soft_keys':
(.text+0x3690): multiple definition of `ast_adsi_clear_soft_keys'
../res/res_adsi.o:/Asterisk/asterisk-1.8.3.2/res/res_adsi.c:731: first defined here
../res/res_adsi.eo: In function `ast_adsi_available':
(.text+0x36f0): multiple definition of `ast_adsi_available'
../res/res_adsi.o:/Asterisk/asterisk-1.8.3.2/res/res_adsi.c:782: first defined here
../res/res_adsi.eo: In function `ast_adsi_connect_session':
(.text+0x2cc0): multiple definition of `ast_adsi_connect_session'
../res/res_adsi.o:/Asterisk/asterisk-1.8.3.2/res/res_adsi.c:490: first defined here
../res/res_adsi.eo: In function `ast_adsi_transmit_message_full':
(.text+0x25b0): multiple definition of `ast_adsi_transmit_message_full'
../res/res_adsi.o:/Asterisk/asterisk-1.8.3.2/res/res_adsi.c:362: first defined here
collect2: ld returned 1 exit status
make[1]: *** [asterisk] Error 1
make: *** [main] Error 2
[root@asterisk asterisk-1.8.3.2]# 



And of course the make command then errors out and Asterisk fails to build properly.