[ 
https://issues.apache.org/jira/browse/MESOS-2537?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14380493#comment-14380493
 ] 

Cody Maloney commented on MESOS-2537:
-------------------------------------

For this there are 4 supported configurations / combinations of flags which are 
explicitly supported (Note if you set CXXFLAGS at all manually neither 
--enable-optimize or --enable debug do anything).

`\-\-enable\-optimize` implies don't do debug info, and --enable-debug implies 
don't do base level optimization (-Og once that stabilizes in GCC eventually). 
So what someone would think they'd get via `\-\-enable\-optimize 
\-\-disable\-debug` or `\-\-disable\-debug \-\-enable\-optimize` they get with 
just `\-\-disable\-debug` and `\-\-enable\-optimize` respectively.

{code}
./configure
CFLAGS='-g1 -O0 -Wno-unused-local-typedefs'
CPPFLAGS='-I/usr/include/subversion-1 -I/usr/include/apr-1 
-I/usr/include/apr-1.0 '
CXXFLAGS='-g1 -O0 -Wno-unused-local-typedefs -std=c++11'
{code}

{code}
../configure --enable-debug
CFLAGS='-g -O0 -Wno-unused-local-typedefs'
CPPFLAGS='-I/usr/include/subversion-1 -I/usr/include/apr-1 
-I/usr/include/apr-1.0 '
CXXFLAGS='-g -O0 -Wno-unused-local-typedefs -std=c++11'
{code}

{code}
../configure --enable-optimize
CFLAGS=' -O2 -Wno-unused-local-typedefs'
CPPFLAGS='-I/usr/include/subversion-1 -I/usr/include/apr-1 
-I/usr/include/apr-1.0 '
CXXFLAGS=' -O2 -Wno-unused-local-typedefs -std=c++11'
{code}

{code}
../configure --enable-optimize --enable-debug
CFLAGS='-g -O2 -Wno-unused-local-typedefs'
CPPFLAGS='-I/usr/include/subversion-1 -I/usr/include/apr-1 
-I/usr/include/apr-1.0 '
CXXFLAGS='-g -O2 -Wno-unused-local-typedefs -std=c++11'
{code}

For the discussion of these choices see: https://reviews.apache.org/r/26426/

Note any changes to the mesos ones also need to be done (in a seperate patch) 
to libprocess.

> AC_ARG_ENABLED checks are broken
> --------------------------------
>
>                 Key: MESOS-2537
>                 URL: https://issues.apache.org/jira/browse/MESOS-2537
>             Project: Mesos
>          Issue Type: Bug
>          Components: build
>            Reporter: James Peach
>            Assignee: James Peach
>            Priority: Minor
>
> In a number of places, the Mesos configure script passes "$foo=yes" to the 
> 2nd argument of {{AC_ARG_ENABLED}}. However, the 2nd argument is invoked when 
> the option is provided in any form, not just when the {{\--enable-foo}} form 
> is used. One result of this is that {{\--disable-optimize}} doesn't work.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to