Meson 1.1.0 arrives with new features and a lot of improvements

meson

Meson is a project to create the best possible next generation building system.

The release of the new version of the Meson 1.1.0 build system, which is used to compile various popular projects, such as X.Org, Mesa, systemd, Wayland, GNOME, among others.

Meson's key development goal is to provide a high-speed compilation process combined with convenience and ease of use. Instead of doing, the build uses the Ninja Toolkit by default, but other backends like xcode and VisualStudio can be used.

The system has a cross-platform dependency handler inbuiltin that allows you to use Meson to create packages for distributions. The compilation rules are written in a simplified domain-specific language, are well readable and understandable to the user (according to the authors' idea, the developer should spend a minimum of time writing rules).

Cross compilation is supported and compilation on a large number of systems and other compilers. Projects can be built in several programming languages, including C, C++, Fortran, Java, and Rust.

Notably supports an incremental build mode, in which only components that are directly related to changes made since the last build are rebuilt. Meson can be used to generate repeatable builds, where running the build in different environments results in the generation of completely identical executables.

Main novelties of Meson 1.1

In this new version of Meson 1.1, the execution of «sudo meson install» guarantees restoration of privileges during the rebuild for the target platforms.

Another of the changes that stands out is that the command «meson install» offers the ability to specify a separate driver to get root permissions (for example, you can select polkit, sudo, opendoas, or $MESON_ROOT_CMD), plus run "meson install» in non-interactive mode no longer attempts to elevate privileges.

In addition to this, it is also noted that it was added a new backend "none" (–backend=none) to create projects that only have installation rules and no build rules, as well as added a new dependency pybind11 to make the dependency ('pybind11') work with pkg-config and cmake without using the pybind11-config script.

Of the major changes Highlights of this new release include the following:

  • Added a new argument "objects:" to declare_dependency() to attach objects directly to executables as internal dependencies that do not require link_who.
  • Redirection provided to stderr from the output of information about the progress of the introspection.
  • Added an option to the command "meson devenv –dump» to specify a file to write environment variables to, instead of sending it to standard output.
  • methods have been added FeatureOption.enable_if and FeatureOption.disable_if to make it easier to create conditionals in preparation for passing parameters to the dependency() function, opt = get_option('feature').disable_if(not foo, error_message: 'Cannot enable feature when foo is not enabled')
    dep = dependency('foo', required : opt)
  • Allowed to pass generated objects as arguments "objects:".
  • The project function supports the installation of files with project license information.
  • Added support for reading file options meson.options instead of meson_options.txt.
  • The options "--reconfigure" and "--wipe" (meson setup –reconfigure builddir and meson setup –wipe builddir) are allowed with an empty builddir.
  • Meson.add_install_script() added keyword support dry_run, which allows you to run your own installation scripts by calling "meson install –dry-run«.

Finally, it is worth mentioning that Meson's code is written in Python and is licensed under the Apache 2.0 license. If you are interested in knowing more about it, you can consult the details In the following link.

How to install Meson on Linux?

For interested in being able to obtain Meson, they should know that it's available on PyPi , so it can be installed with pip3 install meson.

It should be noted that the exact command to type to install pip can vary between systems, so be sure to use the Python 3 version of pip.

Although if you wish, you can install it locally with the standard Python command:

python3 -m pip install meson

Leave a Comment

Your email address will not be published. Required fields are marked with *

*

*

  1. Responsible for the data: AB Internet Networks 2008 SL
  2. Purpose of the data: Control SPAM, comment management.
  3. Legitimation: Your consent
  4. Communication of the data: The data will not be communicated to third parties except by legal obligation.
  5. Data storage: Database hosted by Occentus Networks (EU)
  6. Rights: At any time you can limit, recover and delete your information.