Maybe the OP should review all other available options, particularly since the handling of semaphores and memory segments in this particular package might be less-than-optimal today. "65536" smacks of 16-bit concerns. A lot has changed since this source-code was first written.