2 A <sys/time.h> that conforms better to POSIX.
20 BUILT_SOURCES += sys/time.h
22 # We need the following in order to create <sys/time.h> when the system
23 # doesn't have one that works with the given compiler.
24 sys/time.h: sys_time.in.h $(top_builddir)/config.status $(CXXDEFS_H) $(ARG_NONNULL_H) $(WARN_ON_USE_H)
25 $(AM_V_at)$(MKDIR_P) sys
26 $(AM_V_GEN)rm -f $@-t $@ && \
27 { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \
28 sed -e 's|@''GUARD_PREFIX''@|${gl_include_guard_prefix}|g' \
29 -e 's/@''HAVE_SYS_TIME_H''@/$(HAVE_SYS_TIME_H)/g' \
30 -e 's|@''INCLUDE_NEXT''@|$(INCLUDE_NEXT)|g' \
31 -e 's|@''PRAGMA_SYSTEM_HEADER''@|@PRAGMA_SYSTEM_HEADER@|g' \
32 -e 's|@''PRAGMA_COLUMNS''@|@PRAGMA_COLUMNS@|g' \
33 -e 's|@''NEXT_SYS_TIME_H''@|$(NEXT_SYS_TIME_H)|g' \
34 -e 's/@''GNULIB_GETTIMEOFDAY''@/$(GNULIB_GETTIMEOFDAY)/g' \
35 -e 's|@''HAVE_WINSOCK2_H''@|$(HAVE_WINSOCK2_H)|g' \
36 -e 's/@''HAVE_GETTIMEOFDAY''@/$(HAVE_GETTIMEOFDAY)/g' \
37 -e 's/@''HAVE_STRUCT_TIMEVAL''@/$(HAVE_STRUCT_TIMEVAL)/g' \
38 -e 's/@''REPLACE_GETTIMEOFDAY''@/$(REPLACE_GETTIMEOFDAY)/g' \
39 -e 's/@''REPLACE_STRUCT_TIMEVAL''@/$(REPLACE_STRUCT_TIMEVAL)/g' \
40 -e '/definitions of _GL_FUNCDECL_RPL/r $(CXXDEFS_H)' \
41 -e '/definition of _GL_ARG_NONNULL/r $(ARG_NONNULL_H)' \
42 -e '/definition of _GL_WARN_ON_USE/r $(WARN_ON_USE_H)' \
43 < $(srcdir)/sys_time.in.h; \
46 MOSTLYCLEANFILES += sys/time.h sys/time.h-t