summaryrefslogtreecommitdiffstats
path: root/libc/misc/statfs
diff options
context:
space:
mode:
Diffstat (limited to 'libc/misc/statfs')
-rw-r--r--libc/misc/statfs/Makefile48
-rw-r--r--libc/misc/statfs/fstatfs64.c2
-rw-r--r--libc/misc/statfs/fstatvfs.c2
-rw-r--r--libc/misc/statfs/fstatvfs64.c2
-rw-r--r--libc/misc/statfs/internal_statvfs.c18
-rw-r--r--libc/misc/statfs/statfs64.c2
-rw-r--r--libc/misc/statfs/statvfs.c2
-rw-r--r--libc/misc/statfs/statvfs64.c2
8 files changed, 27 insertions, 51 deletions
diff --git a/libc/misc/statfs/Makefile b/libc/misc/statfs/Makefile
index bbb9dd0bc..4a8f4a072 100644
--- a/libc/misc/statfs/Makefile
+++ b/libc/misc/statfs/Makefile
@@ -1,45 +1,13 @@
# Makefile for uClibc
-# Copyright (C) 2001,2002 Erik Andersen <andersen@uclibc.org>
#
-# This program 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.
+# Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org>
#
-# This program 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.
+# Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball.
#
-# You should have received a copy of the GNU Library General Public License
-# along with this program; if not, write to the Free Software Foundation, Inc.,
-# 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
-#
-# Derived in part from the Linux-8086 C library, the GNU C Library, and several
-# other sundry sources. Files within this library are copyright by their
-# respective copyright holders.
-
-TOPDIR=../../../
-include $(TOPDIR)Rules.mak
-
-ifeq ($(strip $(UCLIBC_HAS_LFS)),y)
-CSRC = fstatfs64.c statfs64.c statvfs.c statvfs64.c fstatvfs.c fstatvfs64.c
-else
-CSRC = statvfs.c fstatvfs.c
-endif
-COBJS=$(patsubst %.c,%.o, $(CSRC))
-OBJS=$(COBJS)
-
-OBJ_LIST=../../obj.misc.statfs
-
-all: $(OBJ_LIST)
-
-$(OBJ_LIST): $(OBJS)
- echo $(patsubst %, misc/statfs/%, $(OBJS)) > $(OBJ_LIST)
-
-$(COBJS): %.o : %.c
- $(CC) $(CFLAGS) -c $< -o $@
- $(STRIPTOOL) -x -R .note -R .comment $*.o
-clean:
- $(RM) *.[oa] *~ core
+top_srcdir=../../../
+top_builddir=../../../
+all: objs
+include $(top_builddir)Rules.mak
+include Makefile.in
+include $(top_srcdir)Makerules
diff --git a/libc/misc/statfs/fstatfs64.c b/libc/misc/statfs/fstatfs64.c
index 1040e1fe1..b793002fb 100644
--- a/libc/misc/statfs/fstatfs64.c
+++ b/libc/misc/statfs/fstatfs64.c
@@ -57,7 +57,7 @@ int fstatfs64 (int fd, struct statfs64 *buf)
buf->f_ffree = buf32.f_ffree;
buf->f_fsid = buf32.f_fsid;
buf->f_namelen = buf32.f_namelen;
- memcpy (buf->f_spare, buf32.f_spare, sizeof (buf32.f_spare));
+ __memcpy (buf->f_spare, buf32.f_spare, sizeof (buf32.f_spare));
return 0;
}
diff --git a/libc/misc/statfs/fstatvfs.c b/libc/misc/statfs/fstatvfs.c
index 5e08f51ad..b79195e73 100644
--- a/libc/misc/statfs/fstatvfs.c
+++ b/libc/misc/statfs/fstatvfs.c
@@ -17,6 +17,8 @@
Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
02111-1307 USA. */
+#define strsep __strsep
+
#include <features.h>
#define __USE_GNU
diff --git a/libc/misc/statfs/fstatvfs64.c b/libc/misc/statfs/fstatvfs64.c
index ed4b63234..0d7416df3 100644
--- a/libc/misc/statfs/fstatvfs64.c
+++ b/libc/misc/statfs/fstatvfs64.c
@@ -17,6 +17,8 @@
Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
02111-1307 USA. */
+#define strsep __strsep
+
#include <features.h>
#ifdef __UCLIBC_HAS_LFS__
diff --git a/libc/misc/statfs/internal_statvfs.c b/libc/misc/statfs/internal_statvfs.c
index aa7af44f5..8f7e386c4 100644
--- a/libc/misc/statfs/internal_statvfs.c
+++ b/libc/misc/statfs/internal_statvfs.c
@@ -39,7 +39,7 @@
buf->__f_unused = 0;
#endif
buf->f_namemax = fsbuf.f_namelen;
- memset (buf->__f_spare, '\0', 6 * sizeof (int));
+ __memset (buf->__f_spare, '\0', 6 * sizeof (int));
/* What remains to do is to fill the fields f_favail and f_flag. */
@@ -79,21 +79,21 @@
char *opt;
while ((opt = strsep (&cp, ",")) != NULL)
- if (strcmp (opt, "ro") == 0)
+ if (__strcmp (opt, "ro") == 0)
buf->f_flag |= ST_RDONLY;
- else if (strcmp (opt, "nosuid") == 0)
+ else if (__strcmp (opt, "nosuid") == 0)
buf->f_flag |= ST_NOSUID;
- else if (strcmp (opt, "noexec") == 0)
+ else if (__strcmp (opt, "noexec") == 0)
buf->f_flag |= ST_NOEXEC;
- else if (strcmp (opt, "nodev") == 0)
+ else if (__strcmp (opt, "nodev") == 0)
buf->f_flag |= ST_NODEV;
- else if (strcmp (opt, "sync") == 0)
+ else if (__strcmp (opt, "sync") == 0)
buf->f_flag |= ST_SYNCHRONOUS;
- else if (strcmp (opt, "mand") == 0)
+ else if (__strcmp (opt, "mand") == 0)
buf->f_flag |= ST_MANDLOCK;
- else if (strcmp (opt, "noatime") == 0)
+ else if (__strcmp (opt, "noatime") == 0)
buf->f_flag |= ST_NOATIME;
- else if (strcmp (opt, "nodiratime") == 0)
+ else if (__strcmp (opt, "nodiratime") == 0)
buf->f_flag |= ST_NODIRATIME;
/* We can stop looking for more entries. */
diff --git a/libc/misc/statfs/statfs64.c b/libc/misc/statfs/statfs64.c
index 0b954c675..7144cce71 100644
--- a/libc/misc/statfs/statfs64.c
+++ b/libc/misc/statfs/statfs64.c
@@ -55,7 +55,7 @@ int statfs64 (const char *file, struct statfs64 *buf)
buf->f_ffree = buf32.f_ffree;
buf->f_fsid = buf32.f_fsid;
buf->f_namelen = buf32.f_namelen;
- memcpy (buf->f_spare, buf32.f_spare, sizeof (buf32.f_spare));
+ __memcpy (buf->f_spare, buf32.f_spare, sizeof (buf32.f_spare));
return 0;
}
diff --git a/libc/misc/statfs/statvfs.c b/libc/misc/statfs/statvfs.c
index 02a95fcde..0fe239573 100644
--- a/libc/misc/statfs/statvfs.c
+++ b/libc/misc/statfs/statvfs.c
@@ -17,6 +17,8 @@
Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
02111-1307 USA. */
+#define strsep __strsep
+
#include <features.h>
#define __USE_GNU
diff --git a/libc/misc/statfs/statvfs64.c b/libc/misc/statfs/statvfs64.c
index 78d1a4c3f..8bacbba70 100644
--- a/libc/misc/statfs/statvfs64.c
+++ b/libc/misc/statfs/statvfs64.c
@@ -17,6 +17,8 @@
Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
02111-1307 USA. */
+#define strsep __strsep
+
#include <features.h>
#ifdef __UCLIBC_HAS_LFS__