summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorКоролев Сергей <korolev.sergey@gmail.com>2016-05-11 22:48:55 +0300
committerDave Watson <davejwatson@fb.com>2017-01-13 08:27:39 -0800
commit208a430bcbab7d63a4c04242f13c4740e0246a56 (patch)
treef8246949f9670633ac8ce3fef8cff0114f19457c
parentad0d7633bc9d18d752423d0cf47096e39bd4d0f1 (diff)
downloadlibunwind-208a430bcbab7d63a4c04242f13c4740e0246a56.tar.gz
add --disable-tests option
Allows to skip tests build.
-rw-r--r--Makefile.am6
-rw-r--r--configure.ac13
2 files changed, 16 insertions, 3 deletions
diff --git a/Makefile.am b/Makefile.am
index 6a3ed9e7..0c29b3ea 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -42,7 +42,11 @@ endif
nodist_include_HEADERS = include/libunwind-common.h
-SUBDIRS = src tests
+SUBDIRS = src
+
+if CONFIG_TESTS
+SUBDIRS += tests
+endif
if CONFIG_DOCS
SUBDIRS += doc
diff --git a/configure.ac b/configure.ac
index 863fb8f4..6c46cf35 100644
--- a/configure.ac
+++ b/configure.ac
@@ -129,6 +129,10 @@ AC_ARG_ENABLE(documentation,
AS_HELP_STRING([--disable-documentation],[Disable generating the man pages]),,
[enable_documentation=yes])
+AC_ARG_ENABLE(tests,
+ AS_HELP_STRING([--disable-tests],[Disable tests build]),,
+ [enable_tests=yes])
+
AC_MSG_CHECKING([if we should build libunwind-setjmp])
AC_MSG_RESULT([$enable_setjmp])
@@ -396,8 +400,13 @@ if test "x$enable_documentation" = "xyes"; then
AC_CONFIG_FILES(doc/Makefile doc/common.tex)
fi
-AC_CONFIG_FILES(Makefile src/Makefile tests/Makefile tests/check-namespace.sh
- include/libunwind-common.h
+AM_CONDITIONAL([CONFIG_TESTS], [test x$enable_tests = xyes])
+if test "x$enable_tests" = "xyes"; then
+ AC_CONFIG_FILES(tests/Makefile tests/check-namespace.sh)
+fi
+
+AC_CONFIG_FILES(Makefile src/Makefile
+ include/libunwind-common.h
include/libunwind.h include/tdep/libunwind_i.h)
AC_CONFIG_FILES(src/unwind/libunwind.pc src/coredump/libunwind-coredump.pc
src/ptrace/libunwind-ptrace.pc src/setjmp/libunwind-setjmp.pc