Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
)
# Python is buffering by default when running on the CI platforms, giving problems interleaving subprocess call output with unflushed calls to 'print'
sys.stdout = Unbuffered(sys.stdout) # type: ignore
print_preamble(platform, build_options)
if not output_dir.exists():
output_dir.mkdir(parents=True)
if platform == 'linux':
cibuildwheel.linux.build(build_options)
elif platform == 'windows':
cibuildwheel.windows.build(build_options)
elif platform == 'macos':
cibuildwheel.macos.build(build_options)
else:
print(f'cibuildwheel: Unsupported platform: {platform}', file=sys.stderr)
exit(2)