Debian Codegraph @

src/auditwheel/options.py

raw
1 """Options shared between multiple subcommands."""
2
3 from __future__ import annotations
4
5 from typing import TYPE_CHECKING
6
7 if TYPE_CHECKING:
8 from argparse import ArgumentParser
9
10
11 def disable_isa_check(parser: ArgumentParser) -> None:
12 parser.add_argument(
13 "--disable-isa-ext-check",
14 dest="DISABLE_ISA_EXT_CHECK",
15 action="store_true",
16 help="Do not check for extended ISA compatibility (e.g. x86_64_v2)",
17 default=False,
18 )
19
20
21 def allow_pure_python_wheel(parser: ArgumentParser) -> None:
22 parser.add_argument(
23 "--allow-pure-python-wheel",
24 dest="ALLOW_PURE_PY_WHEEL",
25 action="store_true",
26 help="Allow processing of pure Python wheels (no platform-specific binaries) without error",
27 default=False,
28 )
29
30
31 def ldpaths(parser: ArgumentParser) -> None:
32 parser.add_argument(
33 "--ldpaths",
34 dest="LDPATHS",
35 help="Colon-delimited list of directories to search for external libraries. "
36 "This replaces the default list; to add to this list, set the environment "
37 "variable AUDITWHEEL_LD_LIBRARY_PATH.",
38 )