This method has been extended to use config-tools, and a fallback to
find_library for lookup as well as pkg-config.
## HDF5 dependency improvements
HDF5 has been improved so that the internal representations have been split.
This allows selecting pkg-config and config-tool dependencies separately.
Both work as proper dependencies of their type, so `get_variable` and similar
now work correctly.
It has also been fixed to use the selected compiler for the build instead of
the default compiler.
## External projects
A new experimental module `unstable_external_project` has been added to build
code using other build systems than Meson. Currently only supporting projects
with a configure script that generates Makefiles.
```meson
project('My Autotools Project', 'c',
meson_version : '>=0.56.0',
)
mod = import('unstable_external_project')
p = mod.add_project('configure',
configure_options : ['--prefix=@PREFIX@',
'--libdir=@LIBDIR@',
'--incdir=@INCLUDEDIR@',
'--enable-foo',
],
)
mylib_dep = p.dependency('mylib')
```
## Per subproject `warning_level` option
`warning_level` can now be defined per subproject, in the same way as
`default_library` and `werror`.
## `meson subprojects` command
A new `--types` argument has been added to all subcommands to run the command only
on wraps with the specified types. For example this command will only print `Hello`
for each git subproject: `meson subprojects foreach --types git echo "Hello"`.
Multiple types can be set as comma separated list e.g. `--types git,file`.
Subprojects with no wrap file are now taken into account as well. This happens
for example for subprojects configured as git submodule, or downloaded manually
by the user and placed into the `subprojects/` directory.
The `checkout` subcommand now always stash any pending changes before switching
branch. Note that `update` subcommand was already stashing changes before updating
the branch.
If the command fails on any subproject the execution continues with other
subprojects, but at the end an error code is now returned.
The `update` subcommand has been reworked:
- In the case the URL of `origin` is different as the `url` set in wrap file,
the subproject will not be updated unless `--reset` is specified (see below).
- In the case a subproject directory exists and is not a git repository but has
a `[wrap-git]`, meson used to run git commands that would wrongly apply to the
main project. It now skip the subproject unless `--reset` is specified (see below).
- The `--rebase` behaviour is now the default for consistency: it was
already rebasing when current branch and revision are the same, it is
less confusing to rebase when they are different too.
- Add `--reset` mode that checkout the new branch and hard reset that
branch to remote commit. This new mode guarantees that every
subproject are exactly at the wrap's revision. In addition the URL of `origin`
is updated in case it changed in the wrap file. If the subproject directory is
not a git repository but has a `[wrap-git]` the directory is deleted and the
new repository is cloned.
- Local changes are always stashed first to avoid any data loss. In the
worst case scenario the user can always check reflog and stash list to
rollback.
## Added CompCert C compiler
Added experimental support for the [CompCert formally-verified C compiler](https://github.com/AbsInt/CompCert). The current state of the implementation is good enough to build the [picolibc project](https://github.com/picolibc/picolibc) with CompCert, but might still need additional adjustments for other projects.
## Dependencies listed in test and benchmark introspection
The introspection data for tests and benchmarks now includes the target
ids for executables and built files that are needed by the test. IDEs can
use this feature to update the build more quickly before running a test.
## `include_type` support for the CMake subproject object dependency method
The `dependency()` method of the CMake subproject object now also supports the
`include_type` kwarg which is similar to the sane kwarg in the `dependency()`
function.
## Deprecate Dependency.get_pkgconfig_variable and Dependency.get_configtool_variable
These have been replaced with the more versatile `get_variable()` method