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

  • From: Diego Biurrun <diego@xxxxxxxxxx>
  • To: pisa-src@xxxxxxxxxxxxx
  • Date: Thu, 29 Oct 2009 17:42:54 +0100

Author: biurrun
Date: Thu Oct 29 17:42:53 2009
New Revision: 1426

Log:
Add -Werror to compiler flags when HIPL is not enabled.

Modified:
   trunk/configure.ac

Modified: trunk/configure.ac
==============================================================================
--- trunk/configure.ac  Thu Oct 29 17:34:51 2009        (r1425)
+++ trunk/configure.ac  Thu Oct 29 17:42:53 2009        (r1426)
@@ -121,11 +121,16 @@
 AC_SUBST(PISA_HIPL_SRCDIR, "$ac_cv_hipl_dir")
 fi
 
+# Set default CFLAGS for the complete project.
+AC_SUBST(CFLAGS, "$CFLAGS -g -O2 -Wall -Wextra")
+
 if test -d "$PISA_HIPL_SRCDIR"; then
        AC_DEFINE(CONFIG_PISA_WITH_HIPL, AC_PREREQ(2.53))
        AH_TEMPLATE(CONFIG_PISA_WITH_HIPL)
        pisa_with_hipl=yes
 else
+        # HIPL generates many warnings, so we cannot enable -Werror with it.
+        AC_SUBST(CFLAGS, "$CFLAGS -Werror")
        AC_MSG_WARN("HIPL source tree cannot be found. So you could encounter 
some problems when hipl-related parts of codes are executed.")
        AC_MSG_WARN("Try giving a correct path to the hipl source tree with the 
--with-hipl option. You can see usage with ./configure -h.")
        pisa_with_hipl=no
@@ -150,9 +155,6 @@
 # Our configuration files should be located in a subdirectory of their own.
 AC_SUBST(sysconfdir, ${sysconfdir}/pisa)
 
-# Set default CFLAGS for the complete project.
-AC_SUBST(CFLAGS, "$CFLAGS -g -O2 -Wall -Wextra")
-
 # This is needed to export the _expanded_ value of the variable to config.h.
 AC_DEFINE_UNQUOTED(PISA_SYSCONFDIR, "$(eval echo $sysconfdir)")
 AH_TEMPLATE([PISA_SYSCONFDIR])

Other related posts:

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