3a408e1056a065acaffc8aa223f3089e76c09b1e
[gnulib.git] / m4 / header.m4
1 # Like AC_CONFIG_HEADER, but automatically create stamp file.
2
3 AC_DEFUN(AM_CONFIG_HEADER,
4 [AC_PREREQ([2.12])
5 AC_CONFIG_HEADER([$1])
6 dnl When config.status generates a header, we must update the stamp-h file.
7 dnl This file resides in the same directory as the config header
8 dnl that is generated.  We must strip everything past the first ":",
9 dnl and everything past the last "/".
10 AC_OUTPUT_COMMANDS(changequote(<<,>>)dnl
11 test -z "<<$>>CONFIG_HEADERS" || echo timestamp > patsubst(<<$1>>, <<^\([^:]*/\)?.*>>, <<\1>>)stamp-h<<>>dnl
12 changequote([,]))])