Commit Graph

9 Commits

Author SHA1 Message Date
Frediano Ziglio
f60d61186f ci: Update makecheck-windows job to Meson
Signed-off-by: Frediano Ziglio <freddy77@gmail.com>
2023-05-30 20:35:57 +01:00
Frediano Ziglio
ee6c01a235 build: Remove some useless file from Meson distribution
Remove:
- internal documentation;
- CI files.

Signed-off-by: Frediano Ziglio <freddy77@gmail.com>
2021-06-14 11:30:55 +01:00
Frediano Ziglio
0219bea62e build: Improve Meson distribution file
Generate .tarball-version file.
Code from spice-gtk.
Meson 0.49 is required for multiple parameters to meson.add_dist_script.

Signed-off-by: Frediano Ziglio <freddy77@gmail.com>
2021-06-14 11:30:55 +01:00
Frediano Ziglio
e2f6f1c7aa build: Update git-version-gen
Pick up new version from https://github.com/coreutils/gnulib.

Signed-off-by: Frediano Ziglio <freddy77@gmail.com>
2021-05-18 10:13:09 +01:00
Frediano Ziglio
c989769211 Do not generate ChangeLog file
People can read change logs from git log instead, version is enough.

Signed-off-by: Frediano Ziglio <fziglio@redhat.com>
Acked-by: Victor Toso <victortoso@redhat.com>
2020-02-27 11:22:40 +00:00
Eduardo Lima (Etrunko)
495d1612c4 Add support for building with meson/ninja
In a comparison with current autotools build system, meson/ninja
provides a huge improvement in build speed, while keeping the same
functionalities currently available and being considered more user
friendly.

The new system coexists within the same repository with the current one,
so we can do more extensive testing of its functionality before deciding
if the old system can be removed, or for some reason, has to stay for
good.

- Meson: https://mesonbuild.com

  This is the equivalent of autogen/configure step in autotools. It
  generates the files that will be used by ninja to actually build the
  source code.

  The project has received lots of traction recently, with many GNOME
  projects willing to move to this new build system. The following wiki
  page has more details of the status of the many projects being ported:

    https://wiki.gnome.org/Initiatives/GnomeGoals/MesonPorting

  Meson has a python-like syntax, easy to read, and the documentation
  on the project is very complete, with a dedicated page on how to port
  from autotools, explaining how most common use cases can be
  implemented using meson.

    http://mesonbuild.com/Porting-from-autotools.html

  Other important sources of information:

    http://mesonbuild.com/howtox.html
    http://mesonbuild.com/Syntax.html
    http://mesonbuild.com/Reference-manual.html

- Ninja: https://ninja-build.org

  Ninja is the equivalent of make in an autotools setup, which actually
  builds the source code. It has being used by large and complex
  projects such as Google Chrome, Android and LLVM. There is not much to
  say about ninja (other than it is much faster than make) because we
  won't interact directly with it as much, as meson does the middle man
  job here. The reasoning for creating ninja in the first place is
  explained on the following post:

    http://neugierig.org/software/chromium/notes/2011/02/ninja.html

  Also its manual provides more in-depth information about the design
  principles:

    https://ninja-build.org/manual.html

- Basic workflow:

  Meson package is available for most if not all distros, so, taking
  Fedora as an example, we only need to run:

    # dnf -y install meson ninja-build.

  With Meson, building in-tree is not possible at all, so we need to
  pass a directory as argument to meson where we want the build to be
  done. This has the advantage of creating builds with different options
  under the same parent directory, e.g.:

    $ meson ./build --prefix=/usr
    $ meson ./build-extra -Dextra-checks=true -Dalignment-checks=true

  After configuration is done, we call ninja to actually do the build.

    $ ninja -C ./build
    $ ninja -C ./build install

  Ninja defaults to parallel builds, and this can be changed with the -j
  flag.

    $ ninja -j 10 -C ./build

- Hacking:

  * meson.build: Mandatory for the project root and usually found under
                 each directory you want something to be built.

  * meson_options.txt: Options that can interfere with the result of the
                       build.

Signed-off-by: Eduardo Lima (Etrunko) <etrunko@redhat.com>
Signed-off-by: Christophe Fergeau <cfergeau@redhat.com>
Signed-off-by: Frediano Ziglio <fziglio@redhat.com>
Acked-by: Frediano Ziglio <fziglio@redhat.com>
Acked-by: Victor Toso <victortoso@redhat.com>
2018-08-30 11:10:45 -03:00
Christophe Fergeau
74300144f8 Update git-version-gen to latest version
Pick the latest git-version-gen version from
http://git.savannah.gnu.org/cgit/gnulib.git/plain/build-aux/git-version-gen
2013-12-11 16:32:36 +01:00
Alon Levy
761ce02406 add git-version-gen and gitlog-to-changelog 2012-10-19 14:15:06 +02:00
Daniel P. Berrange
b5060ff813 Add a 'syntax-check' make target
The 'make syntax-check' target is used to perform various code
style sanity checks, as well as to detect certain trivial error
patterns. The target is placed in GNUmakefile, instead of Makefile.am
since it relies on GNU specific make extensions.

The actual GNUmakefile and maint.mk files are taken from the
GNULIB project, unchanged

The cfg.mk file is used to configure which of the syntax checks
are activated, to allow addition of new project specific syntax
checks, and to blacklist certain files which should not be checked

* .mailmap: Add mapping for various broken email addrs in
  commit log, to stop complaints about AUTHORS file missing
  entries
* GNUmakefile: define the 'syntax-check' rule
* maint.mk: definition of standard syntax checks
* cfg.mk: configuration for checks
2012-01-13 18:12:00 +02:00