source: general/prog/python3.xml@ 7745345d

10.0 10.1 11.0 11.1 11.2 11.3 12.0 12.1 7.10 7.5 7.6 7.6-blfs 7.6-systemd 7.7 7.8 7.9 8.0 8.1 8.2 8.3 8.4 9.0 9.1 basic bdubbs/svn elogind gnome kde5-13430 kde5-14269 kde5-14686 kea ken/TL2024 ken/inkscape-core-mods ken/tuningfonts krejzi/svn lazarus lxqt nosym perl-modules plabs/newcss plabs/python-mods python3.11 qt5new rahul/power-profiles-daemon renodr/vulkan-addition systemd-11177 systemd-13485 trunk upgradedb xry111/intltool xry111/llvm18 xry111/soup3 xry111/test-20220226 xry111/xf86-video-removal
Last change on this file since 7745345d was 7745345d, checked in by Fernando de Oliveira <fernando@…>, 10 years ago

Python-3.3.4. Rephrase discussion abou the test suite.

git-svn-id: svn://svn.linuxfromscratch.org/BLFS/trunk/BOOK@12691 af4574ff-66df-0310-9fd7-8a98e5e911e0

  • Property mode set to 100644
File size: 10.7 KB
RevLine 
[52d29f7]1<?xml version="1.0" encoding="ISO-8859-1"?>
[6732c094]2<!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
3 "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd" [
[52d29f7]4 <!ENTITY % general-entities SYSTEM "../../general.ent">
5 %general-entities;
6
[2cee003]7 <!ENTITY python3-download-http
[355495ce]8 "http://www.python.org/ftp/python/&python3-version;/Python-&python3-version;.tar.xz">
9 <!ENTITY python3-download-ftp " ">
[7fe0ce3b]10 <!ENTITY python3-md5sum "8fb961a20600aafafd249537af3ac637">
[03d30cf]11 <!ENTITY python3-size "12 MB">
[7fe0ce3b]12 <!ENTITY python3-buildsize "260 MB (225 MB without docs or 144 MB for the tests)">
13 <!ENTITY python3-time "1.0 SBU (or 2.5 SBU for the tests)">
[82fac2c]14
[2cee003]15 <!ENTITY python3htmldoc-download-http
[355495ce]16 "http://docs.python.org/ftp/python/doc/&python3-version;/python-&python3-version;-docs-html.tar.bz2">
[7fe0ce3b]17 <!ENTITY python3htmldoc-md5sum "81d3756044c4af97b61ebf003a301a07">
[21e8edc]18 <!ENTITY python3htmldoc-size "4.8 MB">
[52d29f7]19]>
20
[b88be39]21<sect1 id="python3" xreflabel="Python-&python3-version;">
22 <?dbhtml filename="python3.html" ?>
[83f69e5d]23
24 <sect1info>
25 <othername>$LastChangedBy$</othername>
26 <date>$Date$</date>
27 </sect1info>
28
[b88be39]29 <title>Python-&python3-version;</title>
[83f69e5d]30
[b88be39]31 <indexterm zone="python3">
[03d30cf]32 <primary sortas="a-Python3">Python3</primary>
[83f69e5d]33 </indexterm>
34
35 <sect2 role="package">
[03d30cf]36 <title>Introduction to Python 3</title>
[83f69e5d]37
[355495ce]38 <para>
[03d30cf]39 The <application>Python 3</application> package contains the
[355495ce]40 <application>Python</application> development environment.
41 This is useful for object-oriented programming, writing scripts,
42 prototyping large programs or developing entire applications.
43 </para>
[48b816cb]44
[3ed51307]45 &lfs74_checked;
[48b816cb]46
[83f69e5d]47 <bridgehead renderas="sect3">Package Information</bridgehead>
48 <itemizedlist spacing="compact">
49 <listitem>
[355495ce]50 <para>
51 Download (HTTP): <ulink url="&python3-download-http;"/>
52 </para>
[83f69e5d]53 </listitem>
54 <listitem>
[355495ce]55 <para>
56 Download (FTP): <ulink url="&python3-download-ftp;"/>
57 </para>
[83f69e5d]58 </listitem>
59 <listitem>
[355495ce]60 <para>
61 Download MD5 sum: &python3-md5sum;
62 </para>
[83f69e5d]63 </listitem>
64 <listitem>
[355495ce]65 <para>
66 Download size: &python3-size;
67 </para>
[83f69e5d]68 </listitem>
69 <listitem>
[355495ce]70 <para>
71 Estimated disk space required: &python3-buildsize;
72 </para>
[83f69e5d]73 </listitem>
74 <listitem>
[355495ce]75 <para>
76 Estimated build time: &python3-time;
77 </para>
[83f69e5d]78 </listitem>
79 </itemizedlist>
80
81 <bridgehead renderas="sect3">Additional Downloads</bridgehead>
[355495ce]82 <itemizedlist spacing="compact">
[3a94882]83 <title>Optional HTML Documentation</title>
[1970f00]84 <listitem>
[355495ce]85 <para>
86 Download (HTTP): <ulink url="&python3htmldoc-download-http;"/>
87 </para>
[3a94882]88 </listitem>
89 <listitem>
[355495ce]90 <para>
91 Download MD5 sum: &python3htmldoc-md5sum;
92 </para>
[3a94882]93 </listitem>
94 <listitem>
[355495ce]95 <para>
96 Download size: &python3htmldoc-size;
97 </para>
[1970f00]98 </listitem>
99 </itemizedlist>
100
[03d30cf]101 <bridgehead renderas="sect3">Python 3 Dependencies</bridgehead>
[83f69e5d]102
[355495ce]103 <bridgehead renderas="sect4">Recommended</bridgehead>
104 <para role="recommended">
[adf6dd9a]105 <xref linkend="expat"/> and
106 <xref linkend="libffi"/>
[355495ce]107 </para>
108
[83f69e5d]109 <bridgehead renderas="sect4">Optional</bridgehead>
[355495ce]110 <para role="optional">
[7fe0ce3b]111 <xref linkend="bluez"/>,
[7745345d]112 <xref linkend="gdb"/> (required for some tests), and
[21e8edc]113 <ulink url="http://www.valgrind.org/">Valgrind</ulink>
[355495ce]114 </para>
115
116 <bridgehead renderas="sect4">Optional (For Additional Modules)</bridgehead>
117 <para role="optional">
[82fac2c]118 <xref linkend="db"/>,
[355495ce]119 <xref linkend="openssl"/>,
120 <xref linkend="sqlite"/> and
121 <xref linkend="tk"/>
122 </para>
[ce33273]123
[1039de3]124 <para condition="html" role="usernotes">User Notes:
[355495ce]125 <ulink url="&blfs-wiki;/Python3"/>
126 </para>
[83f69e5d]127 </sect2>
128
129 <sect2 role="installation">
[03d30cf]130 <title>Installation of Python 3</title>
[83f69e5d]131
[355495ce]132 <para>
[03d30cf]133 Install <application>Python 3</application> by running the following
[355495ce]134 commands:
135 </para>
[83f69e5d]136
[23d3543c]137<screen><userinput>./configure --prefix=/usr \
[c525bd1]138 --enable-shared \
[355495ce]139 --with-system-expat \
140 --with-system-ffi &amp;&amp;
[83f69e5d]141make</userinput></screen>
142
[355495ce]143 <para>
[7fe0ce3b]144 The test suite must be run separately, using an X terminal (see below).
[355495ce]145 </para>
146
147 <para>
148 Now, as the <systemitem class="username">root</systemitem> user:
149 </para>
150
[82fac2c]151<screen role="root"><userinput>make install &amp;&amp;
[c525bd1]152chmod -v 755 /usr/lib/libpython&python3-majorver;m.so &amp;&amp;
[355495ce]153chmod -v 755 /usr/lib/libpython3.so</userinput></screen>
154
155 <para>
[03d30cf]156 If you have downloaded the preformatted documentation from
157 <ulink url="http://docs.python.org/download.html"/>, install it
158 as the <systemitem class="username">root</systemitem> user:
[355495ce]159 </para>
[1970f00]160
[23d3543c]161<screen role="root"><userinput>install -v -dm755 /usr/share/doc/python-&python3-version;/html &amp;&amp;
[1970f00]162tar --strip-components=1 \
[cff8f9e]163 --no-same-owner \
164 --no-same-permissions \
[03d30cf]165 -C /usr/share/doc/python-&python3-version;/html \
[716ca8aa]166 -xvf ../python-&python3-version;-docs-html.tar.bz2</userinput></screen>
[1970f00]167
[7fe0ce3b]168 <para>
169 The test suite must be run separately from the build, either before or
[7745345d]170 after the package is built and installed. Do not run
171 <command>make install</command>, after running the test suite. To build
172 and install the package, you need to start with a fresh or clean source
173 tree. For the test, you also need a clean source code, so either start by
174 removing the source code directory and starting over, by uncompressing
175 the source tarball or by running <command>make clean</command>. Then
176 configure again, adding <quote>--with-pydebug</quote> to the
177 <command>configure</command> switches above, run <command>make</command>,
178 then <command>make test</command>. Remember that some tests fail, if not
179 run in an X terminal.
[7fe0ce3b]180 </para>
181
[879d269]182 </sect2>
183
184 <sect2 role="commands">
185 <title>Command Explanations</title>
186
[355495ce]187 <para>
[82fac2c]188 <option>--with-system-expat</option>: This switch enables linking against
[355495ce]189 system version of <application>Expat</application>. Remove if you have
190 not installed recommended dependency <xref linkend="expat"/>.
191 </para>
192
193 <para>
194 <option>--with-system-ffi</option>: This switch enables linking against
195 system version of <application>libffi</application>. Remove if you have
196 not installed recommended dependency <xref linkend="libffi"/>.
197 </para>
198
[82fac2c]199 <para>
200 <parameter>--with-dbmliborder=bdb:gdbm:ndbm</parameter>: Use this switch
201 if you want to build <application>Python</application> DBM Module
202 against <application>Berkeley DB</application> instead of
203 <application>GDBM</application>.
204 </para>
205
[355495ce]206 <para>
[0d7900a]207 <command>chmod ...</command>: Fix permissions for shared libraries to be
[355495ce]208 consistent with other libraries.
209 </para>
[7224506]210
[879d269]211 </sect2>
212
213 <sect2 role="configuration">
[03d30cf]214 <title>Configuring Python 3</title>
[879d269]215
[355495ce]216 <para>
[03d30cf]217 In order for <command>python3</command> to find the installed
[355495ce]218 documentation, you must add the following environment variable to
219 individual user's or the system's profile:
220 </para>
[1970f00]221
[03d30cf]222<screen role="root"><userinput>export PYTHONDOCS=/usr/share/doc/python-&python3-version;/html</userinput></screen>
[83f69e5d]223
224 </sect2>
225
226 <sect2 role="content">
227 <title>Contents</title>
228
229 <segmentedlist>
230 <segtitle>Installed Programs</segtitle>
231 <segtitle>Installed Libraries</segtitle>
232 <segtitle>Installed Directories</segtitle>
233
234 <seglistitem>
[355495ce]235 <seg>
[7fe0ce3b]236 2to3 (symlink),
[355495ce]237 2to3-&python3-majorver;,
238
[7fe0ce3b]239 pydoc3 (symlink),
[355495ce]240 pydoc&python3-majorver;,
241
[7fe0ce3b]242 python3 (symlink);
243 python&python3-majorver; and python&python3-majorver;m (hardlinked);
[355495ce]244
[7fe0ce3b]245 python3-config (symlink),
246 python&python3-majorver;-config (symlink),
[c525bd1]247 python&python3-majorver;m-config,
[355495ce]248
[7fe0ce3b]249 pyvenv (symlink),
[21e8edc]250 pyvenv&python3-majorver;,
251
252 and optionally, if Tk is installed,
[7fe0ce3b]253 idle3 (symlink) and
[355495ce]254 idle&python3-majorver;
255 </seg>
256 <seg>
[7fe0ce3b]257 libpython&python3-majorver;m.so and libpython3.so;
258 several under /usr/lib/python3.3/lib-dynload/
[355495ce]259 </seg>
260 <seg>
[c525bd1]261 /usr/include/python&python3-majorver;m,
[355495ce]262 /usr/lib/python&python3-majorver;, and
263 /usr/share/doc/python-&python3-version;
264 </seg>
[83f69e5d]265 </seglistitem>
266 </segmentedlist>
267
268 <variablelist>
269 <bridgehead renderas="sect3">Short Descriptions</bridgehead>
270 <?dbfo list-presentation="list"?>
271 <?dbhtml list-presentation="table"?>
272
[355495ce]273 <varlistentry id="idle3">
274 <term><command>idle3</command></term>
[83f69e5d]275 <listitem>
[355495ce]276 <para>
277 is a wrapper script that opens a
278 <application>Python</application> aware GUI editor.
279 </para>
280 <indexterm zone="python3 idle3">
281 <primary sortas="b-idle3">idle3</primary>
[83f69e5d]282 </indexterm>
283 </listitem>
284 </varlistentry>
285
[355495ce]286 <varlistentry id="pydoc3">
287 <term><command>pydoc3</command></term>
[83f69e5d]288 <listitem>
[355495ce]289 <para>
290 is the <application>Python</application> documentation
291 tool.
292 </para>
293 <indexterm zone="python3 pydoc3">
294 <primary sortas="b-pydoc3">pydo3c</primary>
[83f69e5d]295 </indexterm>
296 </listitem>
297 </varlistentry>
298
[b88be39]299 <varlistentry id="python3-prog">
[2cee003]300 <term><command>python3</command></term>
[83f69e5d]301 <listitem>
[355495ce]302 <para>
303 is an interpreted, interactive, object-oriented programming
304 language.
305 </para>
[b88be39]306 <indexterm zone="python3 python3-prog">
307 <primary sortas="b-python3">python3</primary>
[83f69e5d]308 </indexterm>
309 </listitem>
310 </varlistentry>
311
[f67f5387]312 <varlistentry id="python-ver">
[b88be39]313 <term><command>python&python3-majorver;</command></term>
[83f69e5d]314 <listitem>
[355495ce]315 <para>
316 is a version-specific name for the <command>python</command>
317 program.
318 </para>
[b88be39]319 <indexterm zone="python3 python-ver">
[2cee003]320 <primary
321 sortas="b-python&python3-majorver;">python&python3-majorver;</primary>
[83f69e5d]322 </indexterm>
323 </listitem>
324 </varlistentry>
325
[21e8edc]326 <varlistentry id="pyvenv">
327 <term><command>pyvenv</command></term>
328 <listitem>
329 <para>
330 creates virtual <application>Python</application> environments in
331 one or more target directories.
332 </para>
333 <indexterm zone="python3 pyvenv">
334 <primary
335 sortas="b-python&python3-majorver;">python&python3-majorver;</primary>
336 </indexterm>
337 </listitem>
338 </varlistentry>
339
[83f69e5d]340 </variablelist>
341
342 </sect2>
[f45b1953]343
344</sect1>
Note: See TracBrowser for help on using the repository browser.