octave-maintainers
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: having trouble with XTRA_CFLAGS showing up on AM_CXXFLAGS


From: John W. Eaton
Subject: Re: having trouble with XTRA_CFLAGS showing up on AM_CXXFLAGS
Date: Sun, 07 Feb 2016 02:34:54 -0500
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:31.0) Gecko/20100101 Icedove/31.7.0

On 02/06/2016 10:42 PM, Carnë Draug wrote:
Hi

I've been playing around with our configure and I'm having a problem
that maybe someone can help me with.

I'm adding a flag to XTRA_CFLAGS in our configure script and it seems to
somehow be creeping into AM_CXXFLAGS.  The weird thing is that looking into
the generate Makefiled, it is not there.  However, when I run "make -n", I
see it showing up in AM_CXXFLAGS.

Here's what I've been doing.  I've been adding the following lines to
configure.ac:

     XTRA_CFLAGS="$XTRA_CFLAGS -std=c11"
     XTRA_CXXFLAGS="$XTRA_CXXFLAGS -std=c++11"
     CFLAGS="$CFLAGS -std=c11"
     CXXFLAGS="$CXXFLAGS -std=c++11"

After running configure, everything looks fine, the displayed resume
looks correct.  However, once the build actually starts I get warnings
like:

       GEN      libinterp/octave-value/ov-flt-re-mat.df
     cc1plus: warning: command line option ‘-std=c11’ is valid for
C/ObjC but not for C++

And indeed, running "make -n", I get g++ being called with -std=c11.  For
example, the recipe for octave-value/ov-flt-re-mat.df

     g++ -E -DHAVE_CONFIG_H -I. -I/home/carandraug/dev/octave  \
       -I. [....] \
       -std=c11 -pthread -fopenmp [...] \
       [...]
     mv libinterp/octave-value/ov-flt-re-mat.df-t
libinterp/octave-value/ov-flt-re-mat.df

Anyone can explain me what I'm doing wrong?

Oops, I fixed it in this changeset:

  http://hg.savannah.gnu.org/hgweb/octave/rev/b7a191eb0c3c

Thanks.

jwe





reply via email to

[Prev in Thread] Current Thread [Next in Thread]