While working with C programming, I tried using the following code:
// Create semaphoresemaphoreID = semget(SEM_KEY, 1, 0666 | IPC_CREAT);batherSemID = semget(BATHER_SEM_KEY, 1, 0666 | IPC_CREAT);spinWaitID = semget(SPINWAIT_SEM_KEY,1, 0666 | IPC_CREAT);if(semaphoreID < 0 || batherSemID < 0){(ENABLE_DEBUG)?(fprintf(stderr, "Semaphore error... Exiting\n")):(false);exit(0);}
This compiles and runs, but ends up stopping at the semaphore error and exiting (the semaphores are returning -1 meaning they failed to create)
Running ipcs returns the following output:
localhost:~# ipcs
kernel not configured for message queues
kernel not configured for shared memory
kernel not configured for semaphores
Opening this issue to see if there is any plan on future support for semaphores and shared memory.
While working with C programming, I tried using the following code:
// Create semaphore
semaphoreID = semget(SEM_KEY, 1, 0666 | IPC_CREAT);
batherSemID = semget(BATHER_SEM_KEY, 1, 0666 | IPC_CREAT);
spinWaitID = semget(SPINWAIT_SEM_KEY,1, 0666 | IPC_CREAT);
if(semaphoreID < 0 || batherSemID < 0){
(ENABLE_DEBUG)?(fprintf(stderr, "Semaphore error... Exiting\n")):(false);
exit(0);
}
This compiles and runs, but ends up stopping at the semaphore error and exiting (the semaphores are returning -1 meaning they failed to create)
Running
ipcs
returns the following output:localhost:~# ipcs
kernel not configured for message queues
kernel not configured for shared memory
kernel not configured for semaphores
Opening this issue to see if there is any plan on future support for semaphores and shared memory.