about summary refs log tree commit diff
path: root/sysdeps/stub
diff options
context:
space:
mode:
Diffstat (limited to 'sysdeps/stub')
-rw-r--r--sysdeps/stub/fstatfs.c4
-rw-r--r--sysdeps/stub/fstatfs64.c (renamed from sysdeps/stub/setenv.c)34
-rw-r--r--sysdeps/stub/fxstat.c2
-rw-r--r--sysdeps/stub/fxstat64.c (renamed from sysdeps/stub/morecore.c)40
-rw-r--r--sysdeps/stub/getrlimit64.c (renamed from sysdeps/stub/putenv.c)12
-rw-r--r--sysdeps/stub/lseek64.c49
-rw-r--r--sysdeps/stub/lxstat64.c (renamed from sysdeps/stub/lxstat.c)6
-rw-r--r--sysdeps/stub/open64.c52
-rw-r--r--sysdeps/stub/pread64.c43
-rw-r--r--sysdeps/stub/pwrite64.c43
-rw-r--r--sysdeps/stub/readdir64.c (renamed from sysdeps/stub/getenv.c)16
-rw-r--r--sysdeps/stub/readdir64_r.c (renamed from sysdeps/stub/sbrk.c)19
-rw-r--r--sysdeps/stub/setrlimit64.c34
-rw-r--r--sysdeps/stub/statfs64.c31
-rw-r--r--sysdeps/stub/sysd-stdio.c116
-rw-r--r--sysdeps/stub/sysdep.h3
-rw-r--r--sysdeps/stub/tempname.c7
-rw-r--r--sysdeps/stub/xstat64.c36
18 files changed, 350 insertions, 197 deletions
diff --git a/sysdeps/stub/fstatfs.c b/sysdeps/stub/fstatfs.c
index 71502c5e9f..e7c40d8006 100644
--- a/sysdeps/stub/fstatfs.c
+++ b/sysdeps/stub/fstatfs.c
@@ -1,4 +1,4 @@
-/* fstatfs -- Return information about the filesystem on which FD resides.
+/* Return information about the filesystem on which FD resides.
    Copyright (C) 1996, 1997 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
@@ -28,6 +28,6 @@ __fstatfs (int fd, struct statfs *buf)
   __set_errno (ENOSYS);
   return -1;
 }
-stub_warning (statfs)
+stub_warning (fstatfs)
 
 weak_alias (__fstatfs, fstatfs)
diff --git a/sysdeps/stub/setenv.c b/sysdeps/stub/fstatfs64.c
index 15ba9bd524..b2dba0f38b 100644
--- a/sysdeps/stub/setenv.c
+++ b/sysdeps/stub/fstatfs64.c
@@ -1,4 +1,5 @@
-/* Copyright (C) 1992, 1995, 1996 Free Software Foundation, Inc.
+/* Return information about the filesystem on which FD resides.
+   Copyright (C) 1996, 1997 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
    The GNU C Library is free software; you can redistribute it and/or
@@ -16,36 +17,15 @@
    write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
    Boston, MA 02111-1307, USA.  */
 
-#include <stdlib.h>
 #include <errno.h>
+#include <sys/statfs.h>
+#include <stddef.h>
 
+/* Return information about the filesystem on which FD resides.  */
 int
-setenv (name, value, replace)
-     const char *name;
-     const char *value;
-     int replace;
+fstatfs64 (int fd, struct statfs64 *buf)
 {
   __set_errno (ENOSYS);
   return -1;
 }
-
-stub_warning (setenv)
-
-void
-unsetenv (name)
-     const char *name;
-{
-  __set_errno (ENOSYS);
-}
-
-stub_warning (unsetenv)
-
-
-int
-clearenv (void)
-{
-  __set_errno (ENOSYS);
-  return -1;
-}
-
-stub_warning (clearenv)
+stub_warning (fstatfs64)
diff --git a/sysdeps/stub/fxstat.c b/sysdeps/stub/fxstat.c
index 21c9098d17..0110c5fda0 100644
--- a/sysdeps/stub/fxstat.c
+++ b/sysdeps/stub/fxstat.c
@@ -44,6 +44,6 @@ __fxstat (int vers, int fd, struct stat *buf)
   __set_errno (ENOSYS);
   return -1;
 }
-stub_warning (__fxstat)
+stub_warning (fstat)
 
 weak_alias (__fxstat, _fxstat)
diff --git a/sysdeps/stub/morecore.c b/sysdeps/stub/fxstat64.c
index c2b1cb1985..93ec312d3e 100644
--- a/sysdeps/stub/morecore.c
+++ b/sysdeps/stub/fxstat64.c
@@ -1,4 +1,4 @@
-/* Copyright (C) 1991, 1992, 1995, 1996, 1997 Free Software Foundation, Inc.
+/* Copyright (C) 1991, 1995, 1996, 1997 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
    The GNU C Library is free software; you can redistribute it and/or
@@ -16,22 +16,32 @@
    write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
    Boston, MA 02111-1307, USA.  */
 
-#include <stddef.h>
 #include <errno.h>
+#include <stddef.h>
+#include <sys/stat.h>
 
-#define	_MALLOC_INTERNAL
-#include <malloc.h>
-
-/* Allocate INCREMENT more bytes of data space,
-   and return the start of data space, or NULL on errors.
-   If INCREMENT is negative, shrink data space.  */
-__ptr_t
-__default_morecore (increment)
-     ptrdiff_t increment;
+/* Get information about the file descriptor FD in BUF.  */
+int
+__fxstat64 (int vers, int fd, struct stat64 *buf)
 {
+  if (vers != _STAT_VER)
+    {
+      __set_errno (EINVAL);
+      return -1;
+    }
+
+  if (fd < 0)
+    {
+      __set_errno (EBADF);
+      return -1;
+    }
+  else if (buf == NULL)
+    {
+      __set_errno (EINVAL);
+      return -1;
+    }
+
   __set_errno (ENOSYS);
-  return NULL;
+  return -1;
 }
-
-
-stub_warning (__default_morecore)
+stub_warning (fstat64)
diff --git a/sysdeps/stub/putenv.c b/sysdeps/stub/getrlimit64.c
index 68a4a4552f..6f12cad84b 100644
--- a/sysdeps/stub/putenv.c
+++ b/sysdeps/stub/getrlimit64.c
@@ -16,18 +16,16 @@
    write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
    Boston, MA 02111-1307, USA.  */
 
+#include <sys/resource.h>
 #include <errno.h>
-#include <stdlib.h>
 
-/* Put STRING, which is of the form "NAME=VALUE", in the environment.
-   If there is no `=', remove NAME from the environment.  */
+/* Put the soft and hard limits for RESOURCE in *RLIMITS.
+   Returns 0 if successful, -1 if not (and sets errno).  */
 int
-putenv (string)
-     const char *string;
+getrlimit64 (enum __rlimit_resource resource, struct rlimit64 *rlimits)
 {
   __set_errno (ENOSYS);
   return -1;
 }
 
-
-stub_warning (putenv)
+stub_warning (getrlimit64)
diff --git a/sysdeps/stub/lseek64.c b/sysdeps/stub/lseek64.c
new file mode 100644
index 0000000000..71d58ba1a6
--- /dev/null
+++ b/sysdeps/stub/lseek64.c
@@ -0,0 +1,49 @@
+/* Copyright (C) 1991, 1995, 1996, 1997 Free Software Foundation, Inc.
+   This file is part of the GNU C Library.
+
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Library General Public License as
+   published by the Free Software Foundation; either version 2 of the
+   License, or (at your option) any later version.
+
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Library General Public License for more details.
+
+   You should have received a copy of the GNU Library General Public
+   License along with the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
+
+#include <errno.h>
+#include <unistd.h>
+#include <sys/types.h>
+
+/* Seek to OFFSET on FD, starting from WHENCE.  */
+off64_t
+lseek64 (fd, offset, whence)
+     int fd;
+     off64_t offset;
+     int whence;
+{
+  if (fd < 0)
+    {
+      __set_errno (EBADF);
+      return -1;
+    }
+  switch (whence)
+    {
+    case SEEK_SET:
+    case SEEK_CUR:
+    case SEEK_END:
+      break;
+    default:
+      __set_errno (EINVAL);
+      return -1;
+    }
+
+  __set_errno (ENOSYS);
+  return -1;
+}
+stub_warning (lseek64)
diff --git a/sysdeps/stub/lxstat.c b/sysdeps/stub/lxstat64.c
index 3a7d64bedb..78e0b82bde 100644
--- a/sysdeps/stub/lxstat.c
+++ b/sysdeps/stub/lxstat64.c
@@ -23,7 +23,7 @@
 /* Get file information about FILE in BUF.
    If FILE is a symbolic link, do not follow it.  */
 int
-__lxstat (int vers, const char *file, struct stat *buf)
+__lxstat64 (int vers, const char *file, struct stat64 *buf)
 {
   if (vers != _STAT_VER || file == NULL || buf == NULL)
     {
@@ -34,6 +34,4 @@ __lxstat (int vers, const char *file, struct stat *buf)
   __set_errno (ENOSYS);
   return -1;
 }
-stub_warning (__lxstat)
-
-weak_alias (__lxstat, _lxstat)
+stub_warning (lstat64)
diff --git a/sysdeps/stub/open64.c b/sysdeps/stub/open64.c
new file mode 100644
index 0000000000..c020d887bd
--- /dev/null
+++ b/sysdeps/stub/open64.c
@@ -0,0 +1,52 @@
+/* Copyright (C) 1991, 1995, 1996, 1997 Free Software Foundation, Inc.
+   This file is part of the GNU C Library.
+
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Library General Public License as
+   published by the Free Software Foundation; either version 2 of the
+   License, or (at your option) any later version.
+
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Library General Public License for more details.
+
+   You should have received a copy of the GNU Library General Public
+   License along with the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
+
+#include <errno.h>
+#include <fcntl.h>
+#include <stdarg.h>
+#include <stddef.h>
+
+/* Open FILE with access OFLAG.  If OFLAG includes O_CREAT,
+   a third argument is the file protection.  */
+int
+__open64 (file, oflag)
+     const char *file;
+     int oflag;
+{
+  int mode;
+
+  if (file == NULL)
+    {
+      __set_errno (EINVAL);
+      return -1;
+    }
+
+  if (oflag & O_CREAT)
+    {
+      va_list arg;
+      va_start (arg, oflag);
+      mode = va_arg (arg, int);
+      va_end (arg);
+    }
+
+  __set_errno (ENOSYS);
+  return -1;
+}
+weak_alias (__open64, open64)
+
+stub_warning (open64)
diff --git a/sysdeps/stub/pread64.c b/sysdeps/stub/pread64.c
new file mode 100644
index 0000000000..4223646576
--- /dev/null
+++ b/sysdeps/stub/pread64.c
@@ -0,0 +1,43 @@
+/* Copyright (C) 1991, 1995, 1996, 1997 Free Software Foundation, Inc.
+   This file is part of the GNU C Library.
+
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Library General Public License as
+   published by the Free Software Foundation; either version 2 of the
+   License, or (at your option) any later version.
+
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Library General Public License for more details.
+
+   You should have received a copy of the GNU Library General Public
+   License along with the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
+
+#include <errno.h>
+#include <unistd.h>
+
+/* Read NBYTES into BUF from FD at the given position OFFSET without
+   changing the file pointer.  Return the number read or -1.  */
+ssize_t
+pread64 (int fd, void *buf, size_t nbytes, off64_t offset)
+{
+  if (nbytes == 0)
+    return 0;
+  if (fd < 0)
+    {
+      __set_errno (EBADF);
+      return -1;
+    }
+  if (buf == NULL || offset < 0)
+    {
+      __set_errno (EINVAL);
+      return -1;
+    }
+
+  __set_errno (ENOSYS);
+  return -1;
+}
+stub_warning (pread64)
diff --git a/sysdeps/stub/pwrite64.c b/sysdeps/stub/pwrite64.c
new file mode 100644
index 0000000000..c8c77a1880
--- /dev/null
+++ b/sysdeps/stub/pwrite64.c
@@ -0,0 +1,43 @@
+/* Copyright (C) 1991, 1995, 1996, 1997 Free Software Foundation, Inc.
+   This file is part of the GNU C Library.
+
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Library General Public License as
+   published by the Free Software Foundation; either version 2 of the
+   License, or (at your option) any later version.
+
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Library General Public License for more details.
+
+   You should have received a copy of the GNU Library General Public
+   License along with the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
+
+#include <errno.h>
+#include <unistd.h>
+
+/* Write NBYTES of BUF to FD at given position OFFSET without changing
+   the file position.  Return the number written, or -1.  */
+ssize_t
+pwrite64 (int fd, const void *buf, size_t nbytes, off64_t offset)
+{
+  if (nbytes == 0)
+    return 0;
+  if (fd < 0)
+    {
+      __set_errno (EBADF);
+      return -1;
+    }
+  if (buf == NULL || offset < 0)
+    {
+      __set_errno (EINVAL);
+      return -1;
+    }
+
+  __set_errno (ENOSYS);
+  return -1;
+}
+stub_warning (pwrite64)
diff --git a/sysdeps/stub/getenv.c b/sysdeps/stub/readdir64.c
index ec378f63cc..fbf4bf4d54 100644
--- a/sysdeps/stub/getenv.c
+++ b/sysdeps/stub/readdir64.c
@@ -1,4 +1,4 @@
-/* Copyright (C) 1991, 1995, 1996 Free Software Foundation, Inc.
+/* Copyright (C) 1991, 1995, 1996, 1997 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
    The GNU C Library is free software; you can redistribute it and/or
@@ -17,16 +17,14 @@
    Boston, MA 02111-1307, USA.  */
 
 #include <errno.h>
-#include <stdlib.h>
+#include <stddef.h>
+#include <dirent.h>
 
-/* Return the value of the environment variable NAME.  */
-char *
-getenv (name)
-     const char *name;
+/* Read a directory entry from DIRP.  */
+struct dirent64 *
+readdir64 (DIR *dirp)
 {
   __set_errno (ENOSYS);
   return NULL;
 }
-
-
-stub_warning (getenv)
+stub_warning (readdir64)
diff --git a/sysdeps/stub/sbrk.c b/sysdeps/stub/readdir64_r.c
index a85b1bdb3e..cb143cb40c 100644
--- a/sysdeps/stub/sbrk.c
+++ b/sysdeps/stub/readdir64_r.c
@@ -17,17 +17,16 @@
    Boston, MA 02111-1307, USA.  */
 
 #include <errno.h>
+#include <stddef.h>
+#include <dirent.h>
 
-/* Extend the process's data space by INCREMENT.
-   If INCREMENT is negative, shrink data space by - INCREMENT.
-   Return the address of the start of data space, or -1 for errors.  */
-void *
-__sbrk (increment)
-     int increment;
+/* Read a directory entry from DIRP, store result in ENTRY and return
+   pointer to result in *RESULT.  */
+int
+readdir64_r (DIR *dirp, struct dirent64 *entry, struct dirent64 **result)
 {
   __set_errno (ENOSYS);
-  return (void *) -1;
+  *result = NULL;
+  return -1;
 }
-stub_warning (sbrk)
-
-weak_alias (__sbrk, sbrk)
+stub_warning (readdir64_r)
diff --git a/sysdeps/stub/setrlimit64.c b/sysdeps/stub/setrlimit64.c
new file mode 100644
index 0000000000..0f223f246c
--- /dev/null
+++ b/sysdeps/stub/setrlimit64.c
@@ -0,0 +1,34 @@
+/* Copyright (C) 1991, 1995, 1996, 1997 Free Software Foundation, Inc.
+   This file is part of the GNU C Library.
+
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Library General Public License as
+   published by the Free Software Foundation; either version 2 of the
+   License, or (at your option) any later version.
+
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Library General Public License for more details.
+
+   You should have received a copy of the GNU Library General Public
+   License along with the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
+
+#include <sys/resource.h>
+#include <errno.h>
+
+/* Set the soft and hard limits for RESOURCE to *RLIMITS.
+   Only the super-user can increase hard limits.
+   Return 0 if successful, -1 if not (and sets errno).  */
+int
+setrlimit64 (resource, rlimits)
+     enum __rlimit_resource resource;
+     struct rlimit64 *rlimits;
+{
+  __set_errno (ENOSYS);
+  return -1;
+}
+
+stub_warning (setrlimit64)
diff --git a/sysdeps/stub/statfs64.c b/sysdeps/stub/statfs64.c
new file mode 100644
index 0000000000..51cde7dd27
--- /dev/null
+++ b/sysdeps/stub/statfs64.c
@@ -0,0 +1,31 @@
+/* Return information about the filesystem on which FILE resides.
+   Copyright (C) 1996, 1997 Free Software Foundation, Inc.
+   This file is part of the GNU C Library.
+
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Library General Public License as
+   published by the Free Software Foundation; either version 2 of the
+   License, or (at your option) any later version.
+
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Library General Public License for more details.
+
+   You should have received a copy of the GNU Library General Public
+   License along with the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
+
+#include <errno.h>
+#include <sys/statfs.h>
+#include <stddef.h>
+
+/* Return information about the filesystem on which FILE resides.  */
+int
+statfs64 (const char *file, struct statfs64 *buf)
+{
+  __set_errno (ENOSYS);
+  return -1;
+}
+stub_warning (statfs64)
diff --git a/sysdeps/stub/sysd-stdio.c b/sysdeps/stub/sysd-stdio.c
deleted file mode 100644
index 2c2dc3c1f2..0000000000
--- a/sysdeps/stub/sysd-stdio.c
+++ /dev/null
@@ -1,116 +0,0 @@
-/* Copyright (C) 1991, 92, 93, 94, 95, 96, 97 Free Software Foundation, Inc.
-   This file is part of the GNU C Library.
-
-   The GNU C Library is free software; you can redistribute it and/or
-   modify it under the terms of the GNU Library General Public License as
-   published by the Free Software Foundation; either version 2 of the
-   License, or (at your option) any later version.
-
-   The GNU C Library is distributed in the hope that it will be useful,
-   but WITHOUT ANY WARRANTY; without even the implied warranty of
-   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-   Library General Public License for more details.
-
-   You should have received a copy of the GNU Library General Public
-   License along with the GNU C Library; see the file COPYING.LIB.  If not,
-   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
-   Boston, MA 02111-1307, USA.  */
-
-#include <errno.h>
-#include <stdio.h>
-
-
-/* Read up to N chars into BUF from COOKIE.
-   Return how many chars were read, 0 for EOF or -1 for error.  */
-int
-__stdio_read (cookie, buf, n)
-     void *cookie;
-     register char *buf;
-     register size_t n;
-{
-  __set_errno (ENOSYS);
-  return -1;
-}
-
-/* Write up to N chars from BUF to COOKIE.
-   Return how many chars were written or -1 for error.  */
-int
-__stdio_write (cookie, buf, n)
-     void *cookie;
-     register const char *buf;
-     register size_t n;
-{
-  __set_errno (ENOSYS);
-  return -1;
-}
-
-/* Move COOKIE's file position *POS bytes, according to WHENCE.
-   The new file position is stored in *POS.
-   Returns zero if successful, nonzero if not.  */
-int
-__stdio_seek (cookie, pos, whence)
-     void *cookie;
-     fpos_t *pos;
-     int whence;
-{
-  __set_errno (ENOSYS);
-  return -1;
-}
-
-/* Close the file associated with COOKIE.
-   Return 0 for success or -1 for failure.  */
-int
-__stdio_close (cookie)
-      void *cookie;
-{
-  __set_errno (ENOSYS);
-  return -1;
-}
-
-/* Return the POSIX.1 file descriptor associated with COOKIE,
-   or -1 for errors.  If COOKIE does not relate to any POSIX.1 file
-   descriptor, this should return -1 with errno set to EOPNOTSUPP.  */
-int
-__stdio_fileno (cookie)
-     void *cookie;
-{
-  __set_errno (ENOSYS);
-  return -1;
-}
-
-
-/* Open FILENAME with the mode in M.
-   Store the magic cookie associated with the opened file in *COOKIEPTR.
-   Return zero on success and nonzero on failure.  */
-int
-__stdio_open (filename, m, cookieptr)
-     const char *filename;
-     __io_mode m;
-     void **cookieptr;
-{
-  __set_errno (ENOSYS);
-  return -1;
-}
-
-
-/* Open FILENAME with the mode in M.  Use the same magic cookie
-   already in *COOKIEPTR if possible, closing the old cookie with CLOSEFN.  */
-int
-__stdio_reopen (filename, m, cookieptr)
-     const char *filename;
-     __io_mode m;
-     void **cookieptr;
-     __io_close_fn closefn;
-{
-  __set_errno (ENOSYS);
-  return -1;
-}
-
-
-stub_warning (__stdio_read)
-stub_warning (__stdio_write)
-stub_warning (__stdio_seek)
-stub_warning (__stdio_close)
-stub_warning (__stdio_fileno)
-stub_warning (__stdio_open)
-stub_warning (__stdio_reopen)
diff --git a/sysdeps/stub/sysdep.h b/sysdeps/stub/sysdep.h
deleted file mode 100644
index 8c3184bf03..0000000000
--- a/sysdeps/stub/sysdep.h
+++ /dev/null
@@ -1,3 +0,0 @@
-/* This file should contain any system-dependent types and macros
-   that will be used by many parts of the library.  It should also
-   contain declarations for any functions defined in sysdep.c.  */
diff --git a/sysdeps/stub/tempname.c b/sysdeps/stub/tempname.c
index b93b948ca6..d87c54f86a 100644
--- a/sysdeps/stub/tempname.c
+++ b/sysdeps/stub/tempname.c
@@ -1,4 +1,4 @@
-/* Copyright (C) 1991, 92, 93, 95, 96 Free Software Foundation, Inc.
+/* Copyright (C) 1991, 92, 93, 95, 96, 97 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
    The GNU C Library is free software; you can redistribute it and/or
@@ -26,7 +26,8 @@
    Return the generated filename or NULL if one could not
    be generated, putting the length of the string in *LENPTR.  */
 char *
-__stdio_gen_tempname (buf, bufsize, dir, pfx, dir_search, lenptr, streamptr)
+__stdio_gen_tempname (buf, bufsize, dir, pfx, dir_search, lenptr, streamptr,
+		      large_file)
      char *buf;
      size_t bufsize;
      const char *dir;
@@ -34,11 +35,11 @@ __stdio_gen_tempname (buf, bufsize, dir, pfx, dir_search, lenptr, streamptr)
      int dir_search;
      size_t *lenptr;
      FILE **streamptr;
+     int large_file;
 {
   *lenptr = 0;
   __set_errno (ENOSYS);
   return NULL;
 }
 
-
 stub_warning (__stdio_gen_tempname)
diff --git a/sysdeps/stub/xstat64.c b/sysdeps/stub/xstat64.c
new file mode 100644
index 0000000000..8eb1d177df
--- /dev/null
+++ b/sysdeps/stub/xstat64.c
@@ -0,0 +1,36 @@
+/* Copyright (C) 1991, 1995, 1996, 1997 Free Software Foundation, Inc.
+   This file is part of the GNU C Library.
+
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Library General Public License as
+   published by the Free Software Foundation; either version 2 of the
+   License, or (at your option) any later version.
+
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Library General Public License for more details.
+
+   You should have received a copy of the GNU Library General Public
+   License along with the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
+
+#include <errno.h>
+#include <sys/stat.h>
+#include <stddef.h>
+
+/* Get file information about FILE in BUF.  */
+int
+__xstat64 (int vers, const char *file, struct stat64 *buf)
+{
+  if (vers != _STAT_VER || file == NULL || buf == NULL)
+    {
+      __set_errno (EINVAL);
+      return -1;
+    }
+
+  __set_errno (ENOSYS);
+  return -1;
+}
+stub_warning (stat64)