summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--libc/misc/internals/tempname.c2
-rw-r--r--libc/stdio/fseeko.c2
-rw-r--r--libc/stdio/ftello.c2
-rw-r--r--libc/stdlib/Makefile.in5
-rw-r--r--libc/sysdeps/linux/common/Makefile.in5
5 files changed, 15 insertions, 1 deletions
diff --git a/libc/misc/internals/tempname.c b/libc/misc/internals/tempname.c
index b8b421f13..26918dc16 100644
--- a/libc/misc/internals/tempname.c
+++ b/libc/misc/internals/tempname.c
@@ -50,7 +50,9 @@ libc_hidden_proto(strcmp)
libc_hidden_proto(sprintf)
libc_hidden_proto(mkdir)
libc_hidden_proto(open)
+#ifdef __UCLIBC_HAS_LFS__
libc_hidden_proto(open64)
+#endif
libc_hidden_proto(read)
libc_hidden_proto(close)
libc_hidden_proto(getpid)
diff --git a/libc/stdio/fseeko.c b/libc/stdio/fseeko.c
index 74a9e3c3a..f63ebad4e 100644
--- a/libc/stdio/fseeko.c
+++ b/libc/stdio/fseeko.c
@@ -16,7 +16,9 @@
# define OFFSET_TYPE long int
#endif
+#ifdef __UCLIBC_HAS_LFS__
libc_hidden_proto(fseeko64)
+#endif
libc_hidden_proto(fseek)
int FSEEK(register FILE *stream, OFFSET_TYPE offset, int whence)
diff --git a/libc/stdio/ftello.c b/libc/stdio/ftello.c
index 2b9da8a6b..4445471a4 100644
--- a/libc/stdio/ftello.c
+++ b/libc/stdio/ftello.c
@@ -7,7 +7,9 @@
#include "_stdio.h"
+#ifdef __UCLIBC_HAS_LFS__
libc_hidden_proto(ftello64)
+#endif
libc_hidden_proto(ftell)
#ifndef __DO_LARGEFILE
diff --git a/libc/stdlib/Makefile.in b/libc/stdlib/Makefile.in
index 7c943dd56..26bc78201 100644
--- a/libc/stdlib/Makefile.in
+++ b/libc/stdlib/Makefile.in
@@ -57,12 +57,15 @@ MOBJ3+=old_atexit.o
endif
CSRC:= \
- abort.c getenv.c mkdtemp.c mktemp.c realpath.c mkstemp.c mkstemp64.c \
+ abort.c getenv.c mkdtemp.c mktemp.c realpath.c mkstemp.c \
rand.c random.c random_r.c setenv.c system.c div.c ldiv.c lldiv.c \
getpt.c ptsname.c grantpt.c unlockpt.c gcvt.c drand48-iter.c jrand48.c \
jrand48_r.c lrand48.c lrand48_r.c mrand48.c mrand48_r.c nrand48.c \
nrand48_r.c rand_r.c srand48.c srand48_r.c seed48.c seed48_r.c \
valloc.c posix_memalign.c a64l.c l64a.c arc4random.c
+ifeq ($(UCLIBC_HAS_LFS),y)
+CSRC+=mkstemp64.c
+endif
ifeq ($(UCLIBC_HAS_FLOATS),y)
CSRC+=drand48.c drand48_r.c erand48.c erand48_r.c
endif
diff --git a/libc/sysdeps/linux/common/Makefile.in b/libc/sysdeps/linux/common/Makefile.in
index 5d3d1e293..8869c5aa8 100644
--- a/libc/sysdeps/linux/common/Makefile.in
+++ b/libc/sysdeps/linux/common/Makefile.in
@@ -14,6 +14,11 @@ ifeq ($(EXCLUDE_BRK),y)
CSRC:=$(filter-out sbrk.c,$(CSRC))
endif
+ifneq ($(UCLIBC_HAS_LFS),y)
+CSRC_LFS:=$(patsubst $(COMMON_DIR)/%.c,%.c,$(wildcard $(COMMON_DIR)/*64.c))
+CSRC:=$(filter-out llseek.c $(CSRC_LFS),$(CSRC))
+endif
+
# full list
#COMMON_NO_MULTI:=getcwd.c getrlimit.c getrlimit64.c setrlimit.c setrlimit64.c getpriority.c getpriority64.c setpriority.c getrusage.c wait4.c getitimer.c setitimer.c open.c open64.c uname.c __syscall_fcntl.c __syscall_fcntl64.c
COMMON_NO_MULTI:=getrlimit.c getrlimit64.c setrlimit.c setrlimit64.c getpriority.c setpriority.c getrusage.c getitimer.c setitimer.c uname.c __syscall_rt_sigaction.c