source: general/prog/python3.xml@ 5cfcafe

10.0 10.1 11.0 11.1 11.2 11.3 12.0 12.1 7.10 7.4 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 5cfcafe was 5cfcafe, checked in by Krejzi <krejzi@…>, 11 years ago

Fixes

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

  • Property mode set to 100644
File size: 9.7 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 "http://www.python.org/ftp/python/&python3-version;/Python-&python3-version;.tar.xz">
9 <!ENTITY python3-download-ftp " ">
10 <!ENTITY python3-md5sum "993232d9f4d9b4863cc1ec69a792e9cd">
11 <!ENTITY python3-size "12 MB">
12 <!ENTITY python3-buildsize "260 MB (not including the testsuite)">
13 <!ENTITY python3-time "1.2 SBU (not including the testsuite)">
14
15 <!ENTITY python3htmldoc-download-http
16 "http://docs.python.org/ftp/python/doc/&python3-version;/python-&python3-version;-docs-html.tar.bz2">
17 <!ENTITY python3htmldoc-md5sum "e730def6cc4d6dddb076aae82661b6d6">
18 <!ENTITY python3htmldoc-size "4.6 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 &lfs73_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="expat"/>,
106 <xref linkend="libffi"/> and
107 <xref linkend="pkgconfig"/>
108 </para>
109
110 <bridgehead renderas="sect4">Optional</bridgehead>
111 <para role="optional">
112 <xref linkend="bluez"/>
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>sed "s@\"\$CFLAGS -Werror\"@\"\$CFLAGS -Werror -Wformat\"@g" -i configure &amp;&amp;
137./configure --prefix=/usr \
138 --enable-shared \
139 --with-system-expat \
140 --with-system-ffi &amp;&amp;
141make</userinput></screen>
142
143 <para>
144 To test the results, issue: <command>make test</command>.
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 -m755 -d /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 </sect2>
169
170 <sect2 role="commands">
171 <title>Command Explanations</title>
172
173 <para>
174 <command>sed "s@\"\$CFLAGS -Werror\"@\"\$CFLAGS -Werror -Wformat\"@g"
175 -i configure</command>: Fixes building with
176 <application>GCC</application> 4.8.
177 </para>
178
179 <para>
180 <option>--with-system-expat</option>: This switch enables linking against
181 system version of <application>Expat</application>. Remove if you have
182 not installed recommended dependency <xref linkend="expat"/>.
183 </para>
184
185 <para>
186 <option>--with-system-ffi</option>: This switch enables linking against
187 system version of <application>libffi</application>. Remove if you have
188 not installed recommended dependency <xref linkend="libffi"/>.
189 </para>
190
191 <para>
192 <parameter>--with-dbmliborder=bdb:gdbm:ndbm</parameter>: Use this switch
193 if you want to build <application>Python</application> DBM Module
194 against <application>Berkeley DB</application> instead of
195 <application>GDBM</application>.
196 </para>
197
198 <para>
199 <command>chmod ...</command>: Fix permissions for shared libraries to be
200 consistent with other libraries.
201 </para>
202
203 </sect2>
204
205 <sect2 role="configuration">
206 <title>Configuring Python 3</title>
207
208 <para>
209 In order for <command>python3</command> to find the installed
210 documentation, you must add the following environment variable to
211 individual user's or the system's profile:
212 </para>
213
214<screen role="root"><userinput>export PYTHONDOCS=/usr/share/doc/python-&python3-version;/html</userinput></screen>
215
216 </sect2>
217
218 <sect2 role="content">
219 <title>Contents</title>
220
221 <segmentedlist>
222 <segtitle>Installed Programs</segtitle>
223 <segtitle>Installed Libraries</segtitle>
224 <segtitle>Installed Directories</segtitle>
225
226 <seglistitem>
227 <seg>
228 2to3 (symbolic link to 2to3-&python3-majorver;),
229 2to3-&python3-majorver;,
230
231 pydoc3 (symbolic link to pydoc&python3-majorver;),
232 pydoc&python3-majorver;,
233
234 python3 (hard link to python&python3-majorver;m),
235 python&python3-majorver; (hard link to python&python3-majorver;m),
236 python&python3-majorver;m,
237
238 python3-config (symbolic link to python&python3-majorver;-config),
239 python&python3-majorver;-config (symbolic link to python3-config),
240 python&python3-majorver;m-config,
241
242 and optionally if Tk is installed,
243 idle3 (symbolic link to idle&python3-majorver;),
244 idle&python3-majorver;
245 </seg>
246 <seg>
247 libpython&python3-majorver;m.so and libpython3.so
248 </seg>
249 <seg>
250 /usr/include/python&python3-majorver;m,
251 /usr/lib/python&python3-majorver;, and
252 /usr/share/doc/python-&python3-version;
253 </seg>
254 </seglistitem>
255 </segmentedlist>
256
257 <variablelist>
258 <bridgehead renderas="sect3">Short Descriptions</bridgehead>
259 <?dbfo list-presentation="list"?>
260 <?dbhtml list-presentation="table"?>
261
262 <varlistentry id="idle3">
263 <term><command>idle3</command></term>
264 <listitem>
265 <para>
266 is a wrapper script that opens a
267 <application>Python</application> aware GUI editor.
268 </para>
269 <indexterm zone="python3 idle3">
270 <primary sortas="b-idle3">idle3</primary>
271 </indexterm>
272 </listitem>
273 </varlistentry>
274
275 <varlistentry id="pydoc3">
276 <term><command>pydoc3</command></term>
277 <listitem>
278 <para>
279 is the <application>Python</application> documentation
280 tool.
281 </para>
282 <indexterm zone="python3 pydoc3">
283 <primary sortas="b-pydoc3">pydo3c</primary>
284 </indexterm>
285 </listitem>
286 </varlistentry>
287
288 <varlistentry id="python3-prog">
289 <term><command>python3</command></term>
290 <listitem>
291 <para>
292 is an interpreted, interactive, object-oriented programming
293 language.
294 </para>
295 <indexterm zone="python3 python3-prog">
296 <primary sortas="b-python3">python3</primary>
297 </indexterm>
298 </listitem>
299 </varlistentry>
300
301 <varlistentry id="python-ver">
302 <term><command>python&python3-majorver;</command></term>
303 <listitem>
304 <para>
305 is a version-specific name for the <command>python</command>
306 program.
307 </para>
308 <indexterm zone="python3 python-ver">
309 <primary
310 sortas="b-python&python3-majorver;">python&python3-majorver;</primary>
311 </indexterm>
312 </listitem>
313 </varlistentry>
314
315 </variablelist>
316
317 </sect2>
318
319</sect1>
Note: See TracBrowser for help on using the repository browser.