work around pyqt6.2.0's incorrect architecture label

This commit is contained in:
Damien Elmes 2021-10-16 13:19:37 +10:00
parent 3d1c2cb841
commit e577bd12b8

View File

@ -8,6 +8,7 @@ import re
import shutil
import subprocess
import sys
import platform
from pip._internal.commands import create_command
@ -104,6 +105,14 @@ def main():
# install package in subfolder
folder = os.path.join(base, "temp")
pip_args = []
if sys.platform.startswith("darwin") and platform.machine() == "arm64":
if name in ("pyqt6-qt6", "pyqt6-webengine-qt6"):
# pyqt messed up the architecture tags
pip_args.extend(
[
"--platform=macosx_10_14_arm64",
"--only-binary=:all:",
])
install_package(with_version, folder, pip_args)
# merge into parent
merge_files(base, folder)