mirror of
git://git.musl-libc.org/musl
synced 2024-12-25 08:02:28 +00:00
490d4a0e9e
despite glibc using __key and __seq rather than key and seq, some applications, notably busybox, assume the names are key and seq unless glibc is being used. and the names key and seq are really the ones that _should_ be exposed when not attempting to present a standards-conforming namespace; apps should not be using names that begin with double-underscore. thus, the optimal fix is to use key and seq as the actual names of the members when in bsd/gnu source profile, and define macros for __key and __seq that redirect to plain key and seq.
43 lines
644 B
C
43 lines
644 B
C
#ifndef _SYS_IPC_H
|
|
#define _SYS_IPC_H
|
|
#ifdef __cplusplus
|
|
extern "C" {
|
|
#endif
|
|
|
|
#include <features.h>
|
|
|
|
#define __NEED_uid_t
|
|
#define __NEED_gid_t
|
|
#define __NEED_mode_t
|
|
#define __NEED_key_t
|
|
|
|
#include <bits/alltypes.h>
|
|
|
|
#define __ipc_perm_key __key
|
|
#define __ipc_perm_seq __seq
|
|
|
|
#if defined(_GNU_SOURCE) || defined(_BSD_SOURCE)
|
|
#define __key key
|
|
#define __seq seq
|
|
#endif
|
|
|
|
#include <bits/ipc.h>
|
|
|
|
#define IPC_CREAT 01000
|
|
#define IPC_EXCL 02000
|
|
#define IPC_NOWAIT 04000
|
|
|
|
#define IPC_RMID 0
|
|
#define IPC_SET 1
|
|
#define IPC_STAT 2
|
|
#define IPC_INFO 3
|
|
|
|
#define IPC_PRIVATE ((key_t) 0)
|
|
|
|
key_t ftok (const char *, int);
|
|
|
|
#ifdef __cplusplus
|
|
}
|
|
#endif
|
|
#endif
|