Gentoo Archives: gentoo-dev

From: Christoph Junghans <junghans@g.o>
To: gentoo-dev@l.g.o
Subject: Re: [gentoo-dev] cmake + ninja vs autotools
Date: Thu, 16 Nov 2017 13:45:01
Message-Id: CANgp9kwAqQ7CVKjarnjhZ9_ZxKJP-GZW4Mf5H+JXQeWFyFnUoA@mail.gmail.com
In Reply to: Re: [gentoo-dev] cmake + ninja vs autotools by Brian Evans
1 On Nov 16, 2017 6:29 AM, "Brian Evans" <grknight@g.o> wrote:
2
3 On 11/15/2017 10:27 PM, William L. Thomson Jr. wrote:
4 > It maybe worth considering switching the default generator in the
5 > cmake-utils.eclass from the default of emake to ninja.
6 >
7 > - : ${CMAKE_MAKEFILE_GENERATOR:=emake}
8 > + : ${CMAKE_MAKEFILE_GENERATOR:=ninja}
9 >
10 > For those with cmake ebuilds you can test this out now via
11 >
12 > CMAKE_MAKEFILE_GENERATOR="ninja"
13 > inherit cmake-utils
14 >
15 > Working with both cmake and meson. It seems the real performance of
16 > meson comes from ninja. I am a bit more a fan of cmake than meson for
17 > cpack, generation of deb, rpm, and binary tarball, in addition to
18 > sources. That can be done with meson but not as elegantly at this time.
19 >
20 > ninja is noticeably faster than make. I haven't seen any cases yet where
21 > cmake autotools works, and ninja does not. They seem pretty equal, so
22 > should be safe. Of course could use testing first.
23
24 There are still cases where ninja fails...
25
26 Ninja doesn't support Fortran as well.
27
28
29 I have forcefully set emake in dev-db/{mysql,mysql-cluster} because they
30 fail to build with ninja (using the cmake generator) yet emake works
31 just fine.
32
33 Brian

Replies

Subject Author
Re: [gentoo-dev] cmake + ninja vs autotools Christoph Junghans <junghans@g.o>