[pisa-src] r1575 - trunk/configure.ac

  • From: Diego Biurrun <diego@xxxxxxxxxx>
  • To: pisa-src@xxxxxxxxxxxxx
  • Date: Sat, 07 Nov 2009 20:49:16 +0100

Author: biurrun
Date: Sat Nov  7 20:49:16 2009
New Revision: 1575

Log:
Replace weird use of $ac_cv_use_foo by $enable_foo.
enable_foo variables are automatically set when invoking AC_ARG_ENABLE(foo).
Variables with an ac_ prefix are reserved for autoconf and variables nameed
*_cv_* are reserved for cached results, thus the previous naming polluted
namespaces without reason.

Modified:
   trunk/configure.ac

Modified: trunk/configure.ac
==============================================================================
--- trunk/configure.ac  Sat Nov  7 20:37:36 2009        (r1574)
+++ trunk/configure.ac  Sat Nov  7 20:49:16 2009        (r1575)
@@ -48,7 +48,7 @@
              [ac_cv_use_debug=yes])
 AC_CACHE_CHECK([whether to have verbose debug],
                [ac_cv_use_debug], [ac_cv_use_debug=yes])
-if test x"$ac_cv_use_debug" = x"yes"; then
+if test x"$enable_debug" = x"yes"; then
         AC_DEFINE(CONFIG_PISA_DEBUG)
         AH_TEMPLATE(CONFIG_PISA_DEBUG)
 fi
@@ -60,11 +60,11 @@
              [ac_cv_use_performance=no])
 AC_CACHE_CHECK([whether to use performance measurement],
                [ac_cv_use_performance], [ac_cv_use_performance=no])
-if test x"$ac_cv_use_performance" = x"yes"; then
+if test x"$enable_performance" = x"yes"; then
         AC_DEFINE(CONFIG_PISA_PERFORMANCE)
         AH_TEMPLATE(CONFIG_PISA_PERFORMANCE)
 fi
-AM_CONDITIONAL(PISA_PERFORMANCE, test x"$ac_cv_use_performance" = x"yes")
+AM_CONDITIONAL(PISA_PERFORMANCE, test x"$enable_performance" = x"yes")
 
 AC_ARG_ENABLE(logging,
              AC_HELP_STRING([--enable-logging],
@@ -73,11 +73,11 @@
              [ac_cv_use_logging=no])
 AC_CACHE_CHECK([whether to use logging],
                [ac_cv_use_logging], [ac_cv_use_logging=no])
-if test x"$ac_cv_use_logging" = x"yes"; then
+if test x"$enable_logging" = x"yes"; then
         AC_DEFINE(CONFIG_PISA_LOGGING)
         AH_TEMPLATE(CONFIG_PISA_LOGGING)
 fi
-AM_CONDITIONAL(PISA_LOGGING, test x"$ac_cv_use_logging" = x"yes")
+AM_CONDITIONAL(PISA_LOGGING, test x"$enable_logging" = x"yes")
 
 AC_ARG_ENABLE(openwrt,
              AC_HELP_STRING([--enable-openwrt],
@@ -86,7 +86,7 @@
              [ac_cv_use_openwrt=no])
 AC_CACHE_CHECK([whether to use OpenWRT],
                [ac_cv_use_openwrt], [ac_cv_use_openwrt=no])
-if test x"$ac_cv_use_openwrt" = x"yes"; then
+if test x"$enable_openwrt" = x"yes"; then
         AC_DEFINE(CONFIG_PISA_OPENWRT)
         AH_TEMPLATE(CONFIG_PISA_OPENWRT)
         AC_SUBST(OPENWRT_CFLAGS, "-lc")

Other related posts:

  • » [pisa-src] r1575 - trunk/configure.ac - Diego Biurrun