From 312918e68d4410359b55258dc2b9e9cdfb21f211 Mon Sep 17 00:00:00 2001 From: Morgan Deters Date: Wed, 8 Jan 2014 15:27:26 -0500 Subject: Switch license default back to BSD, and add --best and --enable-gpl options. --- config/cvc4.m4 | 30 ++++++++++++++++++++++++++++-- 1 file changed, 28 insertions(+), 2 deletions(-) (limited to 'config/cvc4.m4') diff --git a/config/cvc4.m4 b/config/cvc4.m4 index 4b8b2e342..7c2f6c82d 100644 --- a/config/cvc4.m4 +++ b/config/cvc4.m4 @@ -13,11 +13,37 @@ dnl _AS_ME_PREPARE AC_DEFUN([CVC4_REWRITE_ARGS_FOR_BUILD_PROFILE], [m4_divert_push([PARSE_ARGS])dnl +CVC4_BSD_LICENSED_CODE_ONLY=1 + +m4_divert_once([HELP_ENABLE], [[ +Licensing and performance options: + --bsd disable all GPL dependences (default) + --enable-gpl permit GPL dependences, if available + --best turn on dependences known to give best performance]])dnl + handle_option() { ac_option="$[]1" case $ac_option in - --bsd) ac_option='CVC4_BSD_LICENSED_CODE_ONLY=1' ;; - -*|*=*) ;; + --bsd|--disable-gpl|CVC4_BSD_LICENSED_CODE_ONLY=1) + if test "$CVC4_LICENSE_OPTION" = gpl; then AC_ERROR([cannot give both --bsd and --enable-gpl]); fi + CVC4_LICENSE_OPTION=bsd + ac_option="CVC4_BSD_LICENSED_CODE_ONLY=1" + eval $ac_option + ;; + --enable-gpl|--gpl|CVC4_BSD_LICENSED_CODE_ONLY=0) + if test "$CVC4_LICENSE_OPTION" = bsd; then AC_ERROR([cannot give both --bsd and --enable-gpl]); fi + CVC4_LICENSE_OPTION=gpl + ac_option="CVC4_BSD_LICENSED_CODE_ONLY=0" + eval $ac_option + ;; + --best) + # set the best configuration + handle_option --with-readline + handle_option --with-cln + return + ;; + -*|*=*) + ;; production|production-*|debug|debug-*|competition|competition-*) # regexp `\?' not supported on Mac OS X ac_option_build=`expr "$ac_option" : '\([[^-]]*\)-\{0,1\}'` -- cgit v1.2.3