Re: -CURRENT compilation time

From: Warner Losh <imp_at_bsdimp.com>
Date: Wed, 08 Sep 2021 23:10:27 UTC
On Wed, Sep 8, 2021, 5:06 PM Tomoaki AOKI <junchoon@dec.sakura.ne.jp> wrote:

> On Wed, 8 Sep 2021 14:32:16 -0600
> Warner Losh <imp@bsdimp.com> wrote:
>
> > On Wed, Sep 8, 2021, 6:33 AM David Chisnall <theraven@freebsd.org>
> wrote:
> >
> > > On 08/09/2021 11:52, Gary Jennejohn wrote:
> > > > Seems to me that there was an earlier mail about getting CMAKE to
> work
> > > > with FreeBSD builds.  Could be worthwhile to look into getting ninja
> > > > to work also.  But I could understand that there might be push-back,
> > > > since the project prefers to use utilities from the source tree.
> > >
> > > CMake is a build-system generator, Ninja is a build system.  Usually
> the
> > > two are used together: CMake generates Ninja files, Ninja runs the
> > > build.  Ninja is explicitly designed not to be written by hand.
> > >
> > > CMake can also emit other things, including POSIX Makefiles, but the
> > > Ninja build is usually the fastest.
> > >
> > > CMake and Ninja are both in package systems for Windows, macOS, *BSD,
> > > and all Linux distros that I've seen, unlike bmake, so  universally
> easy
> > > to depend on for cross-builds.  Cross compiling with bmake is much
> > > harder harder from anything that isn't FreeBSD.
> > >
> >
> > This may be true. I've never had a problem on mac or linux, but my
> windows
> > experience is thin.
> >
> > I got looking at the problem, btw, to see if ninja was faster than meta
> > mode. Ninja files aren't horrible to generate, but I never got past the
> > early proof of concept phase... it seemed possible to implement a make
> > ninja target... I'd wanted to use this day to day if it was better than
> > meta.
> >
> > Mason, however looked much harder to generate, but I didn't spend a lot
> of
> > time on it. I would think this sort of work would be more of a one shot.
> > Didn't look at cmake at all, but I imagine it would be similar...
> >
> > Warner
> >
> > >
>
> What about devel/samurai, ninja-compatible build tool written in C?
>
> devel/ninja/Makefile has USES= python in it, so it maybe require python
> to run or at least build.
>
> In addition, ports framework can use it instead of ninja.
> See {PORTSDIR}/Mk/Uses/ninja.mk.
>

I'll have to take a look next time I play with this stuff

Warner

-- 
> Tomoaki AOKI    <junchoon@dec.sakura.ne.jp>
>
>