Skip to content

Draft: Meson build

Andre Miranda requested to merge andreldm/xfce4-appfinder:meson into master

Proof concept of building with meson instead of autotools. This is based on what I saw in gnome projects, namely gnome-calculator and devhelp.

Build with: meson setup --prefix=<prefix> build && ninja -C build

ninja -C install is installing files exactly as make install would, the only difference is the binary size, autotools generates a bigger one, I imagine different compile flags are used, and xml files have translations in a different order.

Generating a tarball is as easy as executing ninja -C build dist, it will be generated in build/meson-dist/xfce4-appfinder-4.18.0.tar.xz (plus a sha256sum file). I just didn't check if its contents are correct.

Notice that this MR breaks comparability with the autotools setup (glade file loaded via resource and _ prefix removed from xml files) but I think it would be easy to keep both build systems.

Totally non-scientific benchmark (git clean -fdx before each execution, best of three):

  • time sh -c "meson setup --prefix=/usr build && ninja -C build" → 3.79s
  • time sh -c "./ --prefix=/usr && make -j$(nproc)" → 10.18s

Merge request reports