mirror of
https://github.com/Zeckmathederg/glfs.git
synced 2025-01-24 15:12:11 +08:00
3b78237cc0
git-svn-id: svn://svn.linuxfromscratch.org/BLFS/trunk/BOOK@19649 af4574ff-66df-0310-9fd7-8a98e5e911e0
158 lines
5.0 KiB
XML
158 lines
5.0 KiB
XML
<?xml version="1.0" encoding="ISO-8859-1"?>
|
|
<!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
|
|
"http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd" [
|
|
<!ENTITY % general-entities SYSTEM "../../general.ent">
|
|
%general-entities;
|
|
|
|
<!ENTITY setuptools-download-http
|
|
"https://pypi.python.org/packages/source/s/setuptools/setuptools-&setuptools-version;.tar.gz">
|
|
<!ENTITY setuptools-download-ftp " ">
|
|
<!ENTITY setuptools-md5sum "10407f6737d8dc37e5310e68c1f1f6ec">
|
|
<!ENTITY setuptools-size "616 KB">
|
|
<!ENTITY setuptools-buildsize "8.6 MB (additional 4.4 MB for tests)">
|
|
<!ENTITY setuptools-time "less than 0.1 SBU (additional 2.1 SBU for tests)">
|
|
]>
|
|
|
|
<!-- Begin Setuptools -->
|
|
<sect2 id="setuptools" xreflabel="Setuptools-&setuptools-version;">
|
|
|
|
<title>Setuptools-&setuptools-version;</title>
|
|
|
|
<indexterm zone="setuptools">
|
|
<primary sortas="a-Setuptools">Setuptools</primary>
|
|
</indexterm>
|
|
|
|
<sect3 role="package">
|
|
<title>Introduction to Setuptools Module</title>
|
|
|
|
<para>
|
|
<application>Setuptools</application> is a fully-featured,
|
|
actively-maintained, and stable library designed to facilitate
|
|
packaging <application>Python</application> projects.
|
|
</para>
|
|
|
|
&lfs77_checked;
|
|
|
|
<bridgehead renderas="sect4">Package Information</bridgehead>
|
|
<itemizedlist spacing="compact">
|
|
<listitem>
|
|
<para>
|
|
Download (HTTP): <ulink url="&setuptools-download-http;"/>
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
Download (FTP): <ulink url="&setuptools-download-ftp;"/>
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
Download MD5 sum: &setuptools-md5sum;
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
Download size: &setuptools-size;
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
Estimated disk space required: &setuptools-buildsize;
|
|
</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>
|
|
Estimated build time: &setuptools-time;
|
|
</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
|
|
<bridgehead renderas="sect4">Setuptools Dependencies</bridgehead>
|
|
|
|
<bridgehead renderas="sect5">Required</bridgehead>
|
|
<para role="required">
|
|
<xref linkend="python2"/> or <xref linkend="python3"/>
|
|
</para>
|
|
|
|
<para condition="html" role="usernotes">
|
|
User Notes: <ulink url="&blfs-wiki;/setuptools"/>
|
|
</para>
|
|
</sect3>
|
|
|
|
<sect3 role="installation">
|
|
<title>Installation of Setuptools</title>
|
|
|
|
<note>
|
|
<para>
|
|
Both <application>Python 2</application> and
|
|
<application>Python 3</application> modules can
|
|
be built and installed without any conflicts.
|
|
</para>
|
|
</note>
|
|
|
|
<para>
|
|
To install <application>Setuptools</application> for <application>Python
|
|
2</application>, run the following command as the <systemitem
|
|
class="username">root</systemitem> user:
|
|
</para>
|
|
|
|
<screen role="root"><userinput>python setup.py install --optimize=1</userinput></screen>
|
|
|
|
<para>
|
|
To install <application>Setuptools</application> for <application>Python
|
|
3</application>, run the following command as the <systemitem
|
|
class="username">root</systemitem> user:
|
|
</para>
|
|
|
|
<screen role="root"><userinput>sed -i "s:easy_install:&3:" setup.py &&
|
|
python3 setup.py install --optimize=1</userinput></screen>
|
|
|
|
<para>
|
|
Run the tests by issuing <command>python setup.py test</command> and/or
|
|
<command>python3 setup.py test</command>. The tests need an active
|
|
internet connection. Optional python modules mock, pytest and py will be
|
|
downloaded and installed during the tests.
|
|
</para>
|
|
|
|
|
|
</sect3>
|
|
|
|
<sect3 role="commands">
|
|
<title>Command Explanations</title>
|
|
|
|
<para>
|
|
<command>sed -i "s:easy_install:&3:g" setup.py</command>: This sed
|
|
prevents <command>setup.py</command> from overwriting an already
|
|
installed script by the <application>Python 2</application> module.
|
|
Remove it if you are building this module only for
|
|
<application>Python 3</application>.
|
|
</para>
|
|
|
|
</sect3>
|
|
|
|
<sect3 role="content">
|
|
<title>Contents</title>
|
|
|
|
<segmentedlist>
|
|
<segtitle>Installed Programs</segtitle>
|
|
<segtitle>Installed Library</segtitle>
|
|
<segtitle>Installed Directory</segtitle>
|
|
|
|
<seglistitem>
|
|
<seg>
|
|
easy_install, easy_install-&python2-majorver;, and/or
|
|
easy_install3, easy_install3-&python3-majorver;
|
|
</seg>
|
|
<seg>
|
|
setuptools-&setuptools-version;-py&python2-majorver;.egg and/or
|
|
setuptools-&setuptools-version;-py&python3-majorver;.egg
|
|
</seg>
|
|
<seg>
|
|
None
|
|
</seg>
|
|
</seglistitem>
|
|
</segmentedlist>
|
|
</sect3>
|
|
</sect2>
|
|
<!-- End Setuptools -->
|