From bf82c69f1090226e136ef93fcf63c3222e52e3fa Mon Sep 17 00:00:00 2001 From: Mat Martineau Date: Tue, 9 Aug 2016 15:32:56 -0700 Subject: [PATCH] build: Undef _FORTIFY_SOURCE for unoptimized builds './configure --disable-optimization --enable-maintainer-mode' would result in build errors. _FORTIFY_SOURCE requires that optimization is enabled and issues a compile-time warning which is treated as an error. Disabling optimization takes precedence over fortification in this case, since it is being explicitly requested. --- configure.ac | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/configure.ac b/configure.ac index 6e6d36d8..46984225 100644 --- a/configure.ac +++ b/configure.ac @@ -30,7 +30,7 @@ LT_INIT([disable-static]) AC_ARG_ENABLE(optimization, AC_HELP_STRING([--disable-optimization], [disable code optimization through compiler]), [ if (test "${enableval}" = "no"); then - CFLAGS="$CFLAGS -O0" + CFLAGS="$CFLAGS -U_FORTIFY_SOURCE -O0" fi ])