source: general/prog/python3.xml@ d52c17f

systemd-13485
Last change on this file since d52c17f was d52c17f, checked in by Douglas R. Reno <renodr@…>, 8 years ago

Update to elfutils-0.164
Update to Python-3.5.0

git-svn-id: svn://svn.linuxfromscratch.org/BLFS/branches/systemd@16667 af4574ff-66df-0310-9fd7-8a98e5e911e0

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