Repository: mesos Updated Branches: refs/heads/master 322cb8b77 -> 89969592a
Short term fix for false uninitialized erros due to bug in gcc. Review: https://reviews.apache.org/r/33915 Project: http://git-wip-us.apache.org/repos/asf/mesos/repo Commit: http://git-wip-us.apache.org/repos/asf/mesos/commit/89969592 Tree: http://git-wip-us.apache.org/repos/asf/mesos/tree/89969592 Diff: http://git-wip-us.apache.org/repos/asf/mesos/diff/89969592 Branch: refs/heads/master Commit: 89969592a8604f293fc67f7950904aa4bb07d705 Parents: 322cb8b Author: Vinod Kone <[email protected]> Authored: Wed May 6 14:18:15 2015 -0700 Committer: Vinod Kone <[email protected]> Committed: Wed May 6 14:34:28 2015 -0700 ---------------------------------------------------------------------- configure.ac | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/mesos/blob/89969592/configure.ac ---------------------------------------------------------------------- diff --git a/configure.ac b/configure.ac index 14658f6..fa53bbd 100644 --- a/configure.ac +++ b/configure.ac @@ -563,11 +563,13 @@ if test "x$CLANG" = "xno"; then AC_MSG_ERROR([GCC 4.8 or higher is required for compiling Mesos]) fi - # Disable 'maybe-uninitialized' warning when using 'enable-optimize' - # flag due to MESOS-2690. - if test "x$enable_optimize" = "xyes"; then - CXXFLAGS="${CXXFLAGS} -Wno-maybe-uninitialized" - fi + # Disable 'maybe-uninitialized' warning when "-O2" is enabled due + # to MESOS-2690. This is short term fix until the GCC bug is fixed. + case $CXXFLAGS in + *-O2*) CXXFLAGS="${CXXFLAGS} -Wno-maybe-uninitialized" ;; + *) ;; + esac + else # CLANG=yes # Check if -Wno-unused-local-typedef is needed by checking a sample # compilation which contains a local unused typedef.
