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