GeezerVisonThe World Wide Web, restored to 800 pixels of glory. |
| Home|About|Gaming cabinet|Archives|How it works|Starter sites |
GeezerVison is showing github.com — python-docs-zh-cn/using/configure.po at 3.10 · python/python-docs-zh-cn Expand file tree/ Copy pathconfigure.poMore file actions 1269 lines (1029 loc) · 47 KB / Copy pathconfigure.poFile metadata and controls1269 lines (1029 loc) · 47 KB 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 566 567 568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 593 594 595 596 597 598 599 600 601 602 603 604 605 606 607 608 609 610 611 612 613 614 615 616 617 618 619 620 621 622 623 624 625 626 627 628 629 630 631 632 633 634 635 636 637 638 639 640 641 642 643 644 645 646 647 648 649 650 651 652 653 654 655 656 657 658 659 660 661 662 663 664 665 666 667 668 669 670 671 672 673 674 675 676 677 678 679 680 681 682 683 684 685 686 687 688 689 690 691 692 693 694 695 696 697 698 699 700 701 702 703 704 705 706 707 708 709 710 711 712 713 714 715 716 717 718 719 720 721 722 723 724 725 726 727 728 729 730 731 732 733 734 735 736 737 738 739 740 741 742 743 744 745 746 747 748 749 750 751 752 753 754 755 756 757 758 759 760 761 762 763 764 765 766 767 768 769 770 771 772 773 774 775 776 777 778 779 780 781 782 783 784 785 786 787 788 789 790 791 792 793 794 795 796 797 798 799 800 801 802 803 804 805 806 807 808 809 810 811 812 813 814 815 816 817 818 819 820 821 822 823 824 825 826 827 828 829 830 831 832 833 834 835 836 837 838 839 840 841 842 843 844 845 846 847 848 849 850 851 852 853 854 855 856 857 858 859 860 861 862 863 864 865 866 867 868 869 870 871 872 873 874 875 876 877 878 879 880 881 882 883 884 885 886 887 888 889 890 891 892 893 894 895 896 897 898 899 900 901 902 903 904 905 906 907 908 909 910 911 912 913 914 915 916 917 918 919 920 921 922 923 924 925 926 927 928 929 930 931 932 933 934 935 936 937 938 939 940 941 942 943 944 945 946 947 948 949 950 951 952 953 954 955 956 957 958 959 960 961 962 963 964 965 966 967 968 969 970 971 972 973 974 975 976 977 978 979 980 981 982 983 984 985 986 987 988 989 990 991 992 993 994 995 996 997 998 999 1000 # SOME DESCRIPTIVE TITLE. # Copyright (C) 2001-2025, Python Software Foundation # This file is distributed under the same license as the Python package. # FIRST AUTHOR <EMAIL@ADDRESS>, YEAR. # # Translators: # python-doc bot, 2025 # #, fuzzy msgid "" msgstr "" "Project-Id-Version: Python 3.10\n" "Report-Msgid-Bugs-To: \n" "POT-Creation-Date: 2025-01-03 16:02+0000\n" "PO-Revision-Date: 2025-09-22 15:58+0000\n" "Last-Translator: python-doc bot, 2025\n" "Language-Team: Chinese (China) (https://app.transifex.com/python-doc/teams/5390/zh_CN/)\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" "Language: zh_CN\n" "Plural-Forms: nplurals=1; plural=0;\n" #: ../../using/configure.rst:3 msgid "Configure Python" msgstr "配置 Python" #: ../../using/configure.rst:8 msgid "Configure Options" msgstr "配置选项" #: ../../using/configure.rst:10 msgid "List all ``./configure`` script options using::" msgstr "用以下方式列出 ``./configure`` 脚本的所有选项::" #: ../../using/configure.rst:14 msgid "" "See also the :file:`Misc/SpecialBuilds.txt` in the Python source " "distribution." msgstr "参阅 Python 源代码中的 :file:`Misc/SpecialBuilds.txt` 。" #: ../../using/configure.rst:17 msgid "General Options" msgstr "通用选项" #: ../../using/configure.rst:21 msgid "" "Support loadable extensions in the :mod:`_sqlite` extension module (default " "is no)." msgstr "支持 :mod:`_sqlite` 扩展模块中的可加载扩展(默认为否)。" #: ../../using/configure.rst:24 msgid "" "See the :meth:`sqlite3.Connection.enable_load_extension` method of the " ":mod:`sqlite3` module." msgstr "" "参见 :meth:`sqlite3.Connection.enable_load_extension` 方法的 :mod:`sqlite3` 模块。" #: ../../using/configure.rst:31 msgid "" "Disable IPv6 support (enabled by default if supported), see the " ":mod:`socket` module." msgstr "禁用 IPv6 支持(若开启支持则默认启用),见 :mod:`socket` 模块。" #: ../../using/configure.rst:36 msgid "Define the size in bits of Python :class:`int` digits: 15 or 30 bits." msgstr "定义 Python :class:`int` 数字的比特大小:15或30比特" #: ../../using/configure.rst:38 msgid "" "By default, the number of bits is selected depending on ``sizeof(void*)``: " "30 bits if ``void*`` size is 64-bit or larger, 15 bits otherwise." msgstr "" "默认情况下,比特数取决于 ``sizeof(void*)``。如果 ``void*`` 大小为 64 位以上,则比特数为 30 位,否则为 15 位。" #: ../../using/configure.rst:41 msgid "Define the ``PYLONG_BITS_IN_DIGIT`` to ``15`` or ``30``." msgstr "定义 ``PYLONG_BITS_IN_DIGIT`` 为 ``15`` 或 ``30``。" #: ../../using/configure.rst:43 msgid "See :data:`sys.int_info.bits_per_digit <sys.int_info>`." msgstr "参见 :data:`sys.int_info.bits_per_digit <sys.int_info>` 。" #: ../../using/configure.rst:48 msgid "" "Compile the Python ``main()`` function and link Python executable with C++ " "compiler: ``$CXX``, or *COMPILER* if specified." msgstr "" "编译 Python ``main()`` 函数,用 C++ 编译器链接 Python 可执行文件: `$CXX`` 或 *COMPILER*。" #: ../../using/configure.rst:53 msgid "Set the Python executable suffix to *SUFFIX*." msgstr "将 Python 的可执行文件后缀设置为 *SUFFIX*。" #: ../../using/configure.rst:55 msgid "" "The default suffix is ``.exe`` on Windows and macOS (``python.exe`` " "executable), and an empty string on other platforms (``python`` executable)." msgstr "" "在 Windows 和 macOS 上的默认后缀为 ``.exe``( ``python.exe`` 为可执行文件),在其他平台上为空字符串( " "``python`` 可执行)。" #: ../../using/configure.rst:60 msgid "" "Select the default time zone search path for :data:`zoneinfo.TZPATH`. See " "the :ref:`Compile-time configuration <zoneinfo_data_compile_time_config>` of" " the :mod:`zoneinfo` module." msgstr "" "为 :data:`zoneinfo.TZPATH` 选择默认的时区搜索路径。 参见 :mod:`zoneinfo` 模块的 :ref:`编译时配置 " "<zoneinfo_data_compile_time_config>`。" #: ../../using/configure.rst:64 msgid "" "Default: " "``/usr/share/zoneinfo:/usr/lib/zoneinfo:/usr/share/lib/zoneinfo:/etc/zoneinfo``." msgstr "" "默认:``/usr/share/zoneinfo:/usr/lib/zoneinfo:/usr/share/lib/zoneinfo:/etc/zoneinfo``" #: ../../using/configure.rst:66 msgid "See :data:`os.pathsep` path separator." msgstr "参阅 :data:`os.pathsep` 路径分隔符。" #: ../../using/configure.rst:72 msgid "" "Build the ``_decimal`` extension module using a thread-local context rather " "than a coroutine-local context (default), see the :mod:`decimal` module." msgstr "编译 ``_decimal`` 扩展模块时使用线程本地上下文,而不是协程本地上下文(默认),参见 :mod:`decimal` 模块。" #: ../../using/configure.rst:75 msgid "See :data:`decimal.HAVE_CONTEXTVAR` and the :mod:`contextvars` module." msgstr "参见 :data:`decimal.HAVE_CONTEXTVAR` 和 :mod:`contextvars` 模块。" #: ../../using/configure.rst:81 msgid "Override order to check db backends for the :mod:`dbm` module" msgstr "覆盖 :mod:`dbm` 模块的 db 后端检查顺序。" #: ../../using/configure.rst:83 msgid "" "A valid value is a colon (``:``) separated string with the backend names:" msgstr "合法值是用冒号(``:``)分隔的字符串,包含后端名称。" #: ../../using/configure.rst:85 msgid "``ndbm``;" msgstr "``ndbm`` ;" #: ../../using/configure.rst:86 msgid "``gdbm``;" msgstr "``gdbm`` ;" #: ../../using/configure.rst:87 msgid "``bdb``." msgstr "``bdb`` 。" #: ../../using/configure.rst:91 msgid "" "Disable C locale coercion to a UTF-8 based locale (enabled by default)." msgstr "禁用 C 语言对 UTF-8 的强制要求(默认为启用)。" #: ../../using/configure.rst:93 msgid "Don't define the ``PY_COERCE_C_LOCALE`` macro." msgstr "不定义 ``PY_COERCE_C_LOCALE`` 宏。" #: ../../using/configure.rst:95 msgid "See :envvar:`PYTHONCOERCECLOCALE` and the :pep:`538`." msgstr "参阅 :envvar:`PYTHONCOERCECLOCALE` 和 :pep:`538`。" #: ../../using/configure.rst:99 msgid "Python library directory name (default is ``lib``)." msgstr "Python 库目录名(默认为 ``lib``)。" #: ../../using/configure.rst:101 msgid "Fedora and SuSE use ``lib64`` on 64-bit platforms." msgstr "Fedora 和 SuSE 在64 位平台用 ``lib64`` 。" #: ../../using/configure.rst:103 msgid "See :data:`sys.platlibdir`." msgstr "参阅 :data:`sys.platlibdir` 。" #: ../../using/configure.rst:109 msgid "" "Directory of wheel packages used by the :mod:`ensurepip` module (none by " "default)." msgstr ":mod:`ensurepip` 模块用到的 wheel 包目录(默认为无)。" #: ../../using/configure.rst:112 msgid "" "Some Linux distribution packaging policies recommend against bundling " "dependencies. For example, Fedora installs wheel packages in the " "``/usr/share/python-wheels/`` directory and don't install the " ":mod:`ensurepip._bundled` package." msgstr "" "某些 Linux 发行版的打包策略建议不要捆绑依赖关系。如 Fedora 在 ``/usr/share/python-wheels/`` 目录下安装 " "wheel 包,而不安装 :mod:`ensurepip._bundled` 包。" #: ../../using/configure.rst:121 msgid "Install Options" msgstr "安装时的选项" #: ../../using/configure.rst:125 msgid "" "Install architecture-independent files in PREFIX. On Unix, it defaults to " ":file:`/usr/local`." msgstr "在 PREFIX 中安装架构无关的文件。 在 Unix 上,它默认为 :file:`/usr/local`。" #: ../../using/configure.rst:128 msgid "This value can be retrived at runtime using :data:`sys.prefix`." msgstr "该值可使用 :data:`sys.prefix` 在运行时获取。" #: ../../using/configure.rst:130 msgid "" "As an example, one can use ``--prefix=\"$HOME/.local/\"`` to install a " "Python in its home directory." msgstr "作为示例,用户可以使用 ``--prefix=\"$HOME/.local/\"`` 在其家目录中安装 Python。" #: ../../using/configure.rst:135 msgid "" "Install architecture-dependent files in EPREFIX, defaults to " ":option:`--prefix`." msgstr "在 EPREFIX 中安装架构无关的文件,默认为 :option:`--prefix`。" #: ../../using/configure.rst:137 msgid "This value can be retrived at runtime using :data:`sys.exec_prefix`." msgstr "该值可使用 :data:`sys.exec_prefix` 在运行时获取。" #: ../../using/configure.rst:141 msgid "" "Don't build nor install test modules, like the :mod:`test` package or the " ":mod:`_testcapi` extension module (built and installed by default)." msgstr "不编译和安装 test 模块,如 :mod:`test` 包或 :mod:`_testcapi` 扩展模块(默认会编译并安装)。" #: ../../using/configure.rst:148 msgid "Select the :mod:`ensurepip` command run on Python installation:" msgstr "选择 Python 安装时运行的 :mod:`ensurepip` 命令。" #: ../../using/configure.rst:150 msgid "" "``upgrade`` (default): run ``python -m ensurepip --altinstall --upgrade`` " "command." msgstr "" "``upgrade`` (默认):运行 ``python -m ensurepip --altinstall --upgrade`` 命令。" #: ../../using/configure.rst:152 msgid "``install``: run ``python -m ensurepip --altinstall`` command;" msgstr "``install`` :运行 ``python -m ensurepip --altinstall`` 命令。" #: ../../using/configure.rst:153 msgid "``no``: don't run ensurepip;" msgstr "``no`` :不运行 ensurepip。" #: ../../using/configure.rst:159 msgid "Performance options" msgstr "性能选项" #: ../../using/configure.rst:161 msgid "" "Configuring Python using ``--enable-optimizations --with-lto`` (PGO + LTO) " "is recommended for best performance." msgstr "" "建议用 ``--enable-optimizations --with-lto`` (PGO + LTO)配置 Python,以便实现最佳性能。" #: ../../using/configure.rst:166 msgid "" "Enable Profile Guided Optimization (PGO) using :envvar:`PROFILE_TASK` " "(disabled by default)." msgstr "用 :envvar:`PROFILE_TASK` 启用以配置文件主导的优化(PGO)(默认为禁用)。" #: ../../using/configure.rst:169 msgid "" "The C compiler Clang requires ``llvm-profdata`` program for PGO. On macOS, " "GCC also requires it: GCC is just an alias to Clang on macOS." msgstr "" "C 编译器 Clang 需要用到 ``llvm-profdata`` 程序进行 PGO。在 macOS 上,GCC 也需要用到它:在 macOS 上 " "GCC 只是 Clang 的别名而已。" #: ../../using/configure.rst:172 msgid "" "Disable also semantic interposition in libpython if ``--enable-shared`` and " "GCC is used: add ``-fno-semantic-interposition`` to the compiler and linker " "flags." msgstr "" "如果使用 ``--enable-shared`` 和 GCC ,还可以禁用 libpython 中的语义插值:在编译器和链接器的标志中加入 " "``-fno-semantic-interposition`` 。" #: ../../using/configure.rst:178 msgid "Use ``-fno-semantic-interposition`` on GCC." msgstr "在 GCC 上使用 ``-fno-semantic-interposition`` 。" #: ../../using/configure.rst:183 msgid "" "Environment variable used in the Makefile: Python command line arguments for" " the PGO generation task." msgstr "Makefile 用到的环境变量:PGO 用到的 Python 命令行参数。" #: ../../using/configure.rst:186 msgid "Default: ``-m test --pgo --timeout=$(TESTTIMEOUT)``." msgstr "默认为:``-m test --pgo --timeout=$(TESTTIMEOUT)`` 。" #: ../../using/configure.rst:192 msgid "" "Enable Link Time Optimization (LTO) in any build (disabled by default)." msgstr "在编译过程中启用链接时间优化(LTO)(默认为禁用)。" #: ../../using/configure.rst:194 msgid "" "The C compiler Clang requires ``llvm-ar`` for LTO (``ar`` on macOS), as well" " as an LTO-aware linker (``ld.gold`` or ``lld``)." msgstr "" "LTO 时 C 编译器 Clang 需要用到 ``llvm-ar`` 参数(在 macOS 则为 ``ar``),以及支持 LTO " "的链接器(``ld.gold`` 或 ``lld``)。" #: ../../using/configure.rst:201 msgid "" "Enable computed gotos in evaluation loop (enabled by default on supported " "compilers)." msgstr "在求值环节启用 goto 计数(在支持的编译器上默认启用)。" #: ../../using/configure.rst:206 msgid "" "Disable the specialized Python memory allocator :ref:`pymalloc <pymalloc>` " "(enabled by default)." msgstr "禁用特定的 Python 内存分配器 :ref:`pymalloc <pymalloc>` (默认为启用)。" #: ../../using/configure.rst:209 msgid "See also :envvar:`PYTHONMALLOC` environment variable." msgstr "参见环境变量 :envvar:`PYTHONMALLOC` 。" #: ../../using/configure.rst:213 msgid "" "Disable static documentation strings to reduce the memory footprint (enabled" " by default). Documentation strings defined in Python are not affected." msgstr "禁用静态文档字符串以减少内存占用(默认启用)。Python 中定义的文档字符串不受影响。" #: ../../using/configure.rst:216 msgid "Don't define the ``WITH_DOC_STRINGS`` macro." msgstr "不定义 ``PY_COERCE_C_LOCALE`` 宏。" #: ../../using/configure.rst:218 msgid "See the ``PyDoc_STRVAR()`` macro." msgstr "参阅宏 ``PyDoc_STRVAR()`` 。" #: ../../using/configure.rst:222 msgid "Enable C-level code profiling with ``gprof`` (disabled by default)." msgstr "用 ``gprof`` 启用 C 语言级的代码评估(默认为禁用)。" #: ../../using/configure.rst:228 msgid "Python Debug Build" msgstr "Python 调试级编译" #: ../../using/configure.rst:230 msgid "" "A debug build is Python built with the :option:`--with-pydebug` configure " "option." msgstr "调试版本 Python 是指带有 :option:`--with-pydebug` 参数的编译。" #: ../../using/configure.rst:233 msgid "Effects of a debug build:" msgstr "调试版本的效果:" #: ../../using/configure.rst:235 msgid "" "Display all warnings by default: the list of default warning filters is " "empty in the :mod:`warnings` module." msgstr "默认显示所有警告:在 :mod:`warnings` 模块中,默认警告过滤器的列表是空的。" #: ../../using/configure.rst:237 msgid "Add ``d`` to :data:`sys.abiflags`." msgstr "在 :data:`sys.abiflags` 中加入 ``d`` 标记。" #: ../../using/configure.rst:238 msgid "Add :func:`sys.gettotalrefcount` function." msgstr "加入 :func:`sys.gettotalrefcount` 函数。" #: ../../using/configure.rst:239 msgid "Add :option:`-X showrefcount <-X>` command line option." msgstr "命令行参数加入 :option:`-X showrefcount <-X>` 。" #: ../../using/configure.rst:240 msgid "Add :envvar:`PYTHONTHREADDEBUG` environment variable." msgstr "环境变量加入 :envvar:`PYTHONTHREADDEBUG` 。" #: ../../using/configure.rst:241 msgid "" "Add support for the ``__ltrace__`` variable: enable low-level tracing in the" " bytecode evaluation loop if the variable is defined." msgstr "加入对 ``__ltrace__`` 变量的支持:如果定义了该变量,在计算字节码环节启用底层跟踪。" #: ../../using/configure.rst:243 msgid "" "Install :ref:`debug hooks on memory allocators <default-memory-allocators>` " "to detect buffer overflow and other memory errors." msgstr "安装 :ref:`内存分配调试钩子 <default-memory-allocators>` ,以便检测缓冲区溢出和其他内存错误。" #: ../../using/configure.rst:245 msgid "Define ``Py_DEBUG`` and ``Py_REF_DEBUG`` macros." msgstr "定义宏 ``Py_DEBUG`` 和 ``Py_REF_DEBUG`` 。" #: ../../using/configure.rst:246 msgid "" "Add runtime checks: code surroundeded by ``#ifdef Py_DEBUG`` and ``#endif``." " Enable ``assert(...)`` and ``_PyObject_ASSERT(...)`` assertions: don't set " "the ``NDEBUG`` macro (see also the :option:`--with-assertions` configure " "option). Main runtime checks:" msgstr "" "加入运行时检查:针对 ``#ifdef Py_DEBUG`` 和 ``#endif`` 包裹的代码。启用 ``assert(...)`` 和 " "``_PyObject_ASSERT(...)`` 断言:不设置 ``NDEBUG`` 宏(参阅 :option:`--with-" "assertions` 参数)。主要的运行检查包括:" #: ../../using/configure.rst:251 msgid "Add sanity checks on the function arguments." msgstr "增加了对函数参数的合理性检查。" #: ../../using/configure.rst:252 msgid "" "Unicode and int objects are created with their memory filled with a pattern " "to detect usage of uninitialized objects." msgstr "创建 Unicode 和 int 对象时,内存按某种模式进行了填充,用于检测是否使用了未初始化的对象。" #: ../../using/configure.rst:254 msgid "" "Ensure that functions which can clear or replace the current exception are " "not called with an exception raised." msgstr "确保有能力清除或替换当前异常的函数在调用时不会引发异常。" #: ../../using/configure.rst:256 msgid "" "The garbage collector (:func:`gc.collect` function) runs some basic checks " "on objects consistency." msgstr "垃圾收集器(:func:`gc.collect` 函数)对对象的一致性进行一些基本检查。" #: ../../using/configure.rst:258 msgid "" "The :c:macro:`Py_SAFE_DOWNCAST()` macro checks for integer underflow and " "overflow when downcasting from wide types to narrow types." msgstr "从较宽类型转换到较窄类型时,:c:macro:`Py_SAFE_DOWNCAST()` 宏会检查整数下溢和上溢的情况。" #: ../../using/configure.rst:261 msgid "" "See also the :ref:`Python Development Mode <devmode>` and the " ":option:`--with-trace-refs` configure option." msgstr "参见 :ref:`Python 开发模式 <devmode>` 和配置参数 :option:`--with-trace-refs` 。" #: ../../using/configure.rst:264 msgid "" "Release builds and debug builds are now ABI compatible: defining the " "``Py_DEBUG`` macro no longer implies the ``Py_TRACE_REFS`` macro (see the " ":option:`--with-trace-refs` option), which introduces the only ABI " "incompatibility." msgstr "" "发布版和调试版的编译现在是 ABI 兼容的:定义了 ``Py_DEBUG`` 宏不再意味着同时定义了 ``Py_TRACE_REFS`` 宏(参见 " ":option:`--with-trace-refs` 参数),这引入了唯一一处不是 ABI 兼容的地方。" #: ../../using/configure.rst:272 msgid "Debug options" msgstr "调试选项" #: ../../using/configure.rst:276 msgid "" ":ref:`Build Python in debug mode <debug-build>`: define the ``Py_DEBUG`` " "macro (disabled by default)." msgstr ":ref:`在调试模式下编译 Python <debug-build>`: 定义宏 ``Py_DEBUG`` (默认为禁用)。" #: ../../using/configure.rst:281 msgid "Enable tracing references for debugging purpose (disabled by default)." msgstr "为了调试而启用引用的跟踪(默认为禁用)。" #: ../../using/configure.rst:283 msgid "Effects:" msgstr "效果如下:" #: ../../using/configure.rst:285 msgid "Define the ``Py_TRACE_REFS`` macro." msgstr "定义 ``Py_TRACE_REFS`` 宏。" #: ../../using/configure.rst:286 msgid "Add :func:`sys.getobjects` function." msgstr "加入 :func:`sys.getobjects` 函数。" #: ../../using/configure.rst:287 msgid "Add :envvar:`PYTHONDUMPREFS` environment variable." msgstr "环境变量加入 :envvar:`PYTHONDUMPREFS` 。" #: ../../using/configure.rst:289 msgid "" "This build is not ABI compatible with release build (default build) or debug" " build (``Py_DEBUG`` and ``Py_REF_DEBUG`` macros)." msgstr "此版本与发布模式(默认编译模式)或调试模式(``Py_DEBUG`` 和 ``Py_REF_DEBUG`` 宏)不具备 ABI 兼容性。" #: ../../using/configure.rst:296 msgid "" "Build with C assertions enabled (default is no): ``assert(...);`` and " "``_PyObject_ASSERT(...);``." msgstr "编译时启用 C 断言:``assert(...);`` 和 ``_PyObject_ASSERT(...);`` (默认不启用)。" #: ../../using/configure.rst:299 msgid "" "If set, the ``NDEBUG`` macro is not defined in the :envvar:`OPT` compiler " "variable." msgstr "如果设置此参数,则在 :envvar:`OPT` 编译器变量中不定义 ``NDEBUG`` 宏。" #: ../../using/configure.rst:302 msgid "" "See also the :option:`--with-pydebug` option (:ref:`debug build <debug-" "build>`) which also enables assertions." msgstr "参阅 :option:`--with-pydebug` 选项(:ref:`调试编译模式 <debug-build>`),它也可以启用断言。" #: ../../using/configure.rst:309 msgid "Enable Valgrind support (default is no)." msgstr "启用 Valgrind (默认禁用)。" #: ../../using/configure.rst:313 msgid "Enable DTrace support (default is no)." msgstr "启用 DTrace(默认禁用)。" #: ../../using/configure.rst:315 msgid "" "See :ref:`Instrumenting CPython with DTrace and SystemTap " "<instrumentation>`." msgstr "参阅 :ref:`用 DTrace 和 SystemTap 测试 CPython <instrumentation>`。" #: ../../using/configure.rst:322 msgid "" "Enable AddressSanitizer memory error detector, ``asan`` (default is no)." msgstr "启用 AddressSanitizer 内存错误检测 ``asan``,(默认为禁用)。" #: ../../using/configure.rst:328 msgid "" "Enable MemorySanitizer allocation error detector, ``msan`` (default is no)." msgstr "启用 MemorySanitizer 内存错误检测 ``msan``,(默认为禁用)。" #: ../../using/configure.rst:334 msgid "" "Enable UndefinedBehaviorSanitizer undefined behaviour detector, ``ubsan`` " "(default is no)." msgstr "启用 undefinedBehaviorSanitizer 未定义行为检测 ``ubsan``,(默认为禁用)。" #: ../../using/configure.rst:341 msgid "Linker options" msgstr "链接器选项" #: ../../using/configure.rst:345 msgid "" "Enable building a shared Python library: ``libpython`` (default is no)." msgstr "启用共享 Python 库 ``libpython`` 的编译(默认为禁用)。" #: ../../using/configure.rst:349 msgid "" "Do not build ``libpythonMAJOR.MINOR.a`` and do not install ``python.o`` " "(built and enabled by default)." msgstr "不编译 ``libpythonMAJOR.MINOR.a``,也不安装 ``python.o`` (默认会编译并安装)。" #: ../../using/configure.rst:356 msgid "Libraries options" msgstr "库选项" #: ../../using/configure.rst:360 msgid "Link against additional libraries (default is no)." msgstr "链接附加库(默认不会)。" #: ../../using/configure.rst:364 msgid "" "Build the :mod:`pyexpat` module using an installed ``expat`` library " "(default is no)." msgstr "用已安装的 ``expat`` 库编译 :mod:`pyexpat` 模块(默认为否)。" #: ../../using/configure.rst:369 msgid "" "Build the :mod:`_ctypes` extension module using an installed ``ffi`` " "library, see the :mod:`ctypes` module (default is system-dependent)." msgstr "用已安装的 ``ffi`` 库编译 :mod:`_ctypes` 扩展模块,参见 :mod:`ctypes` 模块(默认情况视系统而定)。" #: ../../using/configure.rst:374 msgid "" "Build the ``_decimal`` extension module using an installed ``mpdec`` " "library, see the :mod:`decimal` module (default is no)." msgstr "用已安装的 ``mpdec`` 库编译 ``_decimal`` 扩展模块,参见 :mod:`decimal` 模块(默认为否)。" #: ../../using/configure.rst:381 msgid "Use ``editline`` library for backend of the :mod:`readline` module." msgstr "用 ``editline`` 库作为 :mod:`readline` 模块的后端。" #: ../../using/configure.rst:383 msgid "Define the ``WITH_EDITLINE`` macro." msgstr "定义 ``WITH_EDITLINE`` 宏。" #: ../../using/configure.rst:389 msgid "Don't build the :mod:`readline` module (built by default)." msgstr "不编译 :mod:`readline` 模块(默认会)。" #: ../../using/configure.rst:391 msgid "Don't define the ``HAVE_LIBREADLINE`` macro." msgstr "不定义 ``HAVE_LIBREADLINE`` 宏。" #: ../../using/configure.rst:397 msgid "Override search for Tcl and Tk include files." msgstr "覆盖 Tcl 和 Tk 包含文件的搜索路径。" #: ../../using/configure.rst:401 msgid "Override search for Tcl and Tk libraries." msgstr "覆盖 Tcl 和 Tk 库的搜索路径。" #: ../../using/configure.rst:405 msgid "" "Override ``libm`` math library to *STRING* (default is system-dependent)." msgstr "将 ``libm`` 数学库覆盖为 *STRING* (默认情况视系统而定)。" #: ../../using/configure.rst:409 msgid "Override ``libc`` C library to *STRING* (default is system-dependent)." msgstr "将 ``libc`` C 库覆盖为 *STRING* (默认情况视系统而定)。" #: ../../using/configure.rst:413 msgid "Root of the OpenSSL directory." msgstr "OpenSSL 的根目录。" #: ../../using/configure.rst:419 msgid "Set runtime library directory (rpath) for OpenSSL libraries:" msgstr "设置 OpenSSL 库的运行时库目录(rpath)。" #: ../../using/configure.rst:421 msgid "``no`` (default): don't set rpath;" msgstr "``no`` (默认): 不设置 rpath。" #: ../../using/configure.rst:422 msgid "" "``auto``: auto-detect rpath from :option:`--with-openssl` and ``pkg-" "config``;" msgstr "``auto``:根据 :option:`--with-openssl` 和 ``pkg-config`` 自动检测 rpath。" #: ../../using/configure.rst:424 msgid "*DIR*: set an explicit rpath." msgstr "*DIR* :直接设置 rpath。" #: ../../using/configure.rst:430 msgid "Security Options" msgstr "安全性选项" #: ../../using/configure.rst:434 msgid "Select hash algorithm for use in ``Python/pyhash.c``:" msgstr "选择 ``Python/pyhash.c`` 采用的哈希算法。" #: ../../using/configure.rst:436 msgid "``siphash24`` (default)." msgstr "``siphash24`` (默认)。" #: ../../using/configure.rst:437 msgid "``fnv``;" msgstr "``fnv``。" #: ../../using/configure.rst:443 msgid "Built-in hash modules:" msgstr "内置哈希模块:" #: ../../using/configure.rst:445 msgid "``md5``;" msgstr "``md5``。" #: ../../using/configure.rst:446 msgid "``sha1``;" msgstr "``sha1``。" #: ../../using/configure.rst:447 msgid "``sha256``;" msgstr "``sha256``。" #: ../../using/configure.rst:448 msgid "``sha512``;" msgstr "``sha512``。" #: ../../using/configure.rst:449 msgid "``sha3`` (with shake);" msgstr "``sha3`` (带 shake)。" #: ../../using/configure.rst:450 msgid "``blake2``." msgstr "``blake2``。" #: ../../using/configure.rst:456 msgid "Override the OpenSSL default cipher suites string:" msgstr "覆盖 OpenSSL 默认的密码套件字符串。" #: ../../using/configure.rst:458 msgid "``python`` (default): use Python's preferred selection;" msgstr "``python`` (默认值): 采用 Python 推荐选择。" #: ../../using/configure.rst:459 msgid "``openssl``: leave OpenSSL's defaults untouched;" msgstr "``openssl``:保留 OpenSSL 默认值不动。" #: ../../using/configure.rst:460 msgid "*STRING*: use a custom string" msgstr "*STRING* :采用自定义字符串。" #: ../../using/configure.rst:462 msgid "See the :mod:`ssl` module." msgstr "参见 :mod:`ssl` 模块。" #: ../../using/configure.rst:468 msgid "" "The settings ``python`` and *STRING* also set TLS 1.2 as minimum protocol " "version." msgstr "设置 ``python`` 和 *STRING* 也会把 TLS 1.2 设为最低版本的协议。" #: ../../using/configure.rst:472 msgid "macOS Options" msgstr "macOS 选项" #: ../../using/configure.rst:474 msgid "See ``Mac/README.rst``." msgstr "参见 ``Mac/README.rst`` 。" #: ../../using/configure.rst:479 msgid "" "Create a universal binary build. *SDKDIR* specifies which macOS SDK should " "be used to perform the build (default is no)." msgstr "创建通用的二进制版本。*SDKDIR* 指定应采用的 macOS SDK (默认为否)。" #: ../../using/configure.rst:485 msgid "" "Create a Python.framework rather than a traditional Unix install. Optional " "*INSTALLDIR* specifies the installation path (default is no)." msgstr "" "创建 Python.framework ,而不是传统的 Unix 安装版。可选参数 *INSTALLDIR* 指定了安装路径((默认为否)。" #: ../../using/configure.rst:490 msgid "" "Specify the kind of universal binary that should be created. This option is " "only valid when :option:`--enable-universalsdk` is set." msgstr "指定应创建何种通用二进制文件。该选项仅当设置了 :option:`--enable-universalsdk` 时才有效。" #: ../../using/configure.rst:493 msgid "Options:" msgstr "可选项:" #: ../../using/configure.rst:495 msgid "``universal2``;" msgstr "``universal2``。" #: ../../using/configure.rst:496 msgid "``32-bit``;" msgstr "``32-bit``。" #: ../../using/configure.rst:497 msgid "``64-bit``;" msgstr "``64-bit``。" #: ../../using/configure.rst:498 msgid "``3-way``;" msgstr "``3-way``。" #: ../../using/configure.rst:499 msgid "``intel``;" msgstr "``intel``。" #: ../../using/configure.rst:500 msgid "``intel-32``;" msgstr "``intel-32``。" #: ../../using/configure.rst:501 msgid "``intel-64``;" msgstr "``intel-64``。" #: ../../using/configure.rst:502 msgid "``all``." msgstr "``all``。" #: ../../using/configure.rst:506 msgid "" "Specify the name for the python framework on macOS only valid when " ":option:`--enable-framework` is set (default: ``Python``)." msgstr "" "为 macOS 中的 python 框架指定名称,仅当设置了 :option:`--enable-framework` " "时有效(默认:``Python``)。" #: ../../using/configure.rst:511 msgid "Python Build System" msgstr "Python 构建系统" #: ../../using/configure.rst:514 msgid "Main files of the build system" msgstr "构建系统的主要文件" #: ../../using/configure.rst:516 msgid ":file:`configure.ac` => :file:`configure`;" msgstr ":file:`configure.ac` => :file:`configure`;" #: ../../using/configure.rst:517 msgid "" ":file:`Makefile.pre.in` => :file:`Makefile` (created by :file:`configure`);" msgstr ":file:`Makefile.pre.in` => :file:`Makefile` (由 :file:`configure` 创建);" #: ../../using/configure.rst:518 msgid ":file:`pyconfig.h` (created by :file:`configure`);" msgstr ":file:`pyconfig.h` (由 :file:`configure` 创建);" #: ../../using/configure.rst:519 msgid "" ":file:`Modules/Setup`: C extensions built by the Makefile using " ":file:`Module/makesetup` shell script;" msgstr "" ":file:`Modules/Setup`: 由Makefile 使用 :file:`Module/makesetup` shell 脚本构建的 C " "扩展;" #: ../../using/configure.rst:521 msgid "" ":file:`setup.py`: C extensions built using the :mod:`distutils` module." msgstr ":file:`setup.py`: 使用 :mod:`distutils` 模块构建的 C 扩展。" #: ../../using/configure.rst:524 msgid "Main build steps" msgstr "主要构建步骤" #: ../../using/configure.rst:526 msgid "C files (``.c``) are built as object files (``.o``)." msgstr "C文件( ``.c`` )是作为对象文件( ``.o`` )构建的。" #: ../../using/configure.rst:527 msgid "A static ``libpython`` library (``.a``) is created from objects files." msgstr "一个静态库 ``libpython`` ( ``.a`` )是由对象文件创建的。" #: ../../using/configure.rst:528 msgid "" "``python.o`` and the static ``libpython`` library are linked into the final " "``python`` program." msgstr "``python.o`` 和静态库 ``libpython`` 被链接到最终程序 ``python`` 中。" #: ../../using/configure.rst:530 msgid "" "C extensions are built by the Makefile (see :file:`Modules/Setup`) and " "``python setup.py build``." msgstr "" "C 扩展由 Makefile (参见 :file:`Modules/Setup` ) 和 ``python setup.py build`` 构建。" #: ../../using/configure.rst:534 msgid "Main Makefile targets" msgstr "主要 Makefile 目标" #: ../../using/configure.rst:536 msgid "``make``: Build Python with the standard library." msgstr "``make`` :用标准库构建Python。" #: ../../using/configure.rst:537 msgid "" "``make platform:``: build the ``python`` program, but don't build the " "standard library extension modules." msgstr "``make platform:`` :构建 ``python`` 程序,但不构建标准库扩展模块。" #: ../../using/configure.rst:539 msgid "" "``make profile-opt``: build Python using Profile Guided Optimization (PGO). " "You can use the configure :option:`--enable-optimizations` option to make " "this the default target of the ``make`` command (``make all`` or just " "``make``)." msgstr "" "``make profile-opt`` :使用 Profile Guided Optimization (PGO) 构建 Python 。你可以使用 " "configure 的 :option:`--enable-optimizations` 选项来使其成为 ``make`` 命令的默认目标( " "``make all`` 或只是 ``make`` )。" #: ../../using/configure.rst:543 msgid "" "``make buildbottest``: Build Python and run the Python test suite, the same " "way than buildbots test Python. Set ``TESTTIMEOUT`` variable (in seconds) to" " change the test timeout (1200 by default: 20 minutes)." msgstr "" "``make buildbottest`` :构建 Python 并运行 Python 测试套件,与 buildbots 测试 Python " "的方式相同。设置变量 ``TESTTIMEOUT`` (单位:秒)来改变测试超时时间(默认为 1200 即 20 分钟)。" #: ../../using/configure.rst:546 msgid "``make install``: Build and install Python." msgstr "``make install``:构建并安装 Python 。" #: ../../using/configure.rst:547 msgid "" "``make regen-all``: Regenerate (almost) all generated files; ``make regen-" "stdlib-module-names`` and ``autoconf`` must be run separately for the " "remaining generated files." msgstr "" "``make regen-all`` :重新生成(几乎)所有生成的文件; ``make regen-stdlib-module-names`` 和 " "``autoconf`` 必须对其余生成的文件单独运行。" #: ../../using/configure.rst:550 msgid "``make clean``: Remove built files." msgstr "``make clean`` :移除构建的文件。" #: ../../using/configure.rst:551 msgid "" "``make distclean``: Same than ``make clean``, but remove also files created " "by the configure script." msgstr "``make distclean`` :与 ``make clean`` 相同,但也删除由配置脚本创建的文件。" #: ../../using/configure.rst:555 msgid "C extensions" msgstr "C 扩展" #: ../../using/configure.rst:557 msgid "" "Some C extensions are built as built-in modules, like the ``sys`` module. " "They are built with the ``Py_BUILD_CORE_BUILTIN`` macro defined. Built-in " "modules have no ``__file__`` attribute::" msgstr "" "一些 C 扩展是作为内置模块构建的,比如模块 ``sys`` 。它们是在定义了宏 ``Py_BUILD_CORE_BUILTIN`` " "的情况下构建的。内置模块没有 ``__file__`` 属性::" #: ../../using/configure.rst:569 msgid "" "Other C extensins are built as dynamic libraries, like the ``_asyncio`` " "module. They are built with the ``Py_BUILD_CORE_MODULE`` macro defined. " "Example on Linux x86-64::" msgstr "" "其他的 C 扩展是作为动态库构建的,就像 ``_asyncio`` 模块一样。 它们是在定义了 ``Py_BUILD_CORE_MODULE`` " "宏的情况下构建的。 在 Linux x86-64 上的例子::" #: ../../using/configure.rst:579 msgid "" ":file:`Modules/Setup` is used to generate Makefile targets to build C " "extensions. At the beginning of the files, C extensions are built as built-" "in modules. Extensions defined after the ``*shared*`` marker are built as " "dynamic libraries." msgstr "" ":file:`Modules/Setup` 用于生成 Makefile 目标,以构建 C 扩展。在文件的开头, C 被构建为内置模块。在标记 " "``*shared*`` 之后定义的扩展被构建为动态库。" #: ../../using/configure.rst:583 msgid "" "The :file:`setup.py` script only builds C extensions as shared libraries " "using the :mod:`distutils` module." msgstr ":file:`setup.py` 脚本只使用 :mod:`distutils` 模块将 C 构建为共享库。" #: ../../using/configure.rst:586 msgid "" "The :c:macro:`PyAPI_FUNC()`, :c:macro:`PyAPI_API()` and " ":c:macro:`PyMODINIT_FUNC()` macros of :file:`Include/pyport.h` are defined " "differently depending if the ``Py_BUILD_CORE_MODULE`` macro is defined:" msgstr "" "宏 :c:macro:`PyAPI_FUNC()` , :c:macro:`PyAPI_API()` 和 " ":c:macro:`PyMODINIT_FUNC()` 在 :file:`Include/pyport.h` 中的定义不同,取决于是否定义宏 " "``Py_BUILD_CORE_MODULE`` 。" #: ../../using/configure.rst:590 msgid "Use ``Py_EXPORTED_SYMBOL`` if the ``Py_BUILD_CORE_MODULE`` is defined" msgstr "如果 ``Py_BUILD_CORE_MODULE`` 定义了,使用 ``Py_EXPORTED_SYMBOL`` 。" #: ../../using/configure.rst:591 msgid "Use ``Py_IMPORTED_SYMBOL`` otherwise." msgstr "否则使用 ``Py_IMPORTED_SYMBOL`` 。" #: ../../using/configure.rst:593 msgid "" "If the ``Py_BUILD_CORE_BUILTIN`` macro is used by mistake on a C extension " "built as a shared library, its ``PyInit_xxx()`` function is not exported, " "causing an :exc:`ImportError` on import." msgstr "" "如果宏 ``Py_BUILD_CORE_BUILTIN`` 被错误地用在作为共享库构建的 C 扩展上,它的函数 ``PyInit_xxx()`` " "就不会被导出,导致导入时出现 :exc:`ImportError` 。" #: ../../using/configure.rst:599 msgid "Compiler and linker flags" msgstr "编译器和链接器的标志" #: ../../using/configure.rst:601 msgid "" "Options set by the ``./configure`` script and environment variables and used" " by ``Makefile``." msgstr "脚本 ``./configure`` 和环境变量设置的选项,并被 ``Makefile`` 使用。" #: ../../using/configure.rst:605 msgid "Preprocessor flags" msgstr "预处理器的标志" #: ../../using/configure.rst:609 msgid "" "Value of :envvar:`CPPFLAGS` variable passed to the ``./configure`` script." msgstr "变量 :envvar:`CPPFLAGS` 的值被传递给 ``./configure`` 脚本。" #: ../../using/configure.rst:615 msgid "" "(Objective) C/C++ preprocessor flags, e.g. ``-I<include dir>`` if you have " "headers in a nonstandard directory ``<include dir>``." msgstr "" "( Objective ) C/C++ 预处理器标志,例如,使用 ``-I<include dir>`` 如果你的头文件在一个非标准的目录 " "``<include dir>`` 中 、" #: ../../using/configure.rst:618 ../../using/configure.rst:813 msgid "" "Both :envvar:`CPPFLAGS` and :envvar:`LDFLAGS` need to contain the shell's " "value for setup.py to be able to build extension modules using the " "directories specified in the environment variables." msgstr "" ":envvar:`CPPFLAGS` 和 :envvar:`LDFLAGS` 都需要包含shell的值,以便 setup.py " "能够使用环境变量中指定的目录构建扩展模块。" #: ../../using/configure.rst:628 msgid "" "Extra preprocessor flags added for building the interpreter object files." msgstr "为构建解释器对象文件增加了额外的预处理器标志。" #: ../../using/configure.rst:630 msgid "" "Default: ``$(BASECPPFLAGS) -I. -I$(srcdir)/Include $(CONFIGURE_CPPFLAGS) " "$(CPPFLAGS)``." msgstr "" "默认为: ``$(BASECPPFLAGS) -I. -I$(srcdir)/Include $(CONFIGURE_CPPFLAGS) " |
| You are visitor 01402520 — GeezerVison does not store the pages you look up. Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required. |