954,498 Members — Technology Publication meets Social Media
Username:
Password:
Lost login information?
Have something to say? Contribute New Article Reply to this Article

System V to POSIX Semaphore Wrapper

Hi,

As part of porting a (mostly C++) library[1] to a "new" operating system[2], I'm trying to link the library's semaphore class to the platform's semaphore implementation. The problem is that the library assumes that the semaphore implementation will be a modern POSIX one[3] but the operating system's semaphores are modeled after System V[4].

My question is primarily if anyone knows of a wrapper of C (or C++) code that will act as an emulation layer around the System V semaphores in a way that will present "modern" POSIX semaphores to the library I'm porting. A caveat is that any used code must be compatible with the BSD license.

Thank you,
pikpik


1. The library, semaphore example

http://code.google.com/p/v8/source/browse/branches/bleeding_edge/src/platform-openbsd.cc#488


2. The operating system

http://www.minix3.org/


3. POSIX Semaphores

http://www.opengroup.org/onlinepubs/009695399/basedefs/semaphore.h.html


4. The operating system's System V semaphore implementation

http://gforge.cs.vu.nl/gf/project/minix/scmsvn/?action=browse&path=%2Ftrunk%2Fsrc%2Finclude%2Fsys%2Fsem.h&view=markup

pikpik
Newbie Poster
1 post since Nov 2010
Reputation Points: 10
Solved Threads: 0
 

This article has been dead for over three months

Post: Markdown Syntax: Formatting Help
You
View similar articles that have also been tagged: