[Freeswitch-users] FreeSWITCH, OSX, Libtool, Macports
darius at dons.net.au
Wed Jun 20 12:05:48 MSD 2012
On 20/06/2012, at 3:51, Terry Barnum wrote:
> So I did a make clean and ran your env line and then make. I think it got further but fails on mod_spandsp_la-mod_spandsp_fax.lo
> Creating mod_spandsp_la-mod_spandsp_fax.lo
> quiet_libtool: compile: gcc -DHAVE_CONFIG_H -I. -I../../../../src/include -I../../../../libs/xmlrpc-c -I/usr/local/src/freeswitch/libs/curl/include -I/usr/local/src/freeswitch/src/include -I/usr/local/src/freeswitch/src/include -I/usr/local/src/freeswitch/libs/libteletone/src -fPIC -fvisibility=hidden -DSWITCH_API_VISIBILITY=1 -DHAVE_VISIBILITY=1 -I/opt/local/include -I/usr/local/src/freeswitch/libs/curl/include -I/usr/local/src/freeswitch/src/include -I/usr/local/src/freeswitch/src/include -I/usr/local/src/freeswitch/libs/libteletone/src -Werror -fvisibility=hidden -DSWITCH_API_VISIBILITY=1 -DHAVE_VISIBILITY=1 -g -ggdb -DMACOSX -DHAVE_OPENSSL -Wall -std=c99 -pedantic -Wdeclaration-after-statement -I/usr/local/src/freeswitch/libs/spandsp/src -I/usr/local/src/freeswitch/libs/tiff-3.8.2/libtiff -I/usr/local/src/freeswitch/libs/spandsp/src -I/usr/local/src/freeswitch/libs/tiff-3.8.2/libtiff -I. -g -O2 -pipe -no-cpp-precomp -MT mod_spandsp_la-mod_spandsp_fax.lo -MD -MP -MF .deps/mod_spandsp_la-mod_spandsp_fax.Tpo -c mod_spandsp_fax.c -fno-common -DPIC -o .libs/mod_spandsp_la-mod_spandsp_fax.o
> cc1: warnings being treated as errors
> mod_spandsp_fax.c: In function 'spanfax_init':
> mod_spandsp_fax.c:716: warning: passing argument 2 of 'span_log_set_message_handler' from incompatible pointer type
> mod_spandsp_fax.c:716: error: too many arguments to function 'span_log_set_message_handler'
> mod_spandsp_fax.c:717: warning: passing argument 2 of 'span_log_set_message_handler' from incompatible pointer type
> mod_spandsp_fax.c:717: error: too many arguments to function 'span_log_set_message_handler'
> mod_spandsp_fax.c:772: warning: passing argument 2 of 'span_log_set_message_handler' from incompatible pointer type
> mod_spandsp_fax.c:772: error: too many arguments to function 'span_log_set_message_handler'
> mod_spandsp_fax.c:773: warning: passing argument 2 of 'span_log_set_message_handler' from incompatible pointer type
I think this is because you have spandsp installed in MacPorts and those includes are being used in preference to the ones in libs/spandsp/..
I think to work around this I just removed spandsp while I built freeswitch (bleh).
IMO the "right" solution is to rename spandsp in freeswitch - it has been modified (looking at the git log) so it is really a fork of the original. That is unless those patches get merged back into spandsp and then macports can get an updated one.
The later solution is still pretty bad though unless there is a way to force freeswitch to not look at the bundled version.
There is a similar problem with portaudio although since it has a stable API it doesn't show up. It doesn't however build on OSX (Intel 10.7 anyway) and in the end I hacked src/mod/endpoint/mod_portaudio to use pkg-config to find the right CFLAGS and LIBS to link to it.
Daniel O'Connor software and network engineer
for Genesis Software - http://www.gsoft.com.au
"The nice thing about standards is that there
are so many of them to choose from."
-- Andrew Tanenbaum
GPG Fingerprint - 5596 B766 97C0 0E94 4347 295E E593 DC20 7B3F CE8C
Join us at ClueCon 2011 Aug 9-11, 2011
More information about the FreeSWITCH-users