summaryrefslogtreecommitdiffstats
path: root/Makefile.am
diff options
context:
space:
mode:
Diffstat (limited to 'Makefile.am')
-rw-r--r--Makefile.am19
1 files changed, 18 insertions, 1 deletions
diff --git a/Makefile.am b/Makefile.am
index a82029d..0048520 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -59,7 +59,7 @@ bin_PROGRAMS = @
EXTRA_@_DEPENDENCIES = version.c
CLEANFILES = version.c
CONFIG_CLEAN_FILES =
-EXTRA_DIST = autogen.sh
+EXTRA_DIST = autogen.sh FORMATS
V_REDIR = $(V_REDIR_$(V))
V_REDIR_ = $(V_REDIR_$(AM_DEFAULT_VERBOSITY))
@@ -84,6 +84,23 @@ if IN_GIT
1>>'$(distdir)/ChangeLog~'
mv '$(distdir)/ChangeLog~' '$(distdir)/ChangeLog'
endif
+if ENABLE_TESTS
+if CROSS_COMPILING
+ if ! [ -f 'FORMATS' ]; then \
+ printf 'Error: "FORMATS" file cannot be generated when %s' \
+ 'cross compiling' 1>&2; \
+ exit 1; \
+ fi
+else !CROSS_COMPILING
+ $(srcdir)/@ -d '1969-12-31 19:00:01' -F 1>FORMATS
+endif !CROSS_COMPILING
+else !ENABLE_TESTS
+ if ! [ -f 'FORMATS' ]; then \
+ printf 'Error: "FORMATS" file cannot be generated without %s' \
+ 'test suite support' 1>&2; \
+ exit 1; \
+ fi
+endif !ENABLE_TESTS
release:
sed "s/^Released: ????-??-??\$$/Released: $$(date '+%Y-%m-%d')/" \