From ec928faad350e2aad957256fb47cb10277990738 Mon Sep 17 00:00:00 2001 From: Henning Garus Date: Fri, 15 Aug 2008 00:42:23 +0200 Subject: Add autotools magic for pactests Added a Makefile.am for the pactest/tests dir. This is a blatant ripoff of scripts/Makefile.am, which replaces predefined expressions in NAME.py.in pactests with configure variables. This can be used to write pactests which consider compile time options. Signed-off-by: Henning Garus [Dan: autotools are tough, make a few adjustments for correctness] Signed-off-by: Dan McGee --- pactest/tests/Makefile.am | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) create mode 100644 pactest/tests/Makefile.am (limited to 'pactest/tests') diff --git a/pactest/tests/Makefile.am b/pactest/tests/Makefile.am new file mode 100644 index 00000000..42ca5cbe --- /dev/null +++ b/pactest/tests/Makefile.am @@ -0,0 +1,26 @@ +CONFTESTS = $(patsubst %py.in,%py,$(wildcard *.py.in)) + +check_SCRIPTS = \ + $(wildcard *.py) \ + $(CONFTESTS) + +noinst_SCRIPTS = $(check_SCRIPTS) + +EXTRA_DIST = $(check_SCRIPTS) + +CLEANFILES = $(CONFTESTS) + +#### Taken from the autoconf scripts Makefile.am #### +edit = sed \ + -e 's|@LIBS[@]|$(LIBS)|g' \ + -e 's|@configure_input[@]|Generated from $@.in; do not edit by hand.|g' + + +$(CONFTESTS): Makefile + rm -f $@ $@.tmp + test -f $(srcdir)/$@.in && $(edit) $(srcdir)/$@.in >$@.tmp || true + test -f $@.tmp || false + chmod a-w $@.tmp + mv $@.tmp $@ + +# vim:set ts=2 sw=2 noet: -- cgit v1.2.3-24-g4f1b