python / python/cpython

Improving `./configure --help` output

オープン
#136,700 コメント 1 件 リアクション 0 件 担当者 0 名 GitHub で見る

まだ誰も着手していません。

build triaged type-feature
主要言語
Python
スター
77.2k
フォーク
36k
PR マージ指標
PR 指標を取得中

説明

./configure --help should only show how to alter the default behaviour. Thus not articulating explicitly the default on --help, implies that not passing an option to ./configure will not imply that option. See also my article https://ab.bapha.be/posts/help-output/.

With Python 3.15.3 ./configure --help:

  --enable-universalsdk[=SDKDIR]
                          create a universal binary build. SDKDIR specifies
                          which macOS SDK should be used to perform the build,
                          see Mac/README.rst. (default is no)
  --enable-framework[=INSTALLDIR]
                          create a Python.framework rather than a traditional
                          Unix install. optional INSTALLDIR specifies the
                          installation path. see Mac/README.rst (default is
                          no)
  --enable-wasm-dynamic-linking
                          Enable dynamic linking support for WebAssembly
                          (default is no)
  --enable-wasm-pthreads  Enable pthread emulation for WebAssembly (default is
                          no)
  --enable-shared         enable building a shared Python library (default is
                          no)
  --enable-profiling      enable C-level code profiling with gprof (default is
                          no)
  --disable-gil           enable experimental support for running without the
                          GIL (default is no)
  --enable-pystats        enable internal statistics gathering (default is no)
  --enable-optimizations  enable expensive, stable optimizations (PGO, etc.)
                          (default is no)
  --enable-bolt           enable usage of the llvm-bolt post-link optimizer
                          (default is no)
  --enable-loadable-sqlite-extensions
                          support loadable extensions in the sqlite3 module,
                          see Doc/library/sqlite3.rst (default is no)
  --disable-test-modules  don't build nor install test modules
  --without-static-libpython
                          do not build libpythonMAJOR.MINOR.a and do not
                          install python.o (default is yes)

and more…

--disable-test-modules is used as I suggested. --disable-gil should be renamed to --enable-gil. All (default is no) and (default is yes) should be removed, when the option is binary (on/off/yes/no/with/without/enabled/disabled).

When a parameter has many possible values, sometimes --help emits =[ and sometimes [=. This is inconsistent:

  --enable-big-digits[=15|30]
                          use big digits (30 or 15 bits) for Python longs
                          (default is 30)]
  --with-pkg-config=[yes|no|check]
                          use pkg-config to detect build options (default is
                          check)

コントリビューションガイド

コントリビューションガイドを開く

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

調査の方向性

まず ./configure --help を実行し、文書化されているバイナリのデフォルト値とパラメータ構文を、この issue とリンク先の記事にある例と比較します。これらのエントリを生成している configuration-help の定義を特定し、バイナリオプションではデフォルト値の注記が省略され、値の構文に一貫性があることを確認します。生成されたヘルプ出力が要求された文言に従い、正確性を維持していれば完了です。

索引モデルが issue の本文から書いたものです。

評価

技術スタック
python
領域
build-system
issue の種類
機能追加
難易度
3/5
見積もり時間
1〜2日
活発さ
停滞
明瞭さ
おおむね明確
初心者へのやさしさ
45/100

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。