I have been looking and looking until my eyes have started to cross.

Here's my problem.

The only way I have been able to affect an entire build of GCC, for
example in order to do a "-ggdb -O0" build of the entire compiler and its
libraries, has been to do something like this:

        mkdir build
        cd build
        CFLAGS="-ggdb -O0" CXXFLAGS="-ggdb - O0" ../configure ...

However, one thing I want to be able to do when developing the COBOL front
end is:

        CXXFLAGS="-ggdb -O0 -std=C++17" ../configure ...

That results in a build failure because libcody gets upset when the
standard isn't c++11

Okay.  So, I tried setting CXXFLAGS_FOR_BUILD, which as far as I know is
not supposed to affect libraries.  Jumping ahead a bit, I tried this:

        CXXFLAGS_FOR_BUILD="-DDUBNER_HARMLESS"

I then did a complete --disable-bootstrap build and saved the output of
the make.  The text DUBNER_HARMLESS did not appear anywhere in the output.
I have determined that the environment variable
CXXFLAGS_FOR_BUILD="-DDUBNER_HARMLESS" is  definitely present at the point
where gcc/cobol/xxxx.cc files are being compiled.  But it's not finding
its way into the command line for the compilation.

This raises two, presumably related, questions.  

1) What is CXXFLAGS_FOR_BUILD supposed to be doing?

2) How can I set compilation switches for gcc stuff (like the gcc/cobol
front end) without affecting lib*** stuff?

Thanks.

Reply via email to