Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [paho-dev] iOS/OSX build/link flags

Hi Marcos,

thanks :-) 

The normal way of ignoring SIGPIPE, in Socket.c, is:


I don't remember the details exactly, but it seems this might not work on iOS.  An additional attempt is made by using the flag NOSIGPIPE, which calls:

setsockopt(*sock, SOL_SOCKET, SO_NOSIGPIPE, (void*)&opt, sizeof(opt))

on each socket additionally.  Of course, whether SIGPIPE is not a reliable event, so it's possible that routine tests will not encounter it.  Setting the -DNOSIGPIPE compile option should make sure that SIGPIPE is ignored - I don't see any negatives of including it.


On 05/11/14 14:25, Marcos Sánchez-Dehesa wrote:
I am building Paho for iOS applications (a static library) and another static library for the mac. I am a bit confuse with the building/linker flags needed.

In the repository's makefile, only -DUSE_NAMED_SEMAPHORES is used (among others such as -Os -fvisibility=hidden). However, reading the mailing list, Ian and Andy were using also -DNOSIGPIPE. What are the flags that I exactly need for iOS/OSX?

Thank you for the great job with Paho :)

paho-dev mailing list
To change your delivery options, retrieve your password, or unsubscribe from this list, visit


Back to the top