1124208Sdes/* $Id: bsd-nextstep.h,v 1.9 2003/08/29 16:59:52 mouring Exp $ */
2124208Sdes
398937Sdes/*
4124208Sdes * Copyright (c) 2000,2001 Ben Lindstrom.  All rights reserved.
5124208Sdes *
698937Sdes * Redistribution and use in source and binary forms, with or without
798937Sdes * modification, are permitted provided that the following conditions
898937Sdes * are met:
998937Sdes * 1. Redistributions of source code must retain the above copyright
1098937Sdes *    notice, this list of conditions and the following disclaimer.
1198937Sdes * 2. Redistributions in binary form must reproduce the above copyright
1298937Sdes *    notice, this list of conditions and the following disclaimer in the
1398937Sdes *    documentation and/or other materials provided with the distribution.
1498937Sdes *
1598937Sdes * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
1698937Sdes * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
1798937Sdes * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
1898937Sdes * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
1998937Sdes * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
2098937Sdes * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
2198937Sdes * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
2298937Sdes * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
2398937Sdes * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
2498937Sdes * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
2598937Sdes *
2698937Sdes */
2798937Sdes
2898937Sdes#ifndef _NEXT_POSIX_H
2998937Sdes#define _NEXT_POSIX_H
3098937Sdes
3198937Sdes#ifdef HAVE_NEXT
3298937Sdes#include <sys/dir.h>
3398937Sdes
3498937Sdes/* NGROUPS_MAX is behind -lposix.  Use the BSD version which is NGROUPS */
3598937Sdes#undef NGROUPS_MAX
3698937Sdes#define NGROUPS_MAX NGROUPS
3798937Sdes
3898937Sdes/* NeXT's readdir() is BSD (struct direct) not POSIX (struct dirent) */
3998937Sdes#define dirent direct
4098937Sdes
4198937Sdes/* Swap out NeXT's BSD wait() for a more POSIX complient one */
42124208Sdespid_t posix_wait(int *);
4398937Sdes#define wait(a) posix_wait(a)
4498937Sdes
4598937Sdes/* #ifdef wrapped functions that need defining for clean compiling */
4698937Sdespid_t getppid(void);
4798937Sdesvoid vhangup(void);
48124208Sdesint innetgr(const char *, const char *, const char *, const char *);
4998937Sdes
5098937Sdes/* TERMCAP */
51124208Sdesint tcgetattr(int, struct termios *);
52124208Sdesint tcsetattr(int, int, const struct termios *);
53124208Sdesint tcsetpgrp(int, pid_t);
54124208Sdesspeed_t cfgetospeed(const struct termios *);
55124208Sdesspeed_t cfgetispeed(const struct termios *);
56124208Sdesint cfsetospeed(struct termios *, int);
57124208Sdesint cfsetispeed(struct termios *, int);
5898937Sdes#endif /* HAVE_NEXT */
5998937Sdes#endif /* _NEXT_POSIX_H */
60