Skip to content

Commit 302af02

Browse files
authored
fix(android): execute wheel via sys.executable (#2515)
* Android: execute `wheel` via `sys.executable` * Suppress unhelpful cyclic-import warning
1 parent 9361af3 commit 302af02

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

cibuildwheel/platforms/android.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@
66
import shlex
77
import shutil
88
import subprocess
9+
import sys
910
from collections.abc import Iterable, Iterator
1011
from dataclasses import dataclass
1112
from os.path import relpath
@@ -21,7 +22,7 @@
2122
from elftools.elf.elffile import ELFFile
2223
from filelock import FileLock
2324

24-
from .. import errors, platforms
25+
from .. import errors, platforms # pylint: disable=cyclic-import
2526
from ..architecture import Architecture, arch_synonym
2627
from ..frontend import get_build_frontend_extra_flags, parse_config_settings
2728
from ..logger import log
@@ -517,7 +518,7 @@ def repair_default(
517518
f"${{ORIGIN}}/{relpath(libs_dir, path.parent)}",
518519
path,
519520
)
520-
call("wheel", "pack", unpacked_dir, "-d", repaired_wheel_dir)
521+
call(sys.executable, "-m", "wheel", "pack", unpacked_dir, "-d", repaired_wheel_dir)
521522

522523

523524
def elf_file_filter(paths: Iterable[Path]) -> Iterator[tuple[Path, ELFFile]]:

0 commit comments

Comments
 (0)