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

Re: [reSIProcate-users] Compiling resiprocate on iOS


Learn the resiprocate architecture before.

https://www.resiprocate.org/Design_and_Implementation

And especially:
https://www.resiprocate.org/Why_Asynchronous_DNS


On Fri, Nov 24, 2017 at 2:28 PM, Francesco Lamonica
<alienpenguin@xxxxxxxxx> wrote:
> I'll double check the makefile generated by configure, however, why is
> c-ares needed? doesn't resipares work on iOS?
>
> On Fri, Nov 24, 2017 at 6:28 AM, Dmytro Bogovych <dmytro.bogovych@xxxxxxxxx>
> wrote:
>>
>> Did you include ares source files at all ?
>>
>> On Fri, Nov 24, 2017 at 4:43 AM, Francesco Lamonica
>> <alienpenguin@xxxxxxxxx> wrote:
>> > Hi all,
>> > upon Dmytro suggestion i changed a bit DnsUtil to return localhost,
>> > but i still get the assert failure in SipStack::getHostAddress()
>> >
>> > i tried recompiling resiprocate with -DUSE_CARES as per Dmytro
>> > suggestion,
>> > however i get some compilation error :
>> >
>> > dns/AresDns.cxx:369:61: error: member access into incomplete type
>> > 'ares_channeldata'
>> >
>> >
>> > any ideas?
>> >
>> >
>> > On Thu, Nov 23, 2017 at 6:02 PM, Dmytro Bogovych
>> > <dmytro.bogovych@xxxxxxxxx>
>> > wrote:
>> >>
>> >> Talking about problem in DnsUtil.cxx.
>> >> I did see the same problem.
>> >>
>> >> I use #ifdef-ed minor modification of DnsUtil::getLocalHostName()
>> >> which does return "localhost" name. Nothing more.
>> >>
>> >> I did see similar problem for iOS / Android /  W10(UWP) - sometimes
>> >> this API is slow or bugging, especially after network changes.
>> >>
>> >> About SipStack::getHostAddress() - I'm not sure - please check if you
>> >> have USE_CARES #define. It is must have definition if you want to use
>> >> DNS in async way.
>> >>
>> >>
>> >>
>> >>
>> >> On Thu, Nov 23, 2017 at 7:07 PM, Francesco Lamonica
>> >> <alienpenguin@xxxxxxxxx> wrote:
>> >> > Hi Dmytro, thanks for your reply and your insight about the socket (i
>> >> > knew
>> >> > about that :) )
>> >> > however i noticed an issue with resiprocate on iOS
>> >> >
>> >> > when i run my app on the simulator all goes well, however when i run
>> >> > it
>> >> > on a
>> >> > real iOS (10.x) device (either iphone or ipad) i get an error on
>> >> > DnsUtils.cxx : 176
>> >> >
>> >> > Couldn't determine local hostname. Error was: nodename nor servname
>> >> > provided, or not known. Returning empty string
>> >> >
>> >> > and then (i don't know if related) an assertion in SipStack.cxx: 769
>> >> >
>> >> > ERR | 20171123-170235.228 | | RESIP | 0x16e49b000 | SipStack.cxx:768
>> >> > |
>> >> > gethostbyname failed, returning "127.0.0.1"
>> >> >
>> >> > Assertion failed: (0), function getHostAddress, file SipStack.cxx,
>> >> > line
>> >> > 769.
>> >> >
>> >> >
>> >> >
>> >> > Does anyone know about why that's happening?
>> >> >
>> >> >
>> >> > On Sat, Nov 18, 2017 at 3:46 PM, Dmytro Bogovych
>> >> > <dmytro.bogovych@xxxxxxxxx>
>> >> > wrote:
>> >> >>
>> >> >> Nothing too much special.
>> >> >>
>> >> >> I think the biggest thing is iOS special requirements for VoIP
>> >> >> applications.
>> >> >> You can't expect iOS will retain TCP/TLS connection in background.
>> >> >>
>> >> >> See Apple's doc:
>> >> >>
>> >> >>
>> >> >>
>> >> >> https://developer.apple.com/library/content/documentation/Performance/Conceptual/EnergyGuide-iOS/OptimizeVoIP.html
>> >> >>
>> >> >>
>> >> >> On Fri, Nov 17, 2017 at 3:30 AM, Francesco Lamonica
>> >> >> <alienpenguin@xxxxxxxxx> wrote:
>> >> >> > Hi all,
>> >> >> > i am wondering if there is any special care that should be taken
>> >> >> > when
>> >> >> > compiling for iOS.
>> >> >> >
>> >> >> > i.e. i see in compat.hxx that there is some code definition
>> >> >> > enclosed
>> >> >> > in
>> >> >> > TARGET_IPHONE_OS
>> >> >> > Should that be defined when compiling it?
>> >> >> >
>> >> >> > Beacuse when i try to link my application to the ios libraries i
>> >> >> > get
>> >> >> > an
>> >> >> > undefined symbol errors regarding resip::Data::copy(const char*,
>> >> >> > unsigned
>> >> >> > long) and resip::Data(const char*, unsigned long)
>> >> >> >
>> >> >> > with nm i noticed that in librutil.a i can see the symbols for
>> >> >> > those
>> >> >> > functions defined for unsigned int, NOT long
>> >> >> >
>> >> >> > So, for some reasons my code when compiling and including
>> >> >> > resiprocate
>> >> >> > includes UInt32 seems to match unsigned long, but my IDE seems to
>> >> >> > point
>> >> >> > to
>> >> >> > unsigned int.
>> >> >> >
>> >> >> > Can anyone suggest me something?
>> >> >> >
>> >> >> > _______________________________________________
>> >> >> > resiprocate-users mailing list
>> >> >> > resiprocate-users@xxxxxxxxxxxxxxx
>> >> >> > List Archive:
>> >> >> > http://list.resiprocate.org/archive/resiprocate-users/
>> >> >> >
>> >> >
>> >> >
>> >
>> >
>
>