Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How could I change boost release variant to use cxxflags=-O2?

On my machine cxxflags for variant=release is -O3 by default.
I need to change it to -O2. Please advise how to proceed.

I am fine with defining a new variant as well, if someone could advise me on that.

like image 945
Humble Debugger Avatar asked Sep 03 '10 13:09

Humble Debugger


1 Answers

Just use:

<variant>release:<cxxflags>-O2

as requirements on top-level project. Options specified with cxxflags are passed to gcc after all the other options, so -O3 will be overridden.

like image 152
Vladimir Prus Avatar answered Oct 01 '22 21:10

Vladimir Prus