Allow Strawberry Perl on Windows with Meson >= 0.60.0

Meson now explicitly blacklists pkg-config.bat from Strawberry Perl and
thus building GStreamer on Windows has been fixed.

This allows for instance to build GStreamer on GitHub Action Windows
runners that have Strawberry Perl by default.

It is also useful when needing to build OpenSSL on the same Windows
machine because it requires Perl.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/1263>
This commit is contained in:
Xavier Claessens 2021-10-28 10:09:21 -04:00 committed by GStreamer Marge Bot
parent 577cdcafe0
commit 1ec04817eb

View file

@ -40,10 +40,10 @@ ensure_no_strawberry_perl = '''
import os
assert(r'Strawberry\perl\bin' not in os.environ['PATH'])
'''
if build_system == 'windows'
if build_system == 'windows' and meson.version().version_compare('<0.60.0')
cmdres = run_command(python3, '-c', ensure_no_strawberry_perl)
if cmdres.returncode() != 0
error('You have Strawberry Perl in PATH which is known to cause build issues with gst-build. Please remove it from PATH or uninstall it.')
error('You have Strawberry Perl in PATH which is known to cause build issues with Meson < 0.60.0. Please remove it from PATH, uninstall it, or upgrade Meson.')
endif
endif