Python 3.5 subprocess.run() does not have a capture_output
parameter (it is present only in 3.7 and up).
Capture output by using subprocess.PIPE for stdout instead.
Fixes: bb9cd91095 ("buildtools: make AVX512 check portable")
Cc: stable@dpdk.org
Signed-off-by: Lance Richardson <lance.richardson@broadcom.com>
Acked-by: Dmitry Kozlyuk <dmitry.kozliuk@gmail.com>
buildtools/binutils-avx512-check.sh was Unix-only
and could not be used in cross builds:
1) written in shell;
2) used the assembler binary that may be missing,
e.g. when building on Windows with LLVM;
3) located the assembler as ${AS:-as} and referenced objdump,
but those binaries may be overridden via --cross-file.
Rewrite the script in Python.
Use the C compiler for the check.
Locate objdump and the C compiler using Meson.
Signed-off-by: Dmitry Kozlyuk <dmitry.kozliuk@gmail.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>