* m4/include_next.m4 (gl_INCLUDE_NEXT): Define and AC_SUBST
[gnulib.git] / modules / sys_time
1 Description:
2 A <sys/time.h> that conforms better to POSIX.
3
4 Files:
5 lib/sys_time_.h
6 m4/sys_time_h.m4
7
8 Depends-on:
9 include_next
10
11 configure.ac:
12 gl_HEADER_SYS_TIME_H
13 AC_PROG_MKDIR_P
14
15 Makefile.am:
16 BUILT_SOURCES += $(SYS_TIME_H)
17
18 # We need the following in order to create <sys/time.h> when the system
19 # doesn't have one that works with the given compiler.
20 sys/time.h: sys_time_.h
21         @MKDIR_P@ sys
22         rm -f $@-t $@
23         { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \
24           sed -e 's/@''HAVE_SYS_TIME_H''@/$(HAVE_SYS_TIME_H)/g' \
25               -e 's/@''INCLUDE_NEXT''@/$(INCLUDE_NEXT)/g' \
26               -e 's|@''NEXT_SYS_TIME_H''@|$(NEXT_SYS_TIME_H)|g' \
27               -e 's/@''REPLACE_GETTIMEOFDAY''@/$(REPLACE_GETTIMEOFDAY)/g' \
28               -e 's/@''HAVE_STRUCT_TIMEVAL''@/$(HAVE_STRUCT_TIMEVAL)/g' \
29               < $(srcdir)/sys_time_.h; \
30         } > $@-t
31         mv $@-t $@
32 MOSTLYCLEANFILES += sys/time.h sys/time.h-t
33
34 Include:
35 #include <sys/time.h>
36
37 License:
38 LGPL
39
40 Maintainer:
41 all