Blame sysvipc/sys/shm.h

Packit 6c4009
/* Copyright (C) 1995-2018 Free Software Foundation, Inc.
Packit 6c4009
   This file is part of the GNU C Library.
Packit 6c4009
Packit 6c4009
   The GNU C Library is free software; you can redistribute it and/or
Packit 6c4009
   modify it under the terms of the GNU Lesser General Public
Packit 6c4009
   License as published by the Free Software Foundation; either
Packit 6c4009
   version 2.1 of the License, or (at your option) any later version.
Packit 6c4009
Packit 6c4009
   The GNU C Library is distributed in the hope that it will be useful,
Packit 6c4009
   but WITHOUT ANY WARRANTY; without even the implied warranty of
Packit 6c4009
   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
Packit 6c4009
   Lesser General Public License for more details.
Packit 6c4009
Packit 6c4009
   You should have received a copy of the GNU Lesser General Public
Packit 6c4009
   License along with the GNU C Library; if not, see
Packit 6c4009
   <http://www.gnu.org/licenses/>.  */
Packit 6c4009
Packit 6c4009
#ifndef _SYS_SHM_H
Packit 6c4009
#define _SYS_SHM_H	1
Packit 6c4009
Packit 6c4009
#include <features.h>
Packit 6c4009
Packit 6c4009
#define __need_size_t
Packit 6c4009
#include <stddef.h>
Packit 6c4009
Packit 6c4009
/* Get common definition of System V style IPC.  */
Packit 6c4009
#include <sys/ipc.h>
Packit 6c4009
Packit 6c4009
/* Get system dependent definition of `struct shmid_ds' and more.  */
Packit 6c4009
#include <bits/shm.h>
Packit 6c4009
Packit 6c4009
/* Define types required by the standard.  */
Packit 6c4009
#include <bits/types/time_t.h>
Packit 6c4009
Packit 6c4009
#ifdef __USE_XOPEN
Packit 6c4009
# ifndef __pid_t_defined
Packit 6c4009
typedef __pid_t pid_t;
Packit 6c4009
#  define __pid_t_defined
Packit 6c4009
# endif
Packit 6c4009
#endif	/* X/Open */
Packit 6c4009
Packit 6c4009
Packit 6c4009
__BEGIN_DECLS
Packit 6c4009
Packit 6c4009
/* The following System V style IPC functions implement a shared memory
Packit 6c4009
   facility.  The definition is found in XPG4.2.  */
Packit 6c4009
Packit 6c4009
/* Shared memory control operation.  */
Packit 6c4009
extern int shmctl (int __shmid, int __cmd, struct shmid_ds *__buf) __THROW;
Packit 6c4009
Packit 6c4009
/* Get shared memory segment.  */
Packit 6c4009
extern int shmget (key_t __key, size_t __size, int __shmflg) __THROW;
Packit 6c4009
Packit 6c4009
/* Attach shared memory segment.  */
Packit 6c4009
extern void *shmat (int __shmid, const void *__shmaddr, int __shmflg)
Packit 6c4009
     __THROW;
Packit 6c4009
Packit 6c4009
/* Detach shared memory segment.  */
Packit 6c4009
extern int shmdt (const void *__shmaddr) __THROW;
Packit 6c4009
Packit 6c4009
__END_DECLS
Packit 6c4009
Packit 6c4009
#endif /* sys/shm.h */