< Previous by Date Date Index Next by Date >
< Previous in Thread Thread Index  

Re: [reSIProcate-users] Linker errors when linking with resip


Sure thing.

By the way, if you plan to use any of the other major libraries within resip, here's what the link-time dependencies appear to be at the moment:



/a

On 12/18/08 3:47 PM, Andrew Wood wrote:
Brilliant it was the ordering. Thanks Adam



Adam Roach wrote:
Andrew:

As you mentioned, libares is built by the project itself. (It's an asynchronous DNS resolver library).

Librutil is a set of common utility classes used by various resiprocate subprojects. It uses libares.

Libresip is, as you've guessed, the SIP stack itself. It uses librutil (and, transitively, libares).

Libdum is the Dialog Usage Manager, which abstracts many User Agent behaviors into a higher level than SIP transactions. If you're creating a SIP User Agent, you'll want to use DUM. Libdum uses libresip and librutil.

In most cases, link errors like you're getting come from order of library inclusion. On your link line, you'll want to make sure the libraries are included in the following order: libdum, libresip, librutil, libares.

/a

Andrew Wood wrote:
Ive built the library and ended up with 4 .a files: libares libdum libresip and librutil.

I guess the bulk of the stack is in libresip but what are the others. Ive tried linking against them all but Im getting errors such as:

../lib/resiprocate-1.4.1/lib/lib/libresip.a(DnsResult.o): In function `resip::DnsResult::skipDNSQuestion(unsigned char const*, unsigned char const*, int)':
/home/andrew/xswitch/lib/resiprocate-1.4.1/resip/stack/DnsResult.cxx:679: undefined reference to `ares_expand_name'
../lib/resiprocate-1.4.1/lib/lib/librutil.a(DnsHostRecord.o): In function `DnsHostRecord':
/home/andrew/xswitch/lib/resiprocate-1.4.1/rutil/dns/DnsHostRecord.cxx:31: undefined reference to `ares_expand_name'
/home/andrew/xswitch/lib/resiprocate-1.4.1/rutil/dns/DnsHostRecord.cxx:31: undefined reference to `ares_expand_name'
../lib/resiprocate-1.4.1/lib/lib/librutil.a(DnsNaptrRecord.o): In function `DnsNaptrRecord':
/home/andrew/xswitch/lib/resiprocate-1.4.1/rutil/dns/DnsNaptrRecord.cxx:100: undefined reference to `ares_expand_name'
/home/andrew/xswitch/lib/resiprocate-1.4.1/rutil/dns/DnsNaptrRecord.cxx:140: undefined reference to `ares_expand_name'
../lib/resiprocate-1.4.1/lib/lib/librutil.a(DnsNaptrRecord.o):/home/andrew/xswitch/lib/resiprocate-1.4.1/rutil/dns/DnsNaptrRecord.cxx:100: more undefined references to `ares_expand_name' follow
../lib/resiprocate-1.4.1/lib/lib/librutil.a(AresDns.o): In function `resip::AresDns::lookup(char const*, unsigned short, resip::ExternalDnsHandler*, void*)':
/home/andrew/xswitch/lib/resiprocate-1.4.1/rutil/dns/AresDns.cxx:276: undefined reference to `ares_query'

Which suggests to me libares.a isnt being found? Though Im not sure what libares is and a Google search didnt enlighten me.
Which ones do I need to link against, am I missing something?

Thanks
Andrew

_______________________________________________
resiprocate-users mailing list
resiprocate-users@xxxxxxxxxxxxxxx
List Archive: http://list.resiprocate.org/archive/resiprocate-users/


______________________________________________________________________
This email has been scanned by the MessageLabs Email Security System.
For more information please visit http://www.messagelabs.com/email ______________________________________________________________________

_______________________________________________
resiprocate-users mailing list
resiprocate-users@xxxxxxxxxxxxxxx
List Archive: http://list.resiprocate.org/archive/resiprocate-users/