mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-24 02:31:03 +00:00
afd11f3383
The version of bison that ships with macOS is too old, so we need to provide our own version of it. Fixes https://gitlab.freedesktop.org/gstreamer/gst-build/-/issues/174 Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-build/-/merge_requests/257>
28 lines
852 B
Meson
28 lines
852 B
Meson
project('win-flex-bison-binary', version : '3.7.6')
|
|
|
|
py3 = import('python3').find_python()
|
|
|
|
message('Downloading and extracting bison for macOS x64...')
|
|
|
|
arch = host_machine.cpu_family()
|
|
tar_hash = '932f91d7c7fa0121abc3e5f8e54a7234b03d3de468c254ab8063ff8e6eb92a09'
|
|
if arch != 'x86_64'
|
|
warning('bison binary is untested on non-x86_64, please report whether this worked or not')
|
|
arch = 'x86_64'
|
|
endif
|
|
|
|
ret = run_command(py3, files('download-binary.py'), meson.project_version(), arch, tar_hash)
|
|
if ret.returncode() != 0
|
|
message(ret.stdout())
|
|
error(ret.stderr())
|
|
endif
|
|
|
|
conf = configuration_data()
|
|
conf.set('SRCDIR', meson.project_source_root())
|
|
conf.set('EXTRACTDIR', ret.stdout())
|
|
bison_py = configure_file(
|
|
input: 'bison.py.in',
|
|
output: 'bison.py',
|
|
configuration: conf)
|
|
|
|
meson.override_find_program('bison', find_program(bison_py))
|