[zeromq-dev] Socket migration code on Mac OS X

Martin Sustrik sustrik at 250bpm.com
Mon Aug 30 09:21:41 CEST 2010


Douglas,

Thanks for reporting the problem!

> Has anyone tried the latest git master on Mac OS X?  It looks like the
> new socket migration code doesn't work — it would seem that sem_init()
> is stubbed out on Mac OS X.
>
> http://stackoverflow.com/questions/1413785/sem-init-on-os-x
>
> The result is an assertion failure:
>
>    Function not implemented
>    rc != -1 (semaphore.hpp:96)

This problem used to be solved, but with the changes in 2.1 it got 
unsolved :) I'll fix it shortly.

> Are there any easy alternatives that could be used instead of unnamed
> semaphores?  Maybe something silly like constructing a named semaphore
> from the process ID and the address of the semaphore_t object?  Or from
> a random UUID?

0mq needs only a dumb semaphore that can be simulated using mutex.

Martin



More information about the zeromq-dev mailing list