summaryrefslogtreecommitdiff
path: root/tests/Makefile.am.in
diff options
context:
space:
mode:
authorJim Meyering <jim@meyering.net>1997-02-03 03:22:52 +0000
committerJim Meyering <jim@meyering.net>1997-02-03 03:22:52 +0000
commit704a69781e6abc1df9fb89741a4c07c6b17c8fc9 (patch)
tree2bd312ea214e5b8f56abd467a8a061c4ce49b2db /tests/Makefile.am.in
parent5f24ab538fb4a185f80085a308f86510de0a0e2d (diff)
downloadcoreutils-704a69781e6abc1df9fb89741a4c07c6b17c8fc9.tar.xz
.
Diffstat (limited to 'tests/Makefile.am.in')
-rw-r--r--tests/Makefile.am.in38
1 files changed, 38 insertions, 0 deletions
diff --git a/tests/Makefile.am.in b/tests/Makefile.am.in
new file mode 100644
index 000000000..a8c0eca3f
--- /dev/null
+++ b/tests/Makefile.am.in
@@ -0,0 +1,38 @@
+## Process this file with automake to produce Makefile.in.
+
+##test-files-begin
+##test-files-end
+
+EXTRA_DIST = mk-script.pl Test.pm $x-tests $(explicit) $(maint_gen)
+noinst_SCRIPTS = $x-tests
+
+PERL = @PERL@
+editpl = sed -e 's,@''PERL''@,$(PERL),g' -e 's,@''srcdir''@,@srcdir@,g'
+
+TESTS = $x-tests
+
+$x-tests: @MAINT@mk-script Test.pm
+ ./mk-script ../../src/$x > $@.n
+ mv $@.n $@
+ chmod 755 $@
+
+SUFFIXES = .pl
+
+.pl:
+ rm -f $@ $@.tmp
+ $(editpl) $< > $@.tmp
+ chmod +x-w $@.tmp
+ mv $@.tmp $@
+
+MAINTAINERCLEANFILES = $x-tests $(maint_gen)
+CLEANFILES = $(run_gen)
+
+@MAINT@rebuild-check: Test.pm mk-script
+@MAINT@ rb=rb-check; rm -f $rb; \
+@MAINT@ m_template=../Makefile.am.in; \
+@MAINT@ sed -n '1,/^##test-files-begin/p' $$m_template > $$rb; \
+@MAINT@ tool=`echo $(subdir)|sed 's/^tests.//;s/-test//'`; \
+@MAINT@ echo "x = $$tool" >> $$rb; \
+@MAINT@ ./mk-script --list >> $$rb; \
+@MAINT@ sed -n '/^##test-files-end/,$$p' $$m_template >> $$rb; \
+@MAINT@ diff -u Makefile.am $$rb && echo ok || echo no