mirror of
https://github.com/jart/cosmopolitan.git
synced 2025-06-03 11:12:27 +00:00
Remove bad defines from early days of project
These definitions were causing issues with building LLVM. It is possible they also caused crashes we've seen with our MacOS ARM64 OpenMP support.
This commit is contained in:
parent
f25fbbaaeb
commit
5dd7ddb9ea
20 changed files with 568 additions and 140 deletions
|
@ -3,6 +3,12 @@
|
|||
#include "libc/calls/struct/timespec.h"
|
||||
COSMOPOLITAN_C_START_
|
||||
|
||||
#ifndef __cplusplus
|
||||
#define _SEM_ATOMIC(x) _Atomic(x)
|
||||
#else
|
||||
#define _SEM_ATOMIC(x) x
|
||||
#endif
|
||||
|
||||
#define SEM_FAILED ((sem_t *)0)
|
||||
#define SEM_MAGIC_NAMED 0xDEADBEEFu
|
||||
#define SEM_MAGIC_UNNAMED 0xFEEDABEEu
|
||||
|
@ -11,9 +17,9 @@ COSMOPOLITAN_C_START_
|
|||
typedef struct {
|
||||
union {
|
||||
struct {
|
||||
_Atomic(int) sem_value;
|
||||
_Atomic(int) sem_waiters;
|
||||
_Atomic(int) sem_prefs; /* named only */
|
||||
_SEM_ATOMIC(int) sem_value;
|
||||
_SEM_ATOMIC(int) sem_waiters;
|
||||
_SEM_ATOMIC(int) sem_prefs; /* named only */
|
||||
unsigned sem_magic;
|
||||
int64_t sem_dev; /* named only */
|
||||
int64_t sem_ino; /* named only */
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue