Use Meson commands, if available
Newer versions of Meson provide wrappers for the underlying build backend, and they should be preferred to explicitly calling tools like ninja.
We can still fall back to calling ninja if the version of Meson in use is too old.
Edited by Emmanuele Bassi