Boost logo

Boost Users :

From: Ion Gaztañaga (igaztanaga_at_[hidden])
Date: 2007-11-25 06:18:42


Stefan Arentz escribió:
> I checked out boost trunk from svn and tried to compile a simple
> boost.interprocess example. Unfortunately it fails at a rather
> unexpected place:
>
> % c++ doc_message_queueA.cpp -Itrunk -o doc_message_queueA
> % ./doc_message_queueA
> Assertion failed: (res == 0), function lock, file
> trunk/boost/interprocess/sync/posix/interprocess_mutex.hpp, line 116.
> zsh: abort ./a
>
> The error code is 22, EINVAL.
>
> I'm on OS X 10.5.1, maybe that is too new, or not yet tested?

It is not tested but your problem and another problem reported a couple
of weeks ago are pretty strange. If Leopard now offers process-shared
posix mutexes and native shared memory, in theory Interprocess code
should work without problems, just like other Unixes, but I don't know
what's happening.

I don't have access to the OS so I'll need some help to fix these
issues. Meanwhile, try to undef BOOST_INTERPROCESS_POSIX_PROCESS_SHARED
define <boost/interprocess/detail/workaround.hpp> line 21. This will
avoid native process-shared mutexes and conditions and Interprocess will
work as in Mac Os 10.4

Regards,

Ion


Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net