aboutsummaryrefslogtreecommitdiff
path: root/configure.ac
diff options
context:
space:
mode:
Diffstat (limited to 'configure.ac')
-rw-r--r--configure.ac90
1 files changed, 58 insertions, 32 deletions
diff --git a/configure.ac b/configure.ac
index 815c040b0..b720be535 100644
--- a/configure.ac
+++ b/configure.ac
@@ -714,61 +714,87 @@ AC_SUBST(EXT_LIB_PATH)
714 714
715# should 'make check' run tests? 715# should 'make check' run tests?
716AC_MSG_CHECKING(whether to run tests) 716AC_MSG_CHECKING(whether to run tests)
717AC_ARG_ENABLE(testruns, 717AC_ARG_ENABLE([testruns],
718 [AS_HELP_STRING([--enable-testruns=yes/no], 718 [AS_HELP_STRING([--disable-testruns], [disable running tests on make check (default is YES)])],
719 [disable running tests on make check (default is YES)])], 719 [enable_tests_run=${enableval}],
720 [enable_tests_run=$enableval], 720 [enable_tests_run=yes])
721 [enable_tests_run="yes"])
722AC_MSG_RESULT($enable_test_run) 721AC_MSG_RESULT($enable_test_run)
723AM_CONDITIONAL([DISABLE_TEST_RUN], [test "x$enable_tests_run" = "xno"]) 722AM_CONDITIONAL([ENABLE_TEST_RUN], [test "x$enable_tests_run" = "xyes"])
723
724# should expensive tests be run?
725AC_MSG_CHECKING(whether to run expensive tests)
726AC_ARG_ENABLE([expensivetests],
727 [AS_HELP_STRING([--enable-expensive-tests], [enable running expensive testcases])],
728 [enable_expensive=${enableval}],
729 [enable_expensive=no])
730AC_MSG_RESULT($enable_expensive)
731AM_CONDITIONAL([HAVE_EXPENSIVE_TESTS], [test "x$enable_expensive" = "xyes"])
732
733# should benchmarks be run?
734AC_MSG_CHECKING(whether to run benchmarks during make check)
735AC_ARG_ENABLE([benchmarks],
736 [AS_HELP_STRING([--enable-benchmarks], [enable running benchmarks during make check])],
737 [enable_benchmarks=${enableval}],
738 [enable_benchmarks=no])
739AC_MSG_RESULT($enable_benchmarks)
740AM_CONDITIONAL([HAVE_BENCHMARKS], [test "x$enable_benchmarks" = "xyes"])
724 741
725# should experimental code be compiled (code that may not yet compile)? 742# should experimental code be compiled (code that may not yet compile)?
726disable_experimental=yes
727AC_MSG_CHECKING(whether to compile experimental code) 743AC_MSG_CHECKING(whether to compile experimental code)
728AC_ARG_ENABLE(experimental, 744AC_ARG_ENABLE([experimental],
729 [AS_HELP_STRING([--enable-experimental], 745 [AS_HELP_STRING([--enable-experimental], [enable compiling experimental code])],
730 [enable compiling experimental code])], 746 [enable_experimental=${enableval}],
731 [enable_experimental=$enableval], 747 [enable_experimental=no])
732 [enable_experimental="no"])
733AC_MSG_RESULT($enable_experimental) 748AC_MSG_RESULT($enable_experimental)
734AM_CONDITIONAL([HAVE_EXPERIMENTAL], [test "x$enable_experimental" = "xyes"]) 749AM_CONDITIONAL([HAVE_EXPERIMENTAL], [test "x$enable_experimental" = "xyes"])
735 750
736# should malicious code be compiled (code used for testing with malicious peers) 751# should malicious code be compiled (code used for testing with malicious peers)
737enable_malicious=0
738AC_MSG_CHECKING(whether to compile malicious code) 752AC_MSG_CHECKING(whether to compile malicious code)
739AC_ARG_ENABLE(malicious, 753AC_ARG_ENABLE([malicious],
740 [AS_HELP_STRING([--enable-malicious], 754 [AS_HELP_STRING([--enable-malicious], [enable compiling malicious code (only for developers for testing)])],
741 [enable compiling malicious code (only for developers for testing)])], 755 [enable_malicious=${enableval}],
742 [enable_malicious=1], 756 [enable_malicious=no])
743 [enable_malicious=0])
744AC_MSG_RESULT($enable_malicious) 757AC_MSG_RESULT($enable_malicious)
745AM_CONDITIONAL([HAVE_MALICIOUS], [test "x$enable_malicious" = "x1"]) 758AM_CONDITIONAL([HAVE_MALICIOUS], [test "x$enable_malicious" = "xyes"])
746AC_DEFINE_UNQUOTED([HAVE_MALICIOUS], $enable_malicious, [Compile malicious code]) 759if test "$enable_malicious" = "yes"
760then
761 AC_DEFINE([HAVE_MALICIOUS],[1],[include malicious code])
762else
763 AC_DEFINE([HAVE_MALICIOUS],[0],[disable malicious code])
764fi
747 765
748# should code be enabled that works around missing OS functionality on Windows? 766# should code be enabled that works around missing OS functionality on Windows?
749# used for test cases 767# used for test cases
750AC_ARG_ENABLE(windows_workarounds, [AS_HELP_STRING([--enable-windows_workarounds],
751 [enable workarounds used on Windows (only useful for test cases)])])
752if test $build_target = "mingw" 768if test $build_target = "mingw"
753then 769then
754 workarounds=1 770 workarounds=1
755else 771else
756 if test x$enable_windows_workarounds = "xyes" 772 AC_MSG_CHECKING(whether to enable windows workarounds)
757 then 773 AC_ARG_ENABLE([windows_workarounds],
758 workarounds=1 774 [AS_HELP_STRING([--enable-windows_workarounds], [enable workarounds used on Windows (only useful for test cases)])],
759 else 775 [enable_workarounds=${enableval}],
760 workarounds=0 776 [enable_workarounds=no])
761 fi 777 AC_MSG_RESULT($enable_workarounds)
778 if test x$enable_windows_workarounds = "xyes"
779 then
780 workarounds=1
781 else
782 workarounds=0
783 fi
762fi 784fi
763AC_DEFINE_UNQUOTED([ENABLE_WINDOWS_WORKAROUNDS], $workarounds, [enable workarounds used on Windows (only useful for test cases)]) 785AC_DEFINE_UNQUOTED([ENABLE_WINDOWS_WORKAROUNDS], $workarounds, [enable workarounds used on Windows (only useful for test cases)])
764 786
765# gcov compilation 787# gcov compilation
766use_gcov=no 788AC_MSG_CHECKING(whether to compile with support for code coverage analysis)
767AC_ARG_ENABLE([coverage], AS_HELP_STRING([--enable-coverage], 789AC_ARG_ENABLE([coverage],
768 [Compile the library with code coverage support (default is NO)]), 790 AS_HELP_STRING([--enable-coverage],
769 [use_gcov=yes], [use_gcov=no]) 791 [compile the library with code coverage support]),
792 [use_gcov=${enableval}],
793 [use_gcov=no])
794AC_MSG_RESULT($use_gcov)
770AM_CONDITIONAL([USE_COVERAGE], [test "x$use_gcov" = "xyes"]) 795AM_CONDITIONAL([USE_COVERAGE], [test "x$use_gcov" = "xyes"])
771 796
797
772AC_CONFIG_FILES([ 798AC_CONFIG_FILES([
773Makefile 799Makefile
774contrib/Makefile 800contrib/Makefile