# AC_HEADER_STDC
AC_CHECK_HEADERS(malloc.h \
fcntl.h search.h termios.h \
- unistd.h strings.h stat.h \
+ unistd.h strings.h stat.h vfork.h \
sys/time.h sys/types.h sys/select.h \
- sys/stat.h sys/mman.h \
+ sys/stat.h sys/mman.h sys/vfork.h \
sys/ioctl.h sys/inotify.h crt_externs.h)
AC_HEADER_TIME
AC_HEADER_DIRENT
# Converted to sfio v10/01/94 by Giampiero Sierra (06/08/95).
##################################################################
-hdr unistd
-
lib ftruncate
lib lseek64
# vfork and any associated header files
##################################################
-hdr vfork
-sys vfork
lib vfork
##################################################
# file control checks
##################################################
-sys ioctl
lib remove
lib unlink
lib waitpid
#include "FEATURE/sfio"
#include "sfio_t.h"
+#include "config.h"
#include <vthread.h>
#undef _lib_poll
#undef _stream_peek
#undef _socket_peek
-#undef _hdr_vfork
-#undef _sys_vfork
+#undef HAVE_VFORK_H
+#undef _HAVE_SYS_VFORK_H
#undef _lib_vfork
-#undef _sys_ioctl
+#undef HAVE_SYS_IOCTL_H
#endif
#include <stdlib.h>
#include <fcntl.h>
-#if _hdr_unistd
+#if HAVE_UNISTD_H
#include <unistd.h>
#endif
/* alternative process forking */
#if _lib_vfork && !defined(fork) && !defined(sparc) && !defined(__sparc)
-#if defined(_hdr_vfork)
+#if defined(HAVE_VFORK_H)
#include <vfork.h>
#endif
-#if defined(_sys_vfork)
+#if defined(_HAVE_SYS_VFORK_H)
#include <sys/vfork.h>
#endif
#define fork vfork
#include <io.h>
#define SF_ERROR 0000400 /* an error happened */
#else
-#if !_hdr_unistd
+#if !HAVE_UNISTD_H
extern int close(int);
extern ssize_t read(int, void *, size_t);
extern ssize_t write(int, const void *, size_t);
extern int unlink(const char *);
#endif
-#endif /*_hdr_unistd*/
+#endif /*HAVE_UNISTD_H*/
#endif /* WIN32 */
extern time_t time(time_t *);
extern int fstat(int, Stat_t *);
#endif
-#if _lib_vfork && !defined(_hdr_vfork) && !defined(_sys_vfork)
+#if _lib_vfork && !defined(HAVE_VFORK_H) && !defined(_HAVE_SYS_VFORK_H)
extern pid_t vfork(void);
#endif /*_lib_vfork*/