From: Michael Rys <rys@acm.org>
Subject: pthread_mutex across process boundaries
Date: 1997/06/02 [thread overview]
Message-ID: <3393445C.41C6@acm.org> (raw)
I need to port a Sun Solaris program (C/C++) to a DEC OSF1 environment.
The Sun version uses Sun's mutex_init(&sem, USYNC_PROCESS) which allows
to use the
mutex in shared memory between to processes. Newer versions of Solaris
now support
POSIX's pthread_mutex_init without losing any functionality.
Fine, I thought to myself, both OS are POSIX compliant so it should be
no problem
to port. Wrong! pthread.h on OSF1 has different calls (and even worse),
does not
seem to provide the inter-process functionality...
So I have the following questions to the experts:
1. How do I get the mutex behaviour on OSF1 for Sun's mutex_init(&sem,
USYNC_PROCESS)?
2. Is there some predefined compilation flag which tells my compiler
(g++), if I am
running OSF (similar to IBM's _AIX)? I tried __OSF__, __OSF1__ and
_OSF_SOURCE -
none worked.
Any help is greatly appreciated.
Michael
--
Michael Rys Database Group Stanford University
rys@acm.org
P: +1 415 725 0177 - F: +1 415 725 2588 -
http://www.inf.ethz.ch/personal/rys
-- Wovon man nicht sprechen kann, darueber muss man schweigen. --
Ludwig Wittgenstein, Tractatus logico-philosophicus
next reply other threads:[~1997-06-02 4:00 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
1997-06-02 4:00 Michael Rys [this message]
1997-06-04 4:00 ` pthread_mutex across process boundaries Dave Butenhof
read-only archive
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox