Re: [libvirt PATCH 2/2] ci: Call meson consistently

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, Apr 01, 2021 at 03:43:11PM +0200, Andrea Bolognani wrote:
On Wed, 2021-03-31 at 23:31 +0200, Martin Kletzander wrote:
On Fri, Mar 26, 2021 at 11:35:02AM +0100, Andrea Bolognani wrote:
> We should always pass --werror and display the contents of the
> log file in case of failure.

Any reason why the lines are not in one place?  What I did in libnbd
(first draft, still up for review) is that I just took all the lines of
the script and put them inside `ci/build_script.sh` with only the most
basic conditionals to accommodate various types of runs.  That way
common things are in one place.  It could take a parameter (like what
ninja target to run) and you can run things after that (like `website`
and `potfiles` jobs do.  Just an idea.

As is often the case, the raisins are mostly hysterical ;)

I think the initial idea was to keep things as simple as possible,
but I agree with you that when you have seven (!) build recipes, most
of which are almost identical, it makes sense to think about
consolidating them to a single location.


So I took a look at the consolidation.  I went through few iterations
after which I ended with two scripts, one that does the meson part and
one that does the ninja part.  The first one does not need to take any
parameters, the other one would be nice if it took one, that's enough.
What's weird about it is the way I think of it.  The most understandable
way would be a `configure` that runs `meson ...` and then another one,
which runs `ninja ...` with parameter(s).

At that point you can make the second one a Makefile and just do:

  ./configure
  make

most of the time.  But because we can just put the configure part into
the makefile we can also just have a makefile that does all of it.  It
might sound stupid, but it is the easiest way how to provide few targets
without extra scripting and everything around it.  On the other hand it
feels weird just suggesting that, although I cannot pinpoint why that
is.  Maybe that it would be too controversial?

At this point I honestly do not know whether I went too far or it
actually makes sense and I am not capable of recognising the difference.

Thoughts?

--
Andrea Bolognani / Red Hat / Virtualization

Attachment: signature.asc
Description: PGP signature


[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]

  Powered by Linux