summaryrefslogtreecommitdiffstats
path: root/Makefile
diff options
context:
space:
mode:
authorKaz Kylheku <kaz@kylheku.com>2009-12-02 22:47:03 -0800
committerKaz Kylheku <kaz@kylheku.com>2009-12-02 22:47:03 -0800
commita14cf42f0b9de88aa5b8a68b8f594fcfc6048350 (patch)
treeb71ffaebdae9ad4bee509f4a9fbefd20229b9b72 /Makefile
parent24d5bf1de3e64c3ddb24199cbc6e9c194a03887e (diff)
downloadtxr-a14cf42f0b9de88aa5b8a68b8f594fcfc6048350.tar.gz
txr-a14cf42f0b9de88aa5b8a68b8f594fcfc6048350.tar.bz2
txr-a14cf42f0b9de88aa5b8a68b8f594fcfc6048350.zip
* Makefile (install-tests): New target. Provides a way to make the
test cases part of the installation, and a generated script to run the commands on the installation host.
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile12
1 files changed, 12 insertions, 0 deletions
diff --git a/Makefile b/Makefile
index e756e35c..b166b12d 100644
--- a/Makefile
+++ b/Makefile
@@ -118,6 +118,18 @@ install: $(PROG)
$(call INSTALL,0755,txr,$(DESTDIR)$(bindir))
$(call INSTALL,0444,$(top_srcdir)/txr.1,$(DESTDIR)$(mandir)/man1)
+#
+# Install the tests as well as the script to run them
+#
+install-tests:
+ cd $(top_srcdir) ; find tests -name '*.out' -prune -o -print | cpio -pd $(DESTDIR)$(datadir)
+ ( echo "#!/bin/sh" ; \
+ echo "set -ex" ; \
+ echo "cd $(datadir)" ; \
+ make -s -n tests top_srcdir=. PROG=$(bindir)/txr ) \
+ > run.sh
+ $(call INSTALL,0755,run.sh,$(DESTDIR)$(datadir)/tests)
+
config.make config.h:
@echo "$@ missing: you didn't run ./configure"
@exit 1