[Freeswitch-users] Failed to compile sofia.c for ARM

Anthony Minessale anthony.minessale at gmail.com
Mon Jul 5 06:37:09 PDT 2010


usually va_list is expressed externally as void *

Is this the only place with an error?
try altering the code so the if and else is replaced by just the contents of
the if. ie the switch va_sprintf line



On Sat, Jul 3, 2010 at 7:43 PM, mazilo <Nabble at slickdeals.endjunk.com>wrote:

>
> I tried to compile freeswitch-1.0.6 on OpenWRT for a Marvell Kirkwood (ARM)
> platform to no avail. The same source codes compiled just fine for a
> Broadcomm (MIPS/MIPS32) platform. What fails to compile is the source code
> of sofia.c at line 1574 with the following error messages:
>
> ++++++++++++++++++++++++++
> make[8]: Entering directory
>
> `/opt/tmp/openwrt-svn-trunk-ARM/build_dir/target-arm_v5te_uClibc-0.9.30.2_eabi/freeswitch-1.0.6/src/mod/endpoints/mod_sofia'
> Creating mod_sofia_la-mod_sofia.lo
> mkdir .libs
> Compiling mod_sofia.c ...
> Creating mod_sofia_la-sofia.lo
> Compiling sofia.c ...
> sofia.c: In function 'logger':
> sofia.c:1574: error: used struct type value where scalar is required
> make[8]: *** [mod_sofia_la-sofia.lo] Error 1
> make[8]: Leaving directory
>
> `/opt/tmp/openwrt-svn-trunk-ARM/build_dir/target-arm_v5te_uClibc-0.9.30.2_eabi/freeswitch-1.0.6/src/mod/endpoints/mod_sofia'
> make[7]: *** [all] Error 2
> make[7]: Leaving directory
>
> `/opt/tmp/openwrt-svn-trunk-ARM/build_dir/target-arm_v5te_uClibc-0.9.30.2_eabi/freeswitch-1.0.6/src/mod/endpoints/mod_sofia'
> make[6]: *** [mod_sofia-all] Error 1
> make[6]: Leaving directory
>
> `/opt/tmp/openwrt-svn-trunk-ARM/build_dir/target-arm_v5te_uClibc-0.9.30.2_eabi/freeswitch-1.0.6/src/mod'
> make[5]: *** [all-recursive] Error 1
> make[5]: Leaving directory
>
> `/opt/tmp/openwrt-svn-trunk-ARM/build_dir/target-arm_v5te_uClibc-0.9.30.2_eabi/freeswitch-1.0.6/src'
> ++++++++++++++++++++++++++
>
> The pertaining sofia.c source code at line 1574 is shown below:
>
> ++++++++++++++++++++++++++
> 1569 static void logger(void *logarg, char const *fmt, va_list ap)
> 1570 {
> 1571         if (!fmt)
> 1572                 return;
> 1573
> 1574         if (ap) {
> 1575                 switch_log_vprintf(SWITCH_CHANNEL_LOG_CLEAN,
> mod_sofia_glob     als.tracelevel, fmt, ap);
> 1576         } else {
> 1577                 switch_log_printf(SWITCH_CHANNEL_LOG_CLEAN,
> mod_sofia_globa     ls.tracelevel, "%s", fmt);
> 1578         }
> 1579 }
> ++++++++++++++++++++++++++
>
> I am no programmer; however, isn't va_list ap indicates ap is a struct type
> value while the if(ap) expects ap to be a scalar value? If so, why sofia.c
> doesn't fail to compile for a MIPS/MIPS32 platform but fails to compile for
> an ARM platform? That said, how does one go about to fix this so that
> sofia.c source will compile cleanly on both platforms?
>
> Thanks.
> --
> View this message in context:
> http://freeswitch-users.2379917.n2.nabble.com/Failed-to-compile-sofia-c-for-ARM-tp5252219p5252219.html
> Sent from the freeswitch-users mailing list archive at Nabble.com.
>
> _______________________________________________
> FreeSWITCH-users mailing list
> FreeSWITCH-users at lists.freeswitch.org
> http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
> UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
> http://www.freeswitch.org
>



-- 
Anthony Minessale II

FreeSWITCH http://www.freeswitch.org/
ClueCon http://www.cluecon.com/
Twitter: http://twitter.com/FreeSWITCH_wire

AIM: anthm
MSN:anthony_minessale at hotmail.com <MSN%3Aanthony_minessale at hotmail.com>
GTALK/JABBER/PAYPAL:anthony.minessale at gmail.com<PAYPAL%3Aanthony.minessale at gmail.com>
IRC: irc.freenode.net #freeswitch

FreeSWITCH Developer Conference
sip:888 at conference.freeswitch.org <sip%3A888 at conference.freeswitch.org>
googletalk:conf+888 at conference.freeswitch.org<googletalk%3Aconf%2B888 at conference.freeswitch.org>
pstn:+19193869900
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.freeswitch.org/pipermail/freeswitch-users/attachments/20100705/9983674d/attachment.html 


More information about the FreeSWITCH-users mailing list