[eab03ca] | 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 |
|
---|
[8dfc5c3] | 7 | <!ENTITY pth-download-http "&gnu-http;/pth/pth-&pth-version;.tar.gz">
|
---|
| 8 | <!ENTITY pth-download-ftp "&gnu-ftp;/pth/pth-&pth-version;.tar.gz">
|
---|
[eab03ca] | 9 | <!ENTITY pth-md5sum "9cb4a25331a4c4db866a31cbe507c793">
|
---|
| 10 | <!ENTITY pth-size "652 KB">
|
---|
| 11 | <!ENTITY pth-buildsize "5 MB">
|
---|
| 12 | <!ENTITY pth-time "0.2 SBU">
|
---|
| 13 | ]>
|
---|
| 14 |
|
---|
| 15 | <sect1 id="pth" xreflabel="Pth-&pth-version;">
|
---|
| 16 | <?dbhtml filename="pth.html"?>
|
---|
| 17 |
|
---|
| 18 |
|
---|
| 19 | <title>Pth-&pth-version;</title>
|
---|
| 20 |
|
---|
| 21 | <indexterm zone="pth">
|
---|
| 22 | <primary sortas="a-Pth">Pth</primary>
|
---|
| 23 | </indexterm>
|
---|
| 24 |
|
---|
| 25 | <sect2 role="package">
|
---|
| 26 | <title>Introduction to Pth</title>
|
---|
| 27 |
|
---|
[d56e7df] | 28 | <para>
|
---|
| 29 | The <application>Pth</application> package contains a very portable
|
---|
| 30 | POSIX/ANSI-C based library for Unix platforms which provides
|
---|
| 31 | non-preemptive priority-based scheduling for multiple threads of
|
---|
| 32 | execution (multithreading) inside event-driven applications. All
|
---|
| 33 | threads run in the same address space of the server application, but
|
---|
| 34 | each thread has its own individual program-counter, run-time stack,
|
---|
| 35 | signal mask and errno variable.
|
---|
| 36 | </para>
|
---|
[eab03ca] | 37 |
|
---|
[9b8ff698] | 38 | &lfs112_checked;
|
---|
[70dcb19] | 39 |
|
---|
[eab03ca] | 40 | <bridgehead renderas="sect3">Package Information</bridgehead>
|
---|
| 41 | <itemizedlist spacing="compact">
|
---|
| 42 | <listitem>
|
---|
[d56e7df] | 43 | <para>
|
---|
| 44 | Download (HTTP): <ulink url="&pth-download-http;"/>
|
---|
| 45 | </para>
|
---|
[eab03ca] | 46 | </listitem>
|
---|
| 47 | <listitem>
|
---|
[d56e7df] | 48 | <para>
|
---|
| 49 | Download (FTP): <ulink url="&pth-download-ftp;"/>
|
---|
| 50 | </para>
|
---|
[eab03ca] | 51 | </listitem>
|
---|
| 52 | <listitem>
|
---|
[d56e7df] | 53 | <para>
|
---|
| 54 | Download MD5 sum: &pth-md5sum;
|
---|
| 55 | </para>
|
---|
[eab03ca] | 56 | </listitem>
|
---|
| 57 | <listitem>
|
---|
[d56e7df] | 58 | <para>
|
---|
| 59 | Download size: &pth-size;
|
---|
| 60 | </para>
|
---|
[eab03ca] | 61 | </listitem>
|
---|
| 62 | <listitem>
|
---|
[d56e7df] | 63 | <para>
|
---|
| 64 | Estimated disk space required: &pth-buildsize;
|
---|
| 65 | </para>
|
---|
[eab03ca] | 66 | </listitem>
|
---|
| 67 | <listitem>
|
---|
[d56e7df] | 68 | <para>
|
---|
| 69 | Estimated build time: &pth-time;
|
---|
| 70 | </para>
|
---|
[eab03ca] | 71 | </listitem>
|
---|
| 72 | </itemizedlist>
|
---|
| 73 |
|
---|
[023cc87] | 74 | <bridgehead renderas="sect3">Pth Dependencies</bridgehead>
|
---|
| 75 |
|
---|
[673c070] | 76 | <bridgehead renderas="sect4">Optional</bridgehead>
|
---|
[023cc87] | 77 | <para role="optional">
|
---|
[673c070] | 78 | <xref linkend="gcc"/> (for gfortran) and
|
---|
[8558044] | 79 | <xref linkend="libnsl"/>
|
---|
[023cc87] | 80 | </para>
|
---|
| 81 |
|
---|
[eab03ca] | 82 | <para condition="html" role="usernotes">User Notes:
|
---|
| 83 | <ulink url="&blfs-wiki;/pth"/></para>
|
---|
| 84 | </sect2>
|
---|
| 85 |
|
---|
| 86 | <sect2 role="installation">
|
---|
| 87 | <title>Installation of Pth</title>
|
---|
| 88 |
|
---|
[98b5744] | 89 | <caution>
|
---|
[d56e7df] | 90 | <para>
|
---|
| 91 | Don't add the <option>--enable-pthread</option> parameter to the
|
---|
| 92 | <command>configure</command> command below else you will overwrite the
|
---|
| 93 | pthread library and interface header installed by the
|
---|
| 94 | <application>Glibc</application> package in LFS.
|
---|
| 95 | </para>
|
---|
[98b5744] | 96 | </caution>
|
---|
| 97 |
|
---|
[d56e7df] | 98 | <para>
|
---|
| 99 | Install <application>Pth</application> by running the
|
---|
| 100 | following commands:
|
---|
| 101 | </para>
|
---|
[eab03ca] | 102 |
|
---|
[bfa1248] | 103 | <screen><userinput>sed -i 's#$(LOBJS): Makefile#$(LOBJS): pth_p.h Makefile#' Makefile.in &&
|
---|
[601a838] | 104 | ./configure --prefix=/usr \
|
---|
| 105 | --disable-static \
|
---|
| 106 | --mandir=/usr/share/man &&
|
---|
[eab03ca] | 107 | make</userinput></screen>
|
---|
| 108 |
|
---|
[d56e7df] | 109 | <para>
|
---|
| 110 | To test the results, issue: <command>make test</command>.
|
---|
| 111 | </para>
|
---|
[eab03ca] | 112 |
|
---|
[d56e7df] | 113 | <para>
|
---|
| 114 | Now, as the <systemitem class="username">root</systemitem>
|
---|
| 115 | user:
|
---|
| 116 | </para>
|
---|
[eab03ca] | 117 |
|
---|
| 118 | <screen role="root"><userinput>make install &&
|
---|
| 119 | install -v -m755 -d /usr/share/doc/pth-&pth-version; &&
|
---|
| 120 | install -v -m644 README PORTING SUPPORT TESTS \
|
---|
| 121 | /usr/share/doc/pth-&pth-version;</userinput></screen>
|
---|
[bfa1248] | 122 | </sect2>
|
---|
| 123 |
|
---|
| 124 | <sect2 role="commands">
|
---|
| 125 | <title>Command Explanations</title>
|
---|
| 126 |
|
---|
[d56e7df] | 127 | <para>
|
---|
| 128 | <command>sed -i 's#$(LOBJS) ...</command>: This <command>sed</command>
|
---|
| 129 | fixes a race condition in the <filename>Makefile</filename>. It allows
|
---|
| 130 | running <command>make</command> with multiple jobs (e.g., <command>make
|
---|
| 131 | -j4</command>).
|
---|
| 132 | <!-- how ironic that a package for using multiple threads has this bug in
|
---|
| 133 | its Makefile -->
|
---|
| 134 | </para>
|
---|
[eab03ca] | 135 |
|
---|
[f1d7196] | 136 | <xi:include xmlns:xi="http://www.w3.org/2001/XInclude"
|
---|
| 137 | href="../../xincludes/static-libraries.xml"/>
|
---|
[bfa1248] | 138 |
|
---|
[d56e7df] | 139 | <para>
|
---|
| 140 | <parameter>--mandir=/usr/share/man</parameter>: This switch puts the
|
---|
| 141 | man pages in <filename class="directory">/usr/share/man</filename> instead
|
---|
| 142 | of <filename class="directory">/usr/man</filename>.
|
---|
| 143 | </para>
|
---|
[eab03ca] | 144 | </sect2>
|
---|
| 145 |
|
---|
| 146 | <sect2 role="content">
|
---|
| 147 | <title>Contents</title>
|
---|
| 148 |
|
---|
| 149 | <segmentedlist>
|
---|
| 150 | <segtitle>Installed Program</segtitle>
|
---|
| 151 | <segtitle>Installed Library</segtitle>
|
---|
| 152 | <segtitle>Installed Directory</segtitle>
|
---|
| 153 |
|
---|
| 154 | <seglistitem>
|
---|
| 155 | <seg>pth-config</seg>
|
---|
[bfa1248] | 156 | <seg>libpth.so</seg>
|
---|
[eab03ca] | 157 | <seg>/usr/share/doc/pth-&pth-version;</seg>
|
---|
| 158 | </seglistitem>
|
---|
| 159 | </segmentedlist>
|
---|
| 160 |
|
---|
| 161 | <variablelist>
|
---|
| 162 | <bridgehead renderas="sect3">Short Descriptions</bridgehead>
|
---|
| 163 | <?dbfo list-presentation="list"?>
|
---|
| 164 | <?dbhtml list-presentation="table"?>
|
---|
| 165 |
|
---|
| 166 | <varlistentry id="pth-config">
|
---|
| 167 | <term><command>pth-config</command></term>
|
---|
| 168 | <listitem>
|
---|
[d56e7df] | 169 | <para>
|
---|
| 170 | is a utility used to configure and build applications based on
|
---|
| 171 | the pth(3) library. It can be used to query the C compiler and
|
---|
| 172 | linker flags which are required to correctly compile and link the
|
---|
[4c24eb0a] | 173 | application against the pth(3) library
|
---|
[d56e7df] | 174 | </para>
|
---|
[eab03ca] | 175 | <indexterm zone="pth pth-config">
|
---|
| 176 | <primary sortas="b-pth-config">pth-config</primary>
|
---|
| 177 | </indexterm>
|
---|
| 178 | </listitem>
|
---|
| 179 | </varlistentry>
|
---|
| 180 |
|
---|
| 181 | <varlistentry id="libpth">
|
---|
[bfa1248] | 182 | <term><filename class="libraryfile">libpth.so</filename></term>
|
---|
[eab03ca] | 183 | <listitem>
|
---|
[d56e7df] | 184 | <para>
|
---|
| 185 | contains the API functions used by the GNU Portable Threads
|
---|
[4c24eb0a] | 186 | Library
|
---|
[d56e7df] | 187 | </para>
|
---|
[eab03ca] | 188 | <indexterm zone="pth libpth">
|
---|
[bfa1248] | 189 | <primary sortas="c-libpth">libpth.so</primary>
|
---|
[eab03ca] | 190 | </indexterm>
|
---|
| 191 | </listitem>
|
---|
| 192 | </varlistentry>
|
---|
| 193 | </variablelist>
|
---|
| 194 | </sect2>
|
---|
[4c24eb0a] | 195 |
|
---|
[eab03ca] | 196 | </sect1>
|
---|