2 Convert a date/time string to linear time.
5 doc/parse-datetime.texi
36 # The Automake generated .y.c rule is broken: When executed in a VPATH build,
37 # - The .c file gets generated in the build directory. But since it requires
38 # special tools to rebuild it, we need to distribute it in the tarballs,
39 # and by the GNU Coding Standards
40 # <https://www.gnu.org/prep/standards/html_node/Makefile-Basics.html>
41 # the file should be generated in the source directory.
42 # - The #line directives in the .c file refer to a nonexistent file once it
43 # has been moved from the build directory to the source directory. This
44 # leads to error if 'lcov' is used later.
45 # Additionally, here we assume GNU Bison and therefore don't need the ylwrap
47 # Therefore we override this rule.
48 parse-datetime.c: parse-datetime.y
49 $(AM_V_YACC)$(PARSE_DATETIME_BISON) $(YFLAGS) $(AM_YFLAGS) $(srcdir)/parse-datetime.y \
50 && test ':' = '$(PARSE_DATETIME_BISON)' || { \
51 sed -e 's|".*/parse-datetime\.y"|"parse-datetime.y"|' \
52 -e 's|"parse-datetime\.tab\.c"|"parse-datetime.c"|' \
53 < parse-datetime.tab.c > parse-datetime.c-tmp \
54 && rm -f parse-datetime.tab.c \
55 && mv parse-datetime.c-tmp $(srcdir)/parse-datetime.c; \
57 lib_SOURCES += parse-datetime.y
58 BUILT_SOURCES += parse-datetime.c
59 MOSTLYCLEANFILES += parse-datetime.tab.c parse-datetime.c-tmp
60 MAINTAINERCLEANFILES += parse-datetime.c
61 EXTRA_DIST += parse-datetime.c