meson: Improve detection of Python when using Meson >=0.50.
Previously, on systems where multiple versions of Python 3 (e.g. 3.6 and 3.7) are installed, wrong version of Python 3 could have been used. The proper fix requires availability of path() method in Meson's python module, which has been added in Meson 0.50: https://github.com/mesonbuild/meson/pull/4616 Distro Bug: https://bugs.gentoo.org/671308 Signed-off-by:Arfrever Frehtes Taifersar Arahesis <Arfrever@Apache.Org> Reviewed-by:
Dylan Baker <dylan@pnwbakers.com> v2: - Add missing `endif` keyword (Dylan)