Made semaphore_t an abstract interface.