commit: 8f36aaf184fd8aeb5387d51f22246179b6dd349c
Author: Michael Orlitzky <mjo <AT> gentoo <DOT> org>
AuthorDate: Sun Jun 18 13:43:45 2017 +0000
Commit: Michael Orlitzky <mjo <AT> gentoo <DOT> org>
CommitDate: Fri Aug 11 15:25:25 2017 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=8f36aaf1
apache-2.eclass: don't enable maintainer-mode with USE=debug.
The --enable-maintainer-mode flag serves two purposes: first, it
enables compile-time warnings; and second, it forces all compiled
modules to be loaded at runtime. To achieve the first goal, the build
system checks for the "-std=c89" compiler flag and appends it to
CFLAGS if found. This can cause a problem later, because the CFLAGS
used to build apache are used by apxs to build extension modules.
In particular, if you have an extension that relies on C99 or some
later standard, and if apache was built with --enable-maintainer-mode,
then apxs will attempt to build that extension according to C89 and
fail. This failure can be observed in in bugs 621686, 621756, and
621794 when apache is built with USE=debug, because USE=debug sets
the --enable-maintainer-mode flag.
Since there is not much reason for an end user to enable maintainer-
mode, the simplest fix for this is the wholesale removal of the
--enable-maintainer-mode flag from USE=debug. This prevents us from
having to append CFLAGS to each extension package that uses a later
standard, or from having to add a USE dependency forbidding USE=debug
in apache (which would create conflicts with e.g. mod_backtrace).
Gentoo-Bug: 621686
Gentoo-Bug: 621756
Gentoo-Bug: 621794
eclass/apache-2.eclass | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/eclass/apache-2.eclass b/eclass/apache-2.eclass
index 78a7c5ce474..dbd55abe8c9 100644
--- a/eclass/apache-2.eclass
+++ b/eclass/apache-2.eclass
@@ -1,4 +1,4 @@
-# Copyright 1999-2015 Gentoo Foundation
+# Copyright 1999-2017 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# @ECLASS: apache-2.eclass
@@ -402,7 +402,7 @@ apache-2_pkg_setup() {
setup_modules
if use debug; then
- MY_CONF+=( --enable-maintainer-mode --enable-exception-hook )
+ MY_CONF+=( --enable-exception-hook )
fi
elog "Please note that you need SysV IPC support in your kernel."