aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Makeconfig14
-rw-r--r--Makerules18
-rw-r--r--io/Makefile22
-rw-r--r--io/ftwtest-time64.c1
-rw-r--r--io/tst-fts-time64.c1
-rw-r--r--io/tst-futimens-time64.c2
-rw-r--r--io/tst-futimens.c6
-rw-r--r--io/tst-futimes-time64.c2
-rw-r--r--io/tst-futimes.c6
-rw-r--r--io/tst-futimesat-time64.c4
-rw-r--r--io/tst-futimesat.c47
-rw-r--r--io/tst-lutimes-time64.c2
-rw-r--r--io/tst-lutimes.c10
-rw-r--r--io/tst-stat-time64.c102
-rw-r--r--io/tst-utime-time64.c2
-rw-r--r--io/tst-utime.c6
-rw-r--r--io/tst-utimensat-time64.c2
-rw-r--r--io/tst-utimensat.c12
-rw-r--r--io/tst-utimes-time64.c2
-rw-r--r--io/tst-utimes.c6
-rw-r--r--misc/Makefile4
-rw-r--r--misc/tst-pselect-time64.c1
-rw-r--r--misc/tst-select-time64.c1
-rw-r--r--nptl/Makefile3
-rw-r--r--nptl/tst-cancel4_2-time64.c1
-rw-r--r--posix/Makefile2
-rw-r--r--posix/tst-gnuglob64-time64.c7
-rw-r--r--posix/tst-sched_rr_get_interval-time64.c1
-rw-r--r--posix/tst-wait3-time64.c1
-rw-r--r--posix/tst-wait4-time64.c1
-rw-r--r--rt/Makefile9
-rw-r--r--rt/tst-aio6-time64.c1
-rw-r--r--rt/tst-cpuclock2-time64.c1
-rw-r--r--rt/tst-cpuclock2.c9
-rw-r--r--rt/tst-mqueue1-time64.c1
-rw-r--r--rt/tst-mqueue2-time64.c1
-rw-r--r--rt/tst-mqueue4-time64.c1
-rw-r--r--rt/tst-mqueue8-time64.c1
-rw-r--r--rt/tst-timer4-time64.c1
-rw-r--r--sysdeps/pthread/Makefile10
-rw-r--r--sysdeps/pthread/tst-abstime-time64.c1
-rw-r--r--sysdeps/pthread/tst-cnd-timedwait-time64.c1
-rw-r--r--sysdeps/pthread/tst-cond11-time64.c1
-rw-r--r--sysdeps/pthread/tst-join14-time64.c1
-rw-r--r--sysdeps/pthread/tst-mtx-timedlock-time64.c1
-rw-r--r--sysdeps/pthread/tst-rwlock14-time64.c1
-rw-r--r--sysdeps/pthread/tst-sem5-time64.c1
-rw-r--r--sysdeps/pthread/tst-thrd-sleep-time64.c1
-rw-r--r--sysdeps/unix/sysv/linux/Makefile10
-rw-r--r--sysdeps/unix/sysv/linux/tst-adjtimex-time64.c1
-rw-r--r--sysdeps/unix/sysv/linux/tst-clock_adjtime-time64.c1
-rw-r--r--sysdeps/unix/sysv/linux/tst-ntp_adjtime-time64.c1
-rw-r--r--sysdeps/unix/sysv/linux/tst-ntp_gettime-time64.c1
-rw-r--r--sysdeps/unix/sysv/linux/tst-ntp_gettimex-time64.c1
-rw-r--r--sysdeps/unix/sysv/linux/tst-ppoll-time64.c1
-rw-r--r--sysdeps/unix/sysv/linux/tst-sigtimedwait-time64.c1
-rw-r--r--sysdeps/unix/sysv/linux/tst-timerfd-time64.c1
-rw-r--r--sysvipc/Makefile2
-rw-r--r--sysvipc/test-sysvmsg-time64.c1
-rw-r--r--sysvipc/test-sysvsem-time64.c1
-rw-r--r--sysvipc/test-sysvshm-time64.c1
-rw-r--r--time/Makefile18
-rw-r--r--time/tst-adjtime-time64.c1
-rw-r--r--time/tst-clock-time64.c1
-rw-r--r--time/tst-clock2-time64.c1
-rw-r--r--time/tst-clock_nanosleep-time64.c1
-rw-r--r--time/tst-clock_settime-time64.c1
-rw-r--r--time/tst-cpuclock1-time64.c1
-rw-r--r--time/tst-ctime-time64.c1
-rw-r--r--time/tst-ctime.c16
-rw-r--r--time/tst-difftime-time64.c1
-rw-r--r--time/tst-gmtime-time64.c1
-rw-r--r--time/tst-itimer-time64.c1
-rw-r--r--time/tst-mktime4-time64.c1
-rw-r--r--time/tst-settimeofday-time64.c1
-rw-r--r--time/tst-timegm-time64.c1
-rw-r--r--time/tst-timespec_get-time64.c1
-rw-r--r--time/tst-timespec_getres-time64.c1
-rw-r--r--time/tst-y2039-time64.c1
-rw-r--r--time/tst-y2039.c10
80 files changed, 385 insertions, 30 deletions
diff --git a/Makeconfig b/Makeconfig
index c3496452b6..b6357d0b19 100644
--- a/Makeconfig
+++ b/Makeconfig
@@ -1235,6 +1235,20 @@ $(common-objpfx)versions.stmp: $(common-objpfx)Versions.all \
touch $@
endif # avoid-generated
endif # $(build-shared) = yes
+
+-include $(common-objpfx)time64-compat.mk
+postclean-generated += time64-compat.mk
+
+$(common-objpfx)time64-compat.mk: $(sysd-versions-force) \
+ $(common-objpfx)time64-compat.i
+ sed '/^[ ]*#/d;/^[ ]*$$/d' $< > $@T
+ mv -f $@T $@
+$(common-objpfx)time64-compat.i: $(..)Makeconfig
+ printf "#include <time64-compat.h>\n#ifdef TIME64_NON_DEFAULT\nhave-time64-compat = yes\n#endif" \
+ | $(CC) -E -undef $(CPPFLAGS) -x assembler-with-cpp - > $@T
+ mv -f $@T $@
+
+
endif # sysd-sorted-done
# The name under which the run-time dynamic linker is installed.
diff --git a/Makerules b/Makerules
index ca9885436e..12f1a5cb50 100644
--- a/Makerules
+++ b/Makerules
@@ -771,7 +771,8 @@ endif
$(patsubst %.o,%.d,$(filter %.o,$(extra-objs:.os=.o))) \
$(patsubst %.oS,%.d,$(filter %.oS,$(extra-objs))) \
$(patsubst %.o,%.d,$(filter %.o,$(extra-test-objs:.os=.o))) \
- $(addsuffix .d,$(tests) $(tests-internal) $(xtests) $(test-srcs))
+ $(addsuffix .d,$(tests) $(tests-internal) $(xtests) \
+ $(test-srcs) $(tests-time64) $(xtests-time64))
ifeq ($(build-programs),yes)
+depfiles += $(addsuffix .d,$(others) $(sysdep-others))
endif
@@ -1286,6 +1287,21 @@ check: tests
.PHONY: xcheck
xcheck: xtests
+# Handle tests-time64 and xtests-time64 that should built with LFS
+# and 64-bit time support.
+include $(o-iterator)
+define o-iterator-doit
+$(foreach f,$(tests-time64) $(xtests-time64),\
+ $(objpfx)$(f)$(o)): CFLAGS += -D_TIME_BITS=64 -D_FILE_OFFSET_BITS=64
+endef
+object-suffixes-left := $(all-object-suffixes)
+include $(o-iterator)
+
+ifeq ($(have-time64-compat),yes)
+tests += $(foreach t,$(tests-time64),$(t))
+xtests += $(foreach t,$(xtests-time64),$(t))
+endif
+
# The only difference between MODULE_NAME=testsuite and MODULE_NAME=nonlib is
# that almost all internal declarations from config.h, libc-symbols.h, and
# include/*.h are not available to 'testsuite' code, but are to 'nonlib' code.
diff --git a/io/Makefile b/io/Makefile
index d35e966258..ba8bd37355 100644
--- a/io/Makefile
+++ b/