summaryrefslogtreecommitdiff
path: root/package/evemu/evemu-0002-configure.ac-add-disable-tests-option.patch
blob: cbc025da6fbdcc16338ed8f869337c8ea18fe7a7 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
From 077722193e4e59e76591abbaddac9d22068be4e6 Mon Sep 17 00:00:00 2001
From: Peter Seiderer <ps.report@gmx.net>
Date: Sun, 27 Apr 2014 13:14:51 +0200
Subject: [PATCH] configure.ac: add '--disable-tests' option

Signed-off-by: Peter Seiderer <ps.report@gmx.net>
---
 Makefile.am  | 2 +-
 configure.ac | 9 +++++++++
 2 files changed, 10 insertions(+), 1 deletion(-)

diff --git a/Makefile.am b/Makefile.am
index 7b68f3d..a83b35f 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -1,4 +1,4 @@
-SUBDIRS = src tools python test
+SUBDIRS = src tools python $(SUBDIR_TESTS)
 
 pkgconfigdir = $(libdir)/pkgconfig
 pkgconfig_DATA = evemu.pc
diff --git a/configure.ac b/configure.ac
index ec21a6e..4e0c3b8 100644
--- a/configure.ac
+++ b/configure.ac
@@ -43,6 +43,15 @@ if test "x$XMLTO" = "x" || test "x$ASCIIDOC" = "x"; then
 	AC_MSG_WARN([xmlto or asciidoc not found - cannot create man pages without it])
 fi
 
+AC_ARG_ENABLE([tests],
+	AS_HELP_STRING([--disable-tests], [Disable running tests]))
+
+AS_IF([test "x$enable_tests" != "xno"], [
+	SUBDIR_TESTS=test
+])
+
+AC_SUBST([SUBDIR_TESTS])
+
 AC_SUBST(AM_CFLAGS,
          "-Wall -Wextra -pedantic")
 
-- 
1.8.1.4