[cfe-dev] Optimized build
Peter Collingbourne
peter at pcc.me.uk
Mon Sep 16 14:32:28 PDT 2013
On Mon, Sep 16, 2013 at 05:03:31PM -0400, George Kastrinis wrote:
> I try to make a build directory with optimization in mind. But instead of
>
> ../llvm/configure --enable-optimized --disable-assertions
>
> I want to use cmake and ninja afterwards. I have tried various things but I
> can't achieve what I want. cmake recognizes a variable for assertions
> (LLVM_ENABLE_ASSERTIONS=OFF) but I can't find something similar for
> optimizations.
>
> Is it possible to achieve what I try with ninja?
You can use -DCMAKE_BUILD_TYPE=Release to create a release build.
That turns on optimisations and turns off assertions by default;
LLVM_ENABLE_ASSERTIONS can be used to independently control assertions.
Thanks,
--
Peter
More information about the cfe-dev
mailing list