3. Python ਦੀ ਸੰਰਚਨਾ¶
3.1. Configure ਵਿਕਲਪ¶
List all ./configure script options using:
./configure --help
Python source distribution ਵਿੱਚ ਮੌਜੂਦ Misc/SpecialBuilds.txt ਵੀ ਵੇਖੋ।
3.1.1. ਆਮ ਵਿਕਲਪ¶
- --enable-loadable-sqlite-extensions¶
sqlite3ਮੋਡੀਊਲ ਦੇ_sqliteextension module ਵਿੱਚ load ਹੋਣ ਵਾਲੀਆਂ extensions ਲਈ ਸਮਰਥਨ (ਮੂਲ ਰੂਪ ਵਿੱਚ ਨਹੀਂ)।sqlite3ਮੋਡੀਊਲ ਦੀsqlite3.Connection.enable_load_extension()ਵਿਧੀ ਵੇਖੋ।New in version 3.6.
- --disable-ipv6¶
IPv6 ਸਮਰਥਨ ਨੂੰ ਅਸਮਰੱਥ ਕਰੋ (ਜੇ ਸਮਰਥਿਤ ਹੋਵੇ ਤਾਂ ਮੂਲ ਰੂਪ ਵਿੱਚ ਸਮਰੱਥ ਹੁੰਦਾ ਹੈ)। ਵੇਰਵਿਆਂ ਲਈ
socketਮੋਡੀਊਲ ਵੇਖੋ।
- --enable-big-digits=[15|30]¶
Python
intਅੰਕਾਂ ਦਾ ਆਕਾਰ bits ਵਿੱਚ ਨਿਰਧਾਰਤ ਕਰੋ: 15 ਜਾਂ 30 bits।ਮੂਲ ਰੂਪ ਵਿੱਚ ਅੰਕਾਂ ਦਾ ਆਕਾਰ 30 ਹੁੰਦਾ ਹੈ।
PYLONG_BITS_IN_DIGITਨੂੰ15ਜਾਂ30ਵਜੋਂ ਪਰਿਭਾਸ਼ਿਤ ਕਰੋ।
- --with-cxx-main¶
- --with-cxx-main=COMPILER¶
Compile the Python
main()function and link Python executable with C++ compiler:$CXX, or COMPILER if specified.
- --with-suffix=SUFFIX¶
Python executable ਲਈ SUFFIX suffix ਸੈੱਟ ਕਰੋ।
Windows ਅਤੇ macOS ਉੱਤੇ ਮੂਲ suffix
.exeਹੈ (python.exeexecutable), Emscripten node ਉੱਤੇ.js, Emscripten browser ਉੱਤੇ.html, WASI ਉੱਤੇ.wasmਅਤੇ ਹੋਰ platforms ਉੱਤੇ ਖਾਲੀ string (pythonexecutable) ਹੁੰਦੀ ਹੈ।Changed in version 3.11: WASM platform ਉੱਤੇ ਮੂਲ suffix
.js,.htmlਜਾਂ.wasmਵਿੱਚੋਂ ਇੱਕ ਹੁੰਦਾ ਹੈ।
- --with-tzpath=<list of absolute paths separated by pathsep>¶
zoneinfo.TZPATHਲਈ ਮੂਲ time zone ਖੋਜ ਮਾਰਗ ਚੁਣੋ। ਵੇਰਵਿਆਂ ਲਈzoneinfoਮੋਡੀਊਲ ਦੀ Compile-time configuration ਵੇਖੋ।ਮੂਲ ਮੁੱਲ:
/usr/share/zoneinfo:/usr/lib/zoneinfo:/usr/share/lib/zoneinfo:/etc/zoneinfo।os.pathseppath separator ਵੇਖੋ।New in version 3.9.
- --without-decimal-contextvar¶
_decimalextension module ਨੂੰ coroutine-local context (ਮੂਲ ਰੂਪ) ਦੀ ਬਜਾਏ thread-local context ਨਾਲ ਬਿਲਡ ਕਰੋ। ਵੇਰਵਿਆਂ ਲਈdecimalਮੋਡੀਊਲ ਵੇਖੋ।decimal.HAVE_CONTEXTVARਅਤੇcontextvarsਮੋਡੀਊਲ ਵੇਖੋ।New in version 3.9.
- --with-dbmliborder=<list of backend names>¶
dbmਮੋਡੀਊਲ ਲਈ db backends ਦੀ ਜਾਂਚ ਕਰਨ ਦਾ ਕ੍ਰਮ override ਕਰੋ।ਵੈਧ ਮੁੱਲ colon (
:) ਨਾਲ ਵੱਖ ਕੀਤੀ ਗਈ backend names ਦੀ string ਹੈ:ndbm;gdbm;bdb.
- --without-c-locale-coercion¶
C locale ਨੂੰ UTF-8 ਆਧਾਰਿਤ locale ਵਿੱਚ coercion ਕਰਨ ਦੀ ਵਿਵਸਥਾ ਅਸਮਰੱਥ ਕਰੋ (ਮੂਲ ਰੂਪ ਵਿੱਚ ਸਮਰੱਥ ਹੁੰਦੀ ਹੈ)।
PY_COERCE_C_LOCALEmacro ਨੂੰ ਪਰਿਭਾਸ਼ਿਤ ਨਾ ਕਰੋ।PYTHONCOERCECLOCALEਅਤੇ PEP 538 ਵੇਖੋ।
- --with-platlibdir=DIRNAME¶
Python library directory ਦਾ ਨਾਮ (ਮੂਲ ਰੂਪ ਵਿੱਚ
lib)।Fedora ਅਤੇ SuSE 64-bit platforms ਉੱਤੇ
lib64ਵਰਤਦੇ ਹਨ।sys.platlibdirਵੇਖੋ।New in version 3.9.
- --with-wheel-pkg-dir=PATH¶
ensurepipਮੋਡੀਊਲ ਦੁਆਰਾ ਵਰਤੇ ਜਾਣ ਵਾਲੇ wheel packages ਦੀ ਡਾਇਰੈਕਟਰੀ (ਮੂਲ ਰੂਪ ਵਿੱਚ ਕੋਈ ਨਹੀਂ)।ਕੁਝ Linux distributions ਦੀਆਂ packaging policies dependencies ਨੂੰ bundle ਕਰਨ ਦੇ ਵਿਰੁੱਧ ਸਿਫ਼ਾਰਸ਼ ਕਰਦੀਆਂ ਹਨ। ਉਦਾਹਰਨ ਲਈ, Fedora wheel packages ਨੂੰ
/usr/share/python-wheels/ਡਾਇਰੈਕਟਰੀ ਵਿੱਚ ਸਥਾਪਿਤ ਕਰਦਾ ਹੈ ਅਤੇensurepip._bundledpackage ਨੂੰ ਸਥਾਪਿਤ ਨਹੀਂ ਕਰਦਾ।New in version 3.10.
- --with-pkg-config=[check|yes|no]¶
ਕੀ configure ਨੂੰ build dependencies ਦੀ ਪਛਾਣ ਕਰਨ ਲਈ pkg-config ਦੀ ਵਰਤੋਂ ਕਰਨੀ ਚਾਹੀਦੀ ਹੈ।
check(ਮੂਲ): pkg-config ਵਿਕਲਪਿਕ ਹੈyes: pkg-config ਲਾਜ਼ਮੀ ਹੈno: configure pkg-config ਮੌਜੂਦ ਹੋਣ ਦੇ ਬਾਵਜੂਦ ਇਸਦੀ ਵਰਤੋਂ ਨਹੀਂ ਕਰਦਾ
New in version 3.11.
- --enable-pystats¶
Turn on internal statistics gathering.
The statistics will be dumped to a arbitrary (probably unique) file in
/tmp/py_stats/, orC:\temp\py_stats\on Windows.ਅੰਕੜੇ ਪੜ੍ਹਨ ਲਈ
Tools/scripts/summarize_stats.pyਵਰਤੋ।New in version 3.11.
3.1.2. WebAssembly ਦੇ ਵਿਕਲਪ¶
- --with-emscripten-target=[browser|node]¶
Set build flavor for
wasm32-emscripten.browser(default): preload minimal stdlib, default MEMFS.node: NODERAWFS and pthread support.
New in version 3.11.
- --enable-wasm-dynamic-linking¶
WASM ਲਈ dynamic linking ਸਮਰਥਨ ਸਮਰੱਥ ਕਰੋ।
Dynamic linking,
dlopenਨੂੰ ਸਮਰੱਥ ਬਣਾਉਂਦੀ ਹੈ। ਸੀਮਿਤ dead code elimination ਅਤੇ ਵਾਧੂ ਵਿਸ਼ੇਸ਼ਤਾਵਾਂ ਕਾਰਨ executable ਦੀ ਫ਼ਾਈਲ ਆਕਾਰ ਵੱਧ ਜਾਂਦੀ ਹੈ।New in version 3.11.
- --enable-wasm-pthreads¶
WASM ਲਈ pthreads ਸਮਰਥਨ ਸਮਰੱਥ ਕਰੋ।
New in version 3.11.
3.1.3. ਇੰਸਟਾਲੇਸ਼ਨ ਦੇ ਵਿਕਲਪ¶
- --prefix=PREFIX¶
ਆਰਕੀਟੈਕਚਰ-ਤੋਂ-ਸੁਤੰਤਰ ਫ਼ਾਈਲਾਂ ਨੂੰ PREFIX ਵਿੱਚ ਇੰਸਟਾਲ ਕਰੋ। Unix 'ਤੇ ਮੂਲ ਰੂਪ ਵਿੱਚ ਇਹ
/usr/localਹੁੰਦਾ ਹੈ।ਇਹ ਮੁੱਲ ਰਨਟਾਈਮ ਦੌਰਾਨ
sys.prefixਦੀ ਵਰਤੋਂ ਕਰਕੇ ਪ੍ਰਾਪਤ ਕੀਤਾ ਜਾ ਸਕਦਾ ਹੈ।ਉਦਾਹਰਨ ਵਜੋਂ,
--prefix="$HOME/.local/"ਦੀ ਵਰਤੋਂ ਕਰਕੇ Python ਨੂੰ ਆਪਣੇ home directory ਵਿੱਚ ਇੰਸਟਾਲ ਕੀਤਾ ਜਾ ਸਕਦਾ ਹੈ।
- --exec-prefix=EPREFIX¶
ਆਰਕੀਟੈਕਚਰ-ਨਿਰਭਰ ਫ਼ਾਈਲਾਂ ਨੂੰ EPREFIX ਵਿੱਚ ਇੰਸਟਾਲ ਕਰੋ; ਮੂਲ ਰੂਪ ਵਿੱਚ ਇਹ
--prefixਦੇ ਬਰਾਬਰ ਹੁੰਦਾ ਹੈ।ਇਹ ਮੁੱਲ ਰਨਟਾਈਮ ਦੌਰਾਨ
sys.exec_prefixਦੀ ਵਰਤੋਂ ਕਰਕੇ ਪ੍ਰਾਪਤ ਕੀਤਾ ਜਾ ਸਕਦਾ ਹੈ।
3.1.4. ਕਾਰਗੁਜ਼ਾਰੀ ਦੇ ਵਿਕਲਪ¶
Configuring Python using --enable-optimizations --with-lto (PGO + LTO) is
recommended for best performance.
- --enable-optimizations¶
PROFILE_TASKਦੀ ਵਰਤੋਂ ਕਰਕੇ Profile Guided Optimization (PGO) ਸਮਰੱਥ ਕਰੋ (ਮੂਲ ਰੂਪ ਵਿੱਚ ਅਸਮਰੱਥ)।PGO ਲਈ Clang C compiler ਨੂੰ
llvm-profdataਪ੍ਰੋਗਰਾਮ ਦੀ ਲੋੜ ਹੁੰਦੀ ਹੈ। macOS 'ਤੇ GCC ਨੂੰ ਵੀ ਇਸਦੀ ਲੋੜ ਹੁੰਦੀ ਹੈ, ਕਿਉਂਕਿ macOS 'ਤੇ GCC ਅਸਲ ਵਿੱਚ Clang ਦਾ ਹੀ alias ਹੈ।ਜੇ
--enable-sharedਅਤੇ GCC ਵਰਤੇ ਜਾ ਰਹੇ ਹੋਣ, ਤਾਂ libpython ਵਿੱਚ semantic interposition ਵੀ ਅਸਮਰੱਥ ਕਰੋ: compiler ਅਤੇ linker flags ਵਿੱਚ-fno-semantic-interpositionਸ਼ਾਮਲ ਕਰੋ।New in version 3.6.
Changed in version 3.10: GCC ਨਾਲ
-fno-semantic-interpositionਵਰਤੋ।
- PROFILE_TASK¶
Makefile ਵਿੱਚ ਵਰਤੀ ਜਾਣ ਵਾਲੀ environment variable: PGO generation task ਲਈ Python command line arguments।
ਮੂਲ:
-m test --pgo --timeout=$(TESTTIMEOUT)।New in version 3.8.
- --with-lto=[full|thin|no|yes]¶
ਕਿਸੇ ਵੀ build ਵਿੱਚ Link Time Optimization (LTO) ਸਮਰੱਥ ਕਰੋ (ਮੂਲ ਰੂਪ ਵਿੱਚ ਅਸਮਰੱਥ)।
Clang C compiler ਨੂੰ LTO ਲਈ
llvm-ar(macOS 'ਤੇar) ਅਤੇ LTO-ਸਮਰੱਥ linker (ld.goldਜਾਂlld) ਦੀ ਲੋੜ ਹੁੰਦੀ ਹੈ।New in version 3.6.
New in version 3.11: ThinLTO ਵਿਸ਼ੇਸ਼ਤਾ ਵਰਤਣ ਲਈ Clang ਨਾਲ
--with-lto=thinਵਰਤੋ।
- --with-computed-gotos¶
Evaluation loop ਵਿੱਚ computed gotos ਸਮਰੱਥ ਕਰੋ (ਸਮਰਥਿਤ compilers 'ਤੇ ਮੂਲ ਰੂਪ ਵਿੱਚ ਸਮਰੱਥ)।
- --without-pymalloc¶
ਵਿਸ਼ੇਸ਼ Python memory allocator pymalloc ਨੂੰ ਅਸਮਰੱਥ ਕਰੋ (ਮੂਲ ਰੂਪ ਵਿੱਚ ਸਮਰੱਥ)।
PYTHONMALLOCenvironment variable ਵੀ ਵੇਖੋ।
- --without-doc-strings¶
ਮੈਮੋਰੀ ਦੀ ਵਰਤੋਂ ਘਟਾਉਣ ਲਈ static documentation strings ਨੂੰ ਅਸਮਰੱਥ ਕਰੋ (ਮੂਲ ਰੂਪ ਵਿੱਚ ਸਮਰੱਥ)। Python ਵਿੱਚ ਪਰਿਭਾਸ਼ਿਤ documentation strings ਇਸ ਨਾਲ ਪ੍ਰਭਾਵਿਤ ਨਹੀਂ ਹੁੰਦੀਆਂ।
WITH_DOC_STRINGSmacro ਨੂੰ ਪਰਿਭਾਸ਼ਿਤ ਨਾ ਕਰੋ।PyDoc_STRVAR()macro ਵੇਖੋ।
- --enable-profiling¶
gprofਨਾਲ C-ਪੱਧਰੀ code profiling ਸਮਰੱਥ ਕਰੋ (ਮੂਲ ਰੂਪ ਵਿੱਚ ਅਸਮਰੱਥ)।
3.1.5. Python Debug Build¶
Debug build ਉਹ Python build ਹੈ ਜੋ --with-pydebug configure ਵਿਕਲਪ ਨਾਲ ਬਣਾਈ ਗਈ ਹੋਵੇ।
Debug build ਦੇ ਪ੍ਰਭਾਵ:
ਮੂਲ ਰੂਪ ਵਿੱਚ ਸਾਰੀਆਂ warnings ਦਿਖਾਓ:
warningsਮੋਡੀਊਲ ਵਿੱਚ ਮੂਲ warning filters ਦੀ ਸੂਚੀ ਖਾਲੀ ਹੁੰਦੀ ਹੈ।sys.abiflagsਵਿੱਚdਜੋੜੋ।sys.gettotalrefcount()function ਜੋੜੋ।-X showrefcountcommand line ਵਿਕਲਪ ਜੋੜੋ।Add
PYTHONTHREADDEBUGenvironment variable.__lltrace__variable ਲਈ ਸਮਰਥਨ ਜੋੜੋ: ਜੇ ਇਹ variable ਪਰਿਭਾਸ਼ਿਤ ਹੋਵੇ, ਤਾਂ bytecode evaluation loop ਵਿੱਚ low-level tracing ਸਮਰੱਥ ਕਰੋ।Buffer overflow ਅਤੇ ਹੋਰ memory errors ਦੀ ਪਛਾਣ ਕਰਨ ਲਈ memory allocators ਉੱਤੇ debug hooks ਇੰਸਟਾਲ ਕਰੋ।
Py_DEBUGਅਤੇPy_REF_DEBUGmacros ਪਰਿਭਾਸ਼ਿਤ ਕਰੋ।Runtime checks ਜੋੜੋ:
#ifdef Py_DEBUGਅਤੇ#endifਨਾਲ ਘਿਰਿਆ code।assert(...)ਅਤੇ_PyObject_ASSERT(...)assertions ਨੂੰ ਸਮਰੱਥ ਕਰੋ:NDEBUGmacro ਸੈੱਟ ਨਾ ਕਰੋ (--with-assertionsconfigure ਵਿਕਲਪ ਵੀ ਵੇਖੋ)। ਮੁੱਖ runtime checks:Function arguments ਉੱਤੇ sanity checks ਜੋੜੋ।
Unicode ਅਤੇ int objects ਬਣਾਉਂਦੇ ਸਮੇਂ ਉਨ੍ਹਾਂ ਦੀ memory ਨੂੰ ਇੱਕ pattern ਨਾਲ ਭਰਿਆ ਜਾਂਦਾ ਹੈ ਤਾਂ ਜੋ uninitialized objects ਦੀ ਵਰਤੋਂ ਦਾ ਪਤਾ ਲੱਗ ਸਕੇ।
ਯਕੀਨੀ ਬਣਾਓ ਕਿ ਉਹ functions ਜੋ ਮੌਜੂਦਾ exception ਨੂੰ ਸਾਫ਼ ਜਾਂ ਬਦਲ ਸਕਦੀਆਂ ਹਨ, ਕਿਸੇ exception ਦੇ ਉੱਠੇ ਹੋਏ ਹੋਣ ਦੀ ਸਥਿਤੀ ਵਿੱਚ ਨਾ ਬੁਲਾਈਆਂ ਜਾਣ।
ਜਾਂਚੋ ਕਿ deallocator functions ਮੌਜੂਦਾ exception ਨੂੰ ਨਹੀਂ ਬਦਲਦੀਆਂ।
Garbage collector (
gc.collect()function) objects ਦੀ ਇਕਸਾਰਤਾ ਉੱਤੇ ਕੁਝ ਬੁਨਿਆਦੀ ਜਾਂਚਾਂ ਕਰਦਾ ਹੈ।Py_SAFE_DOWNCAST()macro, ਵੱਡੀਆਂ ਕਿਸਮਾਂ ਤੋਂ ਛੋਟੀਆਂ ਕਿਸਮਾਂ ਵਿੱਚ downcast ਕਰਦੇ ਸਮੇਂ integer underflow ਅਤੇ overflow ਦੀ ਜਾਂਚ ਕਰਦੀ ਹੈ।
Python Development Mode ਅਤੇ --with-trace-refs configure ਵਿਕਲਪ ਵੀ ਵੇਖੋ।
Changed in version 3.8: Release builds and debug builds are now ABI compatible: defining the
Py_DEBUG macro no longer implies the Py_TRACE_REFS macro (see the
--with-trace-refs option), which introduces the only ABI
incompatibility.
3.1.6. Debug ਵਿਕਲਪ¶
- --with-pydebug¶
Python ਨੂੰ debug mode ਵਿੱਚ ਬਣਾਓ:
Py_DEBUGmacro ਪਰਿਭਾਸ਼ਿਤ ਕਰੋ (ਮੂਲ ਰੂਪ ਵਿੱਚ ਅਸਮਰੱਥ)।
- --with-trace-refs¶
Debugging ਦੇ ਉਦੇਸ਼ ਲਈ tracing references ਸਮਰੱਥ ਕਰੋ (ਮੂਲ ਰੂਪ ਵਿੱਚ ਅਸਮਰੱਥ)।
ਅਸਰ:
Py_TRACE_REFSmacro ਪਰਿਭਾਸ਼ਿਤ ਕਰੋ।Add
sys.getobjects()function.PYTHONDUMPREFSenvironment variable ਜੋੜੋ।
This build is not ABI compatible with release build (default build) or debug build (
Py_DEBUGandPy_REF_DEBUGmacros).New in version 3.8.
- --with-assertions¶
C assertions ਸਮਰੱਥ ਕਰਕੇ build ਕਰੋ (ਮੂਲ ਰੂਪ ਵਿੱਚ ਨਹੀਂ):
assert(...);ਅਤੇ_PyObject_ASSERT(...);।ਜੇ ਇਹ ਸੈੱਟ ਕੀਤਾ ਗਿਆ ਹੋਵੇ, ਤਾਂ
NDEBUGmacro ਨੂੰOPTcompiler variable ਵਿੱਚ ਪਰਿਭਾਸ਼ਿਤ ਨਹੀਂ ਕੀਤਾ ਜਾਂਦਾ।--with-pydebugਵਿਕਲਪ (debug build) ਵੀ ਵੇਖੋ, ਜੋ assertions ਨੂੰ ਵੀ ਸਮਰੱਥ ਕਰਦਾ ਹੈ।New in version 3.6.
- --with-valgrind¶
Valgrind ਸਮਰਥਨ ਸਮਰੱਥ ਕਰੋ (ਮੂਲ ਰੂਪ ਵਿੱਚ ਨਹੀਂ)।
- --with-dtrace¶
DTrace ਸਮਰਥਨ ਸਮਰੱਥ ਕਰੋ (ਮੂਲ ਰੂਪ ਵਿੱਚ ਨਹੀਂ)।
Instrumenting CPython with DTrace and SystemTap ਵੇਖੋ।
New in version 3.6.
- --with-address-sanitizer¶
Enable AddressSanitizer memory error detector,
asan(default is no).New in version 3.6.
- --with-memory-sanitizer¶
MemorySanitizer allocation error detector,
msan, ਨੂੰ ਸਮਰੱਥ ਕਰੋ (ਮੂਲ ਰੂਪ ਵਿੱਚ ਨਹੀਂ)।New in version 3.6.
- --with-undefined-behavior-sanitizer¶
UndefinedBehaviorSanitizer undefined behaviour detector,
ubsan, ਨੂੰ ਸਮਰੱਥ ਕਰੋ (ਮੂਲ ਰੂਪ ਵਿੱਚ ਨਹੀਂ)।New in version 3.6.
3.1.7. Linker ਦੇ ਵਿਕਲਪ¶
Shared Python library
libpythonਬਣਾਉਣ ਨੂੰ ਸਮਰੱਥ ਕਰੋ (ਮੂਲ ਰੂਪ ਵਿੱਚ ਨਹੀਂ)।
- --without-static-libpython¶
libpythonMAJOR.MINOR.aਨਾ ਬਣਾਓ ਅਤੇpython.oਇੰਸਟਾਲ ਨਾ ਕਰੋ (ਮੂਲ ਰੂਪ ਵਿੱਚ ਬਣਾਇਆ ਅਤੇ ਸਮਰੱਥ ਕੀਤਾ ਜਾਂਦਾ ਹੈ)।New in version 3.10.
3.1.8. Libraries ਦੇ ਵਿਕਲਪ¶
- --with-libs='lib1 ...'¶
ਵਾਧੂ libraries ਨਾਲ link ਕਰੋ (ਮੂਲ ਰੂਪ ਵਿੱਚ ਨਹੀਂ)।
- --with-system-expat¶
ਇੰਸਟਾਲ ਕੀਤੀ ਹੋਈ
expatlibrary ਦੀ ਵਰਤੋਂ ਕਰਕੇpyexpatਮੋਡੀਊਲ ਬਣਾਓ (ਮੂਲ ਰੂਪ ਵਿੱਚ ਨਹੀਂ)।
- --with-system-ffi¶
Build the
_ctypesextension module using an installedffilibrary, see thectypesmodule (default is system-dependent).
- --with-system-libmpdec¶
Build the
_decimalextension module using an installedmpdeclibrary, see thedecimalmodule (default is no).New in version 3.3.
- --with-readline=editline¶
Use
editlinelibrary for backend of thereadlinemodule.Define the
WITH_EDITLINEmacro.New in version 3.10.
- --without-readline¶
readlineਮੋਡੀਊਲ ਨਾ ਬਣਾਓ (ਮੂਲ ਰੂਪ ਵਿੱਚ ਬਣਾਇਆ ਜਾਂਦਾ ਹੈ)।HAVE_LIBREADLINEmacro ਨੂੰ ਪਰਿਭਾਸ਼ਿਤ ਨਾ ਕਰੋ।New in version 3.10.
- --with-libm=STRING¶
libmਗਣਿਤ library ਨੂੰ STRING ਨਾਲ override ਕਰੋ (ਮੂਲ ਰੂਪ ਵਿੱਚ ਇਹ ਸਿਸਟਮ-ਨਿਰਭਰ ਹੁੰਦੀ ਹੈ)।
- --with-libc=STRING¶
libcC library ਨੂੰ STRING ਨਾਲ override ਕਰੋ (ਮੂਲ ਰੂਪ ਵਿੱਚ ਇਹ ਸਿਸਟਮ-ਨਿਰਭਰ ਹੁੰਦੀ ਹੈ)।
- --with-openssl=DIR¶
OpenSSL directory ਦਾ root।
New in version 3.7.
- --with-openssl-rpath=[no|auto|DIR]¶
OpenSSL libraries ਲਈ runtime library directory (rpath) ਸੈੱਟ ਕਰੋ:
no(ਮੂਲ): rpath ਸੈੱਟ ਨਾ ਕਰੋ।auto:--with-opensslਅਤੇpkg-configਤੋਂ rpath ਆਪਣੇ ਆਪ ਪਤਾ ਲਗਾਓ।DIR: ਇੱਕ ਸਪਸ਼ਟ rpath ਸੈੱਟ ਕਰੋ।
New in version 3.10.
3.1.9. ਸੁਰੱਖਿਆ ਵਿਕਲਪ¶
- --with-hash-algorithm=[fnv|siphash13|siphash24]¶
Python/pyhash.cਵਿੱਚ ਵਰਤੋਂ ਲਈ hash algorithm ਚੁਣੋ:siphash13(ਮੂਲ);siphash24;fnv.
New in version 3.4.
New in version 3.11:
siphash13ਸ਼ਾਮਲ ਕੀਤਾ ਗਿਆ ਹੈ ਅਤੇ ਹੁਣ ਇਹ ਮੂਲ algorithm ਹੈ।
- --with-builtin-hashlib-hashes=md5,sha1,sha256,sha512,sha3,blake2¶
ਅੰਦਰੂਨੀ hash modules:
md5;sha1;sha256;sha512;sha3(shake ਸਮੇਤ);blake2
New in version 3.9.
- --with-ssl-default-suites=[python|openssl|STRING]¶
OpenSSL ਦੀ ਮੂਲ cipher suites string ਨੂੰ override ਕਰੋ:
python(ਮੂਲ): Python ਦੀ ਪਸੰਦੀਦਾ ਚੋਣ ਵਰਤੋ।openssl: OpenSSL ਦੀਆਂ ਮੂਲ settings ਨੂੰ ਬਿਨਾਂ ਬਦਲੇ ਰਹਿਣ ਦਿਓ।STRING: ਆਪਣੀ ਮਨਚਾਹੀ string ਵਰਤੋ।
sslਮੋਡੀਊਲ ਵੇਖੋ।New in version 3.7.
Changed in version 3.10:
pythonਅਤੇ STRING ਦੋਵੇਂ settings TLS 1.2 ਨੂੰ ਘੱਟੋ-ਘੱਟ protocol version ਵਜੋਂ ਵੀ ਸੈੱਟ ਕਰਦੀਆਂ ਹਨ।
3.1.10. macOS ਵਿਕਲਪ¶
See Mac/README.rst.
- --enable-universalsdk¶
- --enable-universalsdk=SDKDIR¶
Universal binary build ਬਣਾਓ। SDKDIR ਦੱਸਦਾ ਹੈ ਕਿ build ਲਈ ਕਿਹੜਾ macOS SDK ਵਰਤਿਆ ਜਾਣਾ ਹੈ (ਮੂਲ ਰੂਪ ਵਿੱਚ ਨਹੀਂ)।
- --enable-framework¶
- --enable-framework=INSTALLDIR¶
ਰਵਾਇਤੀ Unix installation ਦੀ ਬਜਾਏ ਇੱਕ Python.framework ਬਣਾਓ। ਵਿਕਲਪੀ INSTALLDIR installation path ਨਿਰਧਾਰਤ ਕਰਦਾ ਹੈ (ਮੂਲ ਰੂਪ ਵਿੱਚ ਨਹੀਂ)।
- --with-universal-archs=ARCH¶
ਕਿਹੜੀ ਕਿਸਮ ਦਾ universal binary ਬਣਾਇਆ ਜਾਣਾ ਹੈ, ਇਹ ਨਿਰਧਾਰਤ ਕਰੋ। ਇਹ ਵਿਕਲਪ ਕੇਵਲ ਤਦ ਹੀ ਵੈਧ ਹੈ ਜਦੋਂ
--enable-universalsdkਸੈੱਟ ਕੀਤਾ ਗਿਆ ਹੋਵੇ।ਵਿਕਲਪ:
universal2;32-bit;64-bit;3-way;intel;intel-32;intel-64;all.
- --with-framework-name=FRAMEWORK¶
ਕੇਵਲ macOS ਉੱਤੇ Python framework ਦਾ ਨਾਮ ਨਿਰਧਾਰਤ ਕਰੋ। ਇਹ ਵਿਕਲਪ ਤਦੋਂ ਹੀ ਵੈਧ ਹੈ ਜਦੋਂ
--enable-frameworkਸੈੱਟ ਕੀਤਾ ਗਿਆ ਹੋਵੇ (ਮੂਲ:Python)।
3.1.11. Cross Compiling ਵਿਕਲਪ¶
Cross compiling ਜਿਸਨੂੰ cross building ਵੀ ਕਿਹਾ ਜਾਂਦਾ ਹੈ ਦੀ ਵਰਤੋਂ ਕਿਸੇ ਹੋਰ CPU architecture ਜਾਂ platform ਲਈ Python ਬਣਾਉਣ ਵਾਸਤੇ ਕੀਤੀ ਜਾਂਦੀ ਹੈ। Cross compiling ਲਈ build platform ਉੱਤੇ ਇੱਕ Python interpreter ਦੀ ਲੋੜ ਹੁੰਦੀ ਹੈ। Build Python ਦਾ version, cross-compiled host Python ਦੇ version ਨਾਲ ਮਿਲਣਾ ਚਾਹੀਦਾ ਹੈ।
- --build=BUILD¶
BUILD ਉੱਤੇ build ਕਰਨ ਲਈ configure ਕਰੋ; ਆਮ ਤੌਰ 'ਤੇ ਇਹ config.guess ਰਾਹੀਂ ਆਪਣੇ ਆਪ ਅਨੁਮਾਨਿਆ ਜਾਂਦਾ ਹੈ।
- --host=HOST¶
HOST (target platform) ਉੱਤੇ ਚੱਲਣ ਵਾਲੇ ਪ੍ਰੋਗਰਾਮ ਬਣਾਉਣ ਲਈ cross-compile ਕਰੋ।
- --with-build-python=path/to/python¶
Cross compiling ਲਈ ਵਰਤੇ ਜਾਣ ਵਾਲੇ
pythonbinary ਦਾ path।New in version 3.11.
- CONFIG_SITE=file¶
ਇੱਕ environment variable ਜੋ configure overrides ਵਾਲੀ file ਵੱਲ ਇਸ਼ਾਰਾ ਕਰਦਾ ਹੈ।
ਉਦਾਹਰਨ config.site file:
# config.site-aarch64 ac_cv_buggy_getaddrinfo=no ac_cv_file__dev_ptmx=yes ac_cv_file__dev_ptc=no
Cross compiling ਦੀ ਉਦਾਹਰਨ:
CONFIG_SITE=config.site-aarch64 ../configure \
--build=x86_64-pc-linux-gnu \
--host=aarch64-unknown-linux-gnu \
--with-build-python=../x86_64/python
3.2. Python Build System¶
3.2.1. Build system ਦੀਆਂ ਮੁੱਖ files¶
configure.ac=>configure;Makefile.pre.in=>Makefile(configureਦੁਆਰਾ ਬਣਾਈ ਜਾਂਦੀ ਹੈ);pyconfig.h(configureਦੁਆਰਾ ਬਣਾਈ ਜਾਂਦੀ ਹੈ);Modules/Setup: C extensions ਜਿਨ੍ਹਾਂ ਨੂੰ MakefileModule/makesetupshell script ਦੀ ਵਰਤੋਂ ਕਰਕੇ build ਕਰਦੀ ਹੈ;setup.py: C extensions built using thedistutilsmodule.
3.2.2. ਮੁੱਖ ਬਿਲਡ ਕਦਮ¶
C ਫਾਈਲਾਂ (
.c) ਨੂੰ ਆਬਜੈਕਟ ਫਾਈਲਾਂ (.o) ਵਜੋਂ ਬਿਲਡ ਕੀਤਾ ਜਾਂਦਾ ਹੈ।ਆਬਜੈਕਟ ਫਾਈਲਾਂ ਤੋਂ ਇੱਕ ਸਥਿਰ
libpythonਲਾਇਬ੍ਰੇਰੀ (.a) ਬਣਾਈ ਜਾਂਦੀ ਹੈ।python.oਅਤੇ ਸਥਿਰlibpythonਲਾਇਬ੍ਰੇਰੀ ਨੂੰ ਅੰਤਿਮpythonਪ੍ਰੋਗਰਾਮ ਵਿੱਚ ਲਿੰਕ ਕੀਤਾ ਜਾਂਦਾ ਹੈ।C extensions are built by the Makefile (see
Modules/Setup) andpython setup.py build.
3.2.3. ਮੁੱਖ Makefile ਟਾਰਗੇਟ¶
make: Build Python with the standard library.make platform:: build thepythonprogram, but don't build the standard library extension modules.make profile-opt: build Python using Profile Guided Optimization (PGO). You can use the configure--enable-optimizationsoption to make this the default target of themakecommand (make allor justmake).make buildbottest: Build Python and run the Python test suite, the same way than buildbots test Python. SetTESTTIMEOUTvariable (in seconds) to change the test timeout (1200 by default: 20 minutes).make install: Build and install Python.make regen-all: Regenerate (almost) all generated files;make regen-stdlib-module-namesandautoconfmust be run separately for the remaining generated files.make clean: Remove built files.make distclean: Same thanmake clean, but remove also files created by the configure script.
3.2.4. C ਐਕਸਟੈਂਸ਼ਨ¶
ਕੁਝ C ਐਕਸਟੈਂਸ਼ਨਾਂ ਨੂੰ built-in ਮੋਡੀਊਲ ਵਜੋਂ ਬਿਲਡ ਕੀਤਾ ਜਾਂਦਾ ਹੈ, ਜਿਵੇਂ ਕਿ sys ਮੋਡੀਊਲ। ਇਹਨਾਂ ਨੂੰ Py_BUILD_CORE_BUILTIN ਮੈਕਰੋ ਪਰਿਭਾਸ਼ਿਤ ਕਰਕੇ ਬਿਲਡ ਕੀਤਾ ਜਾਂਦਾ ਹੈ। Built-in ਮੋਡੀਊਲਾਂ ਵਿੱਚ __file__ ਐਟ੍ਰਿਬਿਊਟ ਨਹੀਂ ਹੁੰਦਾ:
>>> import sys
>>> sys
<module 'sys' (built-in)>
>>> sys.__file__
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
AttributeError: module 'sys' has no attribute '__file__'
ਹੋਰ C ਐਕਸਟੈਂਸ਼ਨਾਂ ਨੂੰ ਡਾਇਨਾਮਿਕ ਲਾਇਬ੍ਰੇਰੀਆਂ ਵਜੋਂ ਬਿਲਡ ਕੀਤਾ ਜਾਂਦਾ ਹੈ, ਜਿਵੇਂ ਕਿ _asyncio ਮੋਡੀਊਲ। ਇਹਨਾਂ ਨੂੰ Py_BUILD_CORE_MODULE ਮੈਕਰੋ ਪਰਿਭਾਸ਼ਿਤ ਕਰਕੇ ਬਿਲਡ ਕੀਤਾ ਜਾਂਦਾ ਹੈ। Linux x86-64 ਉੱਤੇ ਉਦਾਹਰਨ:
>>> import _asyncio
>>> _asyncio
<module '_asyncio' from '/usr/lib64/python3.9/lib-dynload/_asyncio.cpython-39-x86_64-linux-gnu.so'>
>>> _asyncio.__file__
'/usr/lib64/python3.9/lib-dynload/_asyncio.cpython-39-x86_64-linux-gnu.so'
Modules/Setup ਦੀ ਵਰਤੋਂ C ਐਕਸਟੈਂਸ਼ਨਾਂ ਨੂੰ ਬਿਲਡ ਕਰਨ ਲਈ Makefile ਟਾਰਗੇਟ ਬਣਾਉਣ ਵਾਸਤੇ ਕੀਤੀ ਜਾਂਦੀ ਹੈ। ਫਾਈਲ ਦੀ ਸ਼ੁਰੂਆਤ ਵਿੱਚ C ਐਕਸਟੈਂਸ਼ਨਾਂ ਨੂੰ built-in ਮੋਡੀਊਲਾਂ ਵਜੋਂ ਬਿਲਡ ਕੀਤਾ ਜਾਂਦਾ ਹੈ। *shared* ਮਾਰਕਰ ਤੋਂ ਬਾਅਦ ਪਰਿਭਾਸ਼ਿਤ ਐਕਸਟੈਂਸ਼ਨਾਂ ਨੂੰ ਡਾਇਨਾਮਿਕ ਲਾਇਬ੍ਰੇਰੀਆਂ ਵਜੋਂ ਬਿਲਡ ਕੀਤਾ ਜਾਂਦਾ ਹੈ।
The setup.py script only builds C extensions as shared libraries using
the distutils module.
The PyAPI_FUNC(), PyAPI_DATA() and
PyMODINIT_FUNC macros of Include/pyport.h are defined
differently depending if the Py_BUILD_CORE_MODULE macro is defined:
ਜੇ
Py_BUILD_CORE_MODULEਪਰਿਭਾਸ਼ਿਤ ਹੈ ਤਾਂPy_EXPORTED_SYMBOLਵਰਤੋਨਹੀਂ ਤਾਂ
Py_IMPORTED_SYMBOLਵਰਤੋ।
ਜੇ ਸਾਂਝੀ ਲਾਇਬ੍ਰੇਰੀ ਵਜੋਂ ਬਿਲਡ ਕੀਤੀ ਗਈ C ਐਕਸਟੈਂਸ਼ਨ 'ਤੇ ਗਲਤੀ ਨਾਲ Py_BUILD_CORE_BUILTIN ਮੈਕਰੋ ਵਰਤਿਆ ਜਾਵੇ, ਤਾਂ ਇਸਦਾ PyInit_xxx() ਫੰਕਸ਼ਨ ਐਕਸਪੋਰਟ ਨਹੀਂ ਹੁੰਦਾ, ਜਿਸ ਕਾਰਨ ਇੰਪੋਰਟ ਸਮੇਂ ImportError ਆ ਜਾਂਦੀ ਹੈ।
3.3. ਕੰਪਾਈਲਰ ਅਤੇ ਲਿੰਕਰ ਫਲੈਗ¶
./configure ਸਕ੍ਰਿਪਟ ਅਤੇ ਇਨਵਾਇਰਨਮੈਂਟ ਵੇਰੀਏਬਲਾਂ ਦੁਆਰਾ ਸੈੱਟ ਕੀਤੀਆਂ ਚੋਣਾਂ, ਜੋ Makefile ਦੁਆਰਾ ਵਰਤੀਆਂ ਜਾਂਦੀਆਂ ਹਨ।
3.3.1. ਪ੍ਰੀ-ਪ੍ਰੋਸੈਸਰ ਫਲੈਗ¶
- CPPFLAGS¶
(Objective) C/C++ ਪ੍ਰੀ-ਪ੍ਰੋਸੈਸਰ ਫਲੈਗ, ਉਦਾਹਰਨ ਲਈ
-Iinclude_dir, ਜੇ ਤੁਹਾਡੀਆਂ ਹੈਡਰ ਫਾਈਲਾਂ ਕਿਸੇ ਗੈਰ-ਮਿਆਰੀ include_dir ਡਾਇਰੈਕਟਰੀ ਵਿੱਚ ਹਨ।Both
CPPFLAGSandLDFLAGSneed to contain the shell's value for setup.py to be able to build extension modules using the directories specified in the environment variables.
- BASECPPFLAGS¶
New in version 3.4.
- PY_CPPFLAGS¶
ਇੰਟਰਪ੍ਰੀਟਰ ਆਬਜੈਕਟ ਫਾਈਲਾਂ ਨੂੰ ਬਿਲਡ ਕਰਨ ਲਈ ਸ਼ਾਮਲ ਕੀਤੇ ਵਾਧੂ ਪ੍ਰੀ-ਪ੍ਰੋਸੈਸਰ ਫਲੈਗ।
ਮੂਲ:
$(BASECPPFLAGS) -I. -I$(srcdir)/Include $(CONFIGURE_CPPFLAGS) $(CPPFLAGS)।New in version 3.2.
3.3.2. ਕੰਪਾਈਲਰ ਫਲੈਗ¶
- CC¶
C compiler ਕਮਾਂਡ।
ਉਦਾਹਰਨ:
gcc -pthread।
- MAINCC¶
C compiler command used to build the
main()function of programs likepython.Variable set by the
--with-cxx-mainoption of the configure script.Default:
$(CC).
- CXX¶
C++ ਕੰਪਾਈਲਰ ਕਮਾਂਡ।
Used if the
--with-cxx-mainoption is used.ਉਦਾਹਰਨ:
g++ -pthread।
- CFLAGS¶
C compiler flags।
- CFLAGS_NODIST¶
CFLAGS_NODISTis used for building the interpreter and stdlib C extensions. Use it when a compiler flag should not be part of the distutilsCFLAGSonce Python is installed (bpo-21121).ਖ਼ਾਸ ਤੌਰ 'ਤੇ,
CFLAGSਵਿੱਚ ਹੇਠ ਲਿਖੇ ਸ਼ਾਮਲ ਨਹੀਂ ਹੋਣੇ ਚਾਹੀਦੇ:ਕੰਪਾਈਲਰ ਫਲੈਗ
-I(include ਫਾਈਲਾਂ ਲਈ ਖੋਜ ਮਾਰਗ ਸੈੱਟ ਕਰਨ ਵਾਸਤੇ)।-Iਫਲੈਗ ਖੱਬੇ ਤੋਂ ਸੱਜੇ ਪ੍ਰੋਸੈਸ ਕੀਤੇ ਜਾਂਦੇ ਹਨ ਅਤੇCFLAGSਵਿੱਚ ਮੌਜੂਦ ਕੋਈ ਵੀ ਫਲੈਗ ਯੂਜ਼ਰ ਜਾਂ ਪੈਕੇਜ ਦੁਆਰਾ ਦਿੱਤੇ-Iਫਲੈਗਾਂ ਨਾਲੋਂ ਪਹਿਲਾਂ ਲਾਗੂ ਹੋ ਜਾਣਗੇ।-Werrorਵਰਗੇ hardening ਫਲੈਗ, ਕਿਉਂਕਿ ਡਿਸਟ੍ਰਿਬਿਊਸ਼ਨ ਇਹ ਨਿਯੰਤਰਿਤ ਨਹੀਂ ਕਰ ਸਕਦੀਆਂ ਕਿ ਯੂਜ਼ਰਾਂ ਦੁਆਰਾ ਇੰਸਟਾਲ ਕੀਤੇ ਪੈਕੇਜ ਅਜਿਹੇ ਸਖ਼ਤ ਮਿਆਰਾਂ ਦੀ ਪਾਲਣਾ ਕਰਦੇ ਹਨ ਜਾਂ ਨਹੀਂ।
New in version 3.5.
- EXTRA_CFLAGS¶
ਵਾਧੂ C ਕੰਪਾਈਲਰ ਫਲੈਗ।
- CONFIGURE_CFLAGS_NODIST¶
./configureਸਕ੍ਰਿਪਟ ਨੂੰ ਦਿੱਤੇ ਗਏCFLAGS_NODISTਵੇਰੀਏਬਲ ਦਾ ਮੁੱਲ।New in version 3.5.
- BASECFLAGS¶
ਮੂਲ ਕੰਪਾਈਲਰ ਫਲੈਗ।
- OPT¶
ਓਪਟੀਮਾਈਜ਼ੇਸ਼ਨ ਫਲੈਗ।
- CFLAGS_ALIASING¶
Python/dtoa.cਨੂੰ ਕੰਪਾਈਲ ਕਰਨ ਲਈ ਵਰਤੇ ਜਾਣ ਵਾਲੇ strict ਜਾਂ non-strict aliasing ਫਲੈਗ।New in version 3.7.
- CCSHARED¶
ਸਾਂਝੀ ਲਾਇਬ੍ਰੇਰੀ ਬਣਾਉਣ ਲਈ ਵਰਤੇ ਜਾਣ ਵਾਲੇ ਕੰਪਾਈਲਰ ਫਲੈਗ।
ਉਦਾਹਰਨ ਲਈ, Linux ਅਤੇ BSD ਉੱਤੇ
-fPICਵਰਤਿਆ ਜਾਂਦਾ ਹੈ।
- CFLAGSFORSHARED¶
ਇੰਟਰਪ੍ਰੀਟਰ ਆਬਜੈਕਟ ਫਾਈਲਾਂ ਨੂੰ ਬਿਲਡ ਕਰਨ ਲਈ ਸ਼ਾਮਲ ਕੀਤੇ ਵਾਧੂ C ਫਲੈਗ।
ਮੂਲ: ਜੇ
--enable-sharedਵਰਤੀ ਗਈ ਹੈ ਤਾਂ$(CCSHARED), ਨਹੀਂ ਤਾਂ ਖਾਲੀ ਸਟਰਿੰਗ।
- PY_CFLAGS¶
ਮੂਲ:
$(BASECFLAGS) $(OPT) $(CONFIGURE_CFLAGS) $(CFLAGS) $(EXTRA_CFLAGS)।
- PY_CFLAGS_NODIST¶
ਮੂਲ:
$(CONFIGURE_CFLAGS_NODIST) $(CFLAGS_NODIST) -I$(srcdir)/Include/internal।New in version 3.5.
- PY_STDMODULE_CFLAGS¶
ਇੰਟਰਪ੍ਰੀਟਰ ਆਬਜੈਕਟ ਫਾਈਲਾਂ ਨੂੰ ਬਿਲਡ ਕਰਨ ਲਈ ਵਰਤੇ ਜਾਣ ਵਾਲੇ C ਫਲੈਗ।
ਮੂਲ:
$(PY_CFLAGS) $(PY_CFLAGS_NODIST) $(PY_CPPFLAGS) $(CFLAGSFORSHARED)।New in version 3.7.
- PY_CORE_CFLAGS¶
ਮੂਲ:
$(PY_STDMODULE_CFLAGS) -DPy_BUILD_CORE।New in version 3.2.
- PY_BUILTIN_MODULE_CFLAGS¶
posixਮੋਡੀਊਲ ਵਾਂਗ ਸਟੈਂਡਰਡ ਲਾਇਬ੍ਰੇਰੀ ਐਕਸਟੈਂਸ਼ਨ ਮੋਡੀਊਲ ਨੂੰ built-in ਮੋਡੀਊਲ ਵਜੋਂ ਬਿਲਡ ਕਰਨ ਲਈ ਕੰਪਾਈਲਰ ਫਲੈਗ।ਮੂਲ:
$(PY_STDMODULE_CFLAGS) -DPy_BUILD_CORE_BUILTIN।New in version 3.8.
- PURIFY¶
Purify ਕਮਾਂਡ। Purify ਇੱਕ ਮੈਮੋਰੀ ਡੀਬੱਗਰ ਪ੍ਰੋਗਰਾਮ ਹੈ।
ਮੂਲ: ਖਾਲੀ ਸਟਰਿੰਗ (ਵਰਤੀ ਨਹੀਂ ਜਾਂਦੀ)।
3.3.3. ਲਿੰਕਰ ਫਲੈਗ¶
- LINKCC¶
pythonਅਤੇ_testembedਵਰਗੇ ਪ੍ਰੋਗਰਾਮਾਂ ਨੂੰ ਬਿਲਡ ਕਰਨ ਲਈ ਵਰਤੀ ਜਾਣ ਵਾਲੀ ਲਿੰਕਰ ਕਮਾਂਡ।Default:
$(PURIFY) $(MAINCC).
- CONFIGURE_LDFLAGS¶
./configureਸਕ੍ਰਿਪਟ ਨੂੰ ਦਿੱਤੇ ਗਏLDFLAGSਵੇਰੀਏਬਲ ਦਾ ਮੁੱਲ।CFLAGS,LDFLAGSਆਦਿ ਨੂੰ ਸਿੱਧਾ ਮੁੱਲ ਨਾ ਦਿਓ, ਤਾਂ ਜੋ ਵਰਤੋਂਕਾਰ ਪਹਿਲਾਂ ਤੋਂ ਸੈੱਟ ਕੀਤੀਆਂ ਕੀਮਤਾਂ ਨੂੰ ਓਵਰਰਾਈਟ ਕੀਤੇ ਬਿਨਾਂ ਕਮਾਂਡ-ਲਾਈਨ ਰਾਹੀਂ ਇਨ੍ਹਾਂ ਵਿੱਚ ਆਪਣੀਆਂ ਕੀਮਤਾਂ ਜੋੜ ਸਕਣ।New in version 3.2.
- LDFLAGS_NODIST¶
LDFLAGS_NODISTis used in the same manner asCFLAGS_NODIST. Use it when a linker flag should not be part of the distutilsLDFLAGSonce Python is installed (bpo-35257).ਖ਼ਾਸ ਤੌਰ 'ਤੇ,
LDFLAGSਵਿੱਚ ਹੇਠ ਲਿਖੇ ਸ਼ਾਮਲ ਨਹੀਂ ਹੋਣੇ ਚਾਹੀਦੇ:ਕੰਪਾਈਲਰ ਫਲੈਗ
-L(ਲਾਇਬ੍ਰੇਰੀਆਂ ਲਈ ਖੋਜ ਮਾਰਗ ਸੈੱਟ ਕਰਨ ਵਾਸਤੇ)।-Lਫਲੈਗ ਖੱਬੇ ਤੋਂ ਸੱਜੇ ਪ੍ਰੋਸੈਸ ਕੀਤੇ ਜਾਂਦੇ ਹਨ ਅਤੇLDFLAGSਵਿੱਚ ਮੌਜੂਦ ਕੋਈ ਵੀ ਫਲੈਗ ਯੂਜ਼ਰ ਜਾਂ ਪੈਕੇਜ ਦੁਆਰਾ ਦਿੱਤੇ-Lਫਲੈਗਾਂ ਨਾਲੋਂ ਪਹਿਲਾਂ ਲਾਗੂ ਹੋ ਜਾਣਗੇ।
- CONFIGURE_LDFLAGS_NODIST¶
./configureਸਕ੍ਰਿਪਟ ਨੂੰ ਦਿੱਤੇ ਗਏLDFLAGS_NODISTਵੇਰੀਏਬਲ ਦਾ ਮੁੱਲ।New in version 3.8.
- LDFLAGS¶
ਲਿੰਕਰ ਫਲੈਗ, ਉਦਾਹਰਨ ਲਈ
-Llib_dir, ਜੇ ਤੁਹਾਡੀਆਂ ਲਾਇਬ੍ਰੇਰੀਆਂ ਕਿਸੇ ਗੈਰ-ਮਿਆਰੀ lib_dir ਡਾਇਰੈਕਟਰੀ ਵਿੱਚ ਹਨ।Both
CPPFLAGSandLDFLAGSneed to contain the shell's value for setup.py to be able to build extension modules using the directories specified in the environment variables.
- LIBS¶
Python ਐਗਜ਼ਿਕਿਊਟੇਬਲ ਨੂੰ ਲਿੰਕ ਕਰਦੇ ਸਮੇਂ ਲਾਇਬ੍ਰੇਰੀਆਂ ਨੂੰ ਲਿੰਕਰ ਤੱਕ ਭੇਜਣ ਲਈ ਵਰਤੇ ਜਾਣ ਵਾਲੇ ਲਿੰਕਰ ਫਲੈਗ।
ਉਦਾਹਰਨ:
-lrt।
- LDSHARED¶
ਸਾਂਝੀ ਲਾਇਬ੍ਰੇਰੀ ਬਣਾਉਣ ਲਈ ਕਮਾਂਡ।
ਮੂਲ:
@LDSHARED@ $(PY_LDFLAGS)।
- BLDSHARED¶
libpythonਸਾਂਝੀ ਲਾਇਬ੍ਰੇਰੀ ਬਣਾਉਣ ਲਈ ਕਮਾਂਡ।ਮੂਲ:
@BLDSHARED@ $(PY_CORE_LDFLAGS)।
- PY_LDFLAGS¶
ਮੂਲ:
$(CONFIGURE_LDFLAGS) $(LDFLAGS)।
- PY_LDFLAGS_NODIST¶
ਮੂਲ:
$(CONFIGURE_LDFLAGS_NODIST) $(LDFLAGS_NODIST)।New in version 3.8.
- PY_CORE_LDFLAGS¶
ਇੰਟਰਪ੍ਰੀਟਰ ਆਬਜੈਕਟ ਫਾਈਲਾਂ ਨੂੰ ਬਿਲਡ ਕਰਨ ਲਈ ਵਰਤੇ ਜਾਣ ਵਾਲੇ ਲਿੰਕਰ ਫਲੈਗ।
New in version 3.8.