[Freeswitch-users] Javascript & cURL: Error loading CURL

Birgit Arkesteijn birgit at westhawk.co.uk
Wed Nov 5 04:09:30 PST 2008


I realised the curl-devel package wasn't installed.
Now mod_xml_curl won't compile. :-(

I'm running Suse Linux 10.0, x86_64, GNU/Linux.
I installed the curl-devel package from the original suse DVD.
I ran 'configure' again, to make sure FreeSWITCH picks up on the change(s).
I ran 'make current' again and get the following errors:

make[6]: Entering directory 
Compiling mod_xml_curl.c...
mod_xml_curl.c: In function ‘do_config’:
mod_xml_curl.c:265: error: syntax error before ‘;’ token
cc1: warnings being treated as errors
mod_xml_curl.c:245: warning: unused variable ‘hash_node’
mod_xml_curl.c:239: warning: unused variable ‘bname’
mod_xml_curl.c:280: error: ‘url’ undeclared (first use in this function)
mod_xml_curl.c:280: error: (Each undeclared identifier is reported only once
mod_xml_curl.c:280: error: for each function it appears in.)
mod_xml_curl.c:284: error: continue statement not within a loop
mod_xml_curl.c:296: error: ‘bind_mask’ undeclared (first use in this 
mod_xml_curl.c:300: error: ‘bind_cred’ undeclared (first use in this 
mod_xml_curl.c:304: error: ‘disable100continue’ undeclared (first use in 
this function)
mod_xml_curl.c:305: error: ‘ignore_cacert_check’ undeclared (first use 
in this function)
mod_xml_curl.c:310: error: ‘hash_node’ undeclared (first use in this 
mod_xml_curl.c:310: warning: left-hand operand of comma expression has 
no effect
mod_xml_curl.c:327: error: ‘bname’ undeclared (first use in this function)
mod_xml_curl.c: At top level:
mod_xml_curl.c:333: error: syntax error before ‘:’ token
mod_xml_curl.c:235: error: label ‘done’ used but not defined

I noticed that FreeSWITCH contains curl code under libs/.
Did I do the right thing by installing the curl-devel package?
If so, could someone please help with the errors above? Thanks.

BTW, I'm a bit puzzled as to why mod_xml_cdr could be build previously. 
I thought it used curl, but it's not in the dependencies page - 
http://wiki.freeswitch.org/wiki/FreeSwitch_Dependencies, so maybe I'm wrong.

Thanks, Birgit

On 05/11/08 11:00, Birgit Arkesteijn wrote:
> Hi,
> I've spent yesterday afternoon in vain trying to load CURL in 
> javascript, so here I'm again begging for help.
> The modules doesn't load successfully:
> [ERR] mod_spidermonkey.c:3303 js_api_use() Error loading CURL
> We do use mod_xml_curl successfully, btw.
> Things I tried:
> - I added to the file "modules.conf" the line:
>    languages/mod_spidermonkey_curl.
>    (This line was not in the build/modules.conf.in, btw).
> - In the same file, I commented out mod_spidermonkey_teletone,
>    mod_spidermonkey_core_db and mod_spidermonkey_socket, since I don't
>    think I need them.
> - I run "make current"
> I'm running now version 597:10239M
> Doing a find on /usr/local/freeswitch for 'curl', shows the following:
> % find . -name \*curl\*
> ./mod/mod_spidermonkey_curl.so
> ./mod/mod_xml_curl.so
> ./conf/autoload_configs/xml_curl.conf.xml
> The javascript I'm running is copied from the example on page 
> http://wiki.freeswitch.org/wiki/Run
> Any suggestions?
> Thanks, Birgit

-- Birgit Arkesteijn, birgit at westhawk.co.uk,
-- Westhawk Ltd, Albion Wharf, 19 Albion Street, Manchester M1 5LN, UK
-- Company no: 1769350
-- Registered Office:
-- 15 London Road, Stockton Heath, Warrington WA4 6SJ. UK.
-- tel.: +44 (0)161 237 0660
-- <URL: http://www.westhawk.co.uk>

More information about the FreeSWITCH-users mailing list