From bd3634c81577195ea471d0f049713b0f8705b11b Mon Sep 17 00:00:00 2001 From: Alibek Omarov Date: Sun, 9 Feb 2025 15:34:16 +0300 Subject: [PATCH] wscript: add sanity test for opusfile because some distros don't ship 32-bit binary --- wscript | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/wscript b/wscript index 35d6671a..1753aa24 100644 --- a/wscript +++ b/wscript @@ -485,6 +485,12 @@ def configure(conf): if conf.check_cfg(package=i, uselib_store=i, args='--cflags --libs', mandatory=False): conf.env['HAVE_SYSTEM_%s' % i.upper()] = True + if conf.env.HAVE_SYSTEM_OPUSFILE: + frag='''#include +int main(int argc, char **argv) { return opus_tagcompare(argv[0], argv[1]); }''' + + conf.env.HAVE_SYSTEM_OPUSFILE = conf.check_cc(msg='Checking for libopusfile sanity', use='opusfile werror', fragment=frag, mandatory=False) + # search for opus 1.4 only, it has fixes for custom modes # 1.5 breaks custom modes: https://github.com/xiph/opus/issues/374 if conf.check_cfg(package='opus', uselib_store='opus', args='opus = 1.4 --cflags --libs', mandatory=False):