[ab4fdfc] | 1 | <?xml version="1.0" encoding="UTF-8"?>
|
---|
[6732c094] | 2 | <!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
|
---|
| 3 | "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd" [
|
---|
[52d29f7] | 4 | <!ENTITY % general-entities SYSTEM "../../general.ent">
|
---|
| 5 | %general-entities;
|
---|
| 6 |
|
---|
[7526f4f] | 7 | <!ENTITY pcre-download-http "https://sourceforge.net/projects/pcre/files/pcre/8.45/pcre-&pcre-version;.tar.bz2">
|
---|
| 8 | <!ENTITY pcre-download-ftp " ">
|
---|
[6b06d8bc] | 9 | <!ENTITY pcre-md5sum "4452288e6a0eefb2ab11d36010a1eebb">
|
---|
[7de152b] | 10 | <!ENTITY pcre-size "1.5 MB">
|
---|
[6b06d8bc] | 11 | <!ENTITY pcre-buildsize "23 MB (with tests)">
|
---|
[041db65] | 12 | <!ENTITY pcre-time "0.3 SBU (with tests)">
|
---|
[52d29f7] | 13 | ]>
|
---|
| 14 |
|
---|
[9d0cd203] | 15 | <sect1 id="pcre" xreflabel="PCRE-&pcre-version;">
|
---|
[469ad5d0] | 16 | <?dbhtml filename="pcre.html"?>
|
---|
[4c3474fe] | 17 |
|
---|
| 18 |
|
---|
[469ad5d0] | 19 | <title>PCRE-&pcre-version;</title>
|
---|
[4c3474fe] | 20 |
|
---|
[469ad5d0] | 21 | <indexterm zone="pcre">
|
---|
| 22 | <primary sortas="a-PCRE">PCRE</primary>
|
---|
| 23 | </indexterm>
|
---|
| 24 |
|
---|
| 25 | <sect2 role="package">
|
---|
| 26 | <title>Introduction to PCRE</title>
|
---|
[4c3474fe] | 27 |
|
---|
[ea16306] | 28 | <para>
|
---|
| 29 | The <application>PCRE</application> package contains
|
---|
| 30 | <application>Perl</application> Compatible Regular Expression
|
---|
| 31 | libraries. These are useful for implementing regular expression
|
---|
| 32 | pattern matching using the same syntax and semantics as
|
---|
| 33 | <application>Perl</application> 5.
|
---|
| 34 | </para>
|
---|
[4c3474fe] | 35 |
|
---|
[b9874725] | 36 | &lfs121_checked;
|
---|
[7f4cdbc0] | 37 |
|
---|
[469ad5d0] | 38 | <bridgehead renderas="sect3">Package Information</bridgehead>
|
---|
| 39 | <itemizedlist spacing="compact">
|
---|
| 40 | <listitem>
|
---|
[ea16306] | 41 | <para>
|
---|
| 42 | Download (HTTP): <ulink url="&pcre-download-http;"/>
|
---|
| 43 | </para>
|
---|
| 44 | </listitem>
|
---|
[469ad5d0] | 45 | <listitem>
|
---|
[ea16306] | 46 | <para>
|
---|
| 47 | Download (FTP): <ulink url="&pcre-download-ftp;"/>
|
---|
| 48 | </para>
|
---|
[469ad5d0] | 49 | </listitem>
|
---|
| 50 | <listitem>
|
---|
[ea16306] | 51 | <para>
|
---|
| 52 | Download MD5 sum: &pcre-md5sum;
|
---|
| 53 | </para>
|
---|
[469ad5d0] | 54 | </listitem>
|
---|
| 55 | <listitem>
|
---|
[ea16306] | 56 | <para>
|
---|
| 57 | Download size: &pcre-size;
|
---|
| 58 | </para>
|
---|
[469ad5d0] | 59 | </listitem>
|
---|
| 60 | <listitem>
|
---|
[ea16306] | 61 | <para>
|
---|
| 62 | Estimated disk space required: &pcre-buildsize;
|
---|
| 63 | </para>
|
---|
[469ad5d0] | 64 | </listitem>
|
---|
| 65 | <listitem>
|
---|
[ea16306] | 66 | <para>
|
---|
| 67 | Estimated build time: &pcre-time;
|
---|
| 68 | </para>
|
---|
[469ad5d0] | 69 | </listitem>
|
---|
| 70 | </itemizedlist>
|
---|
[1c8a9c9d] | 71 |
|
---|
[33a9814] | 72 | <bridgehead renderas="sect3">PCRE Dependencies</bridgehead>
|
---|
| 73 |
|
---|
| 74 | <bridgehead renderas="sect4">Optional</bridgehead>
|
---|
| 75 | <para role="optional">
|
---|
[f1607a4] | 76 | <xref linkend="valgrind"/>
|
---|
[33a9814] | 77 | </para>
|
---|
| 78 |
|
---|
[469ad5d0] | 79 | </sect2>
|
---|
[4c3474fe] | 80 |
|
---|
[469ad5d0] | 81 | <sect2 role="installation">
|
---|
| 82 | <title>Installation of PCRE</title>
|
---|
| 83 |
|
---|
[ea16306] | 84 | <para>
|
---|
| 85 | Install <application>PCRE</application> by running
|
---|
| 86 | the following commands:
|
---|
| 87 | </para>
|
---|
| 88 |
|
---|
[2086c106] | 89 | <screen><userinput>./configure --prefix=/usr \
|
---|
[ea16306] | 90 | --docdir=/usr/share/doc/pcre-&pcre-version; \
|
---|
[500d604a] | 91 | --enable-unicode-properties \
|
---|
[0eba16e] | 92 | --enable-pcre16 \
|
---|
| 93 | --enable-pcre32 \
|
---|
[500d604a] | 94 | --enable-pcregrep-libz \
|
---|
| 95 | --enable-pcregrep-libbz2 \
|
---|
[839ac504] | 96 | --enable-pcretest-libreadline \
|
---|
[500d604a] | 97 | --disable-static &&
|
---|
[469ad5d0] | 98 | make</userinput></screen>
|
---|
[4fa8bf55] | 99 |
|
---|
[ea16306] | 100 | <para>
|
---|
| 101 | To test the results, issue: <command>make check</command>.
|
---|
| 102 | </para>
|
---|
[4c3474fe] | 103 |
|
---|
[ea16306] | 104 | <para>
|
---|
| 105 | Now, as the <systemitem class="username">root</systemitem> user:
|
---|
| 106 | </para>
|
---|
[4c3474fe] | 107 |
|
---|
[aab13c9] | 108 | <screen role="root"><userinput>make install</userinput></screen>
|
---|
[e959f37] | 109 |
|
---|
[469ad5d0] | 110 | </sect2>
|
---|
[4c3474fe] | 111 |
|
---|
[469ad5d0] | 112 | <sect2 role="commands">
|
---|
| 113 | <title>Command Explanations</title>
|
---|
| 114 |
|
---|
[ea16306] | 115 | <para>
|
---|
[4edb9a6] | 116 | <parameter>--enable-unicode-properties</parameter>: This switch enables
|
---|
[e81d71b] | 117 | Unicode properties support and includes the code for handling UTF-8/16/32
|
---|
[4edb9a6] | 118 | character strings in the library. You need this switch if you are going to
|
---|
[ac7f1b0] | 119 | build <xref linkend="glib2"/>.
|
---|
[ea16306] | 120 | </para>
|
---|
| 121 |
|
---|
[0eba16e] | 122 | <para>
|
---|
[4edb9a6] | 123 | <parameter>--enable-pcre16</parameter>: This switch enables 16 bit
|
---|
[0eba16e] | 124 | character support.
|
---|
| 125 | </para>
|
---|
| 126 |
|
---|
| 127 | <para>
|
---|
[4edb9a6] | 128 | <parameter>--enable-pcre32</parameter>: This switch enables 32 bit
|
---|
[0eba16e] | 129 | character support.
|
---|
| 130 | </para>
|
---|
| 131 |
|
---|
[ea16306] | 132 | <para>
|
---|
[4edb9a6] | 133 | <parameter>--enable-pcregrep-libz</parameter>: This switch adds
|
---|
[ea16306] | 134 | support to <command>pcregrep</command> to read
|
---|
| 135 | <filename class="extension">.gz</filename> compressed files.
|
---|
| 136 | </para>
|
---|
| 137 |
|
---|
| 138 | <para>
|
---|
[4edb9a6] | 139 | <parameter>--enable-pcregrep-libbz2</parameter>: This switch adds
|
---|
[ea16306] | 140 | support to <command>pcregrep</command> to read
|
---|
| 141 | <filename class="extension">.bz2</filename> compressed files.
|
---|
| 142 | </para>
|
---|
| 143 |
|
---|
[839ac504] | 144 | <para>
|
---|
[4edb9a6] | 145 | <parameter>--enable-pcretest-libreadline</parameter>: This switch adds line
|
---|
[839ac504] | 146 | editing and history features to <command>pcretest</command> program.
|
---|
| 147 | </para>
|
---|
| 148 |
|
---|
[ea16306] | 149 | <xi:include xmlns:xi="http://www.w3.org/2001/XInclude"
|
---|
| 150 | href="../../xincludes/static-libraries.xml"/>
|
---|
| 151 |
|
---|
[aab13c9] | 152 | <!-- FIXME: Removed due to merged-/usr setup
|
---|
[ea16306] | 153 | <para>
|
---|
[500d604a] | 154 | <command>mv -v /usr/lib/libpcre.so.* /lib</command>: Moves the
|
---|
[ea16306] | 155 | <application>PCRE</application> library on the root filesystem
|
---|
| 156 | so that it is available in case <command>grep</command>
|
---|
| 157 | gets reinstalled with <application>PCRE</application> support.
|
---|
| 158 | </para>
|
---|
[aab13c9] | 159 | -->
|
---|
[ea16306] | 160 |
|
---|
[d86a91f] | 161 | <para>
|
---|
| 162 | <option>--enable-jit</option>: this option enables Just-in-time
|
---|
| 163 | compiling, which can greatly speed up pattern matching.
|
---|
| 164 | </para>
|
---|
| 165 |
|
---|
[469ad5d0] | 166 | </sect2>
|
---|
[4c3474fe] | 167 |
|
---|
[469ad5d0] | 168 | <sect2 role="content">
|
---|
| 169 | <title>Contents</title>
|
---|
| 170 |
|
---|
| 171 | <segmentedlist>
|
---|
| 172 | <segtitle>Installed Programs</segtitle>
|
---|
| 173 | <segtitle>Installed Libraries</segtitle>
|
---|
[4c288b0] | 174 | <segtitle>Installed Directory</segtitle>
|
---|
[4c3474fe] | 175 |
|
---|
[469ad5d0] | 176 | <seglistitem>
|
---|
[ea16306] | 177 | <seg>
|
---|
[041db65] | 178 | pcregrep, pcretest, and pcre-config
|
---|
[ea16306] | 179 | </seg>
|
---|
| 180 | <seg>
|
---|
[0eba16e] | 181 | libpcre.so, libpcre16.so, libpcre32.so,
|
---|
| 182 | libpcrecpp.so and libpcreposix.so
|
---|
[ea16306] | 183 | </seg>
|
---|
| 184 | <seg>
|
---|
| 185 | /usr/share/doc/pcre-&pcre-version;
|
---|
| 186 | </seg>
|
---|
[469ad5d0] | 187 | </seglistitem>
|
---|
| 188 | </segmentedlist>
|
---|
[4c3474fe] | 189 |
|
---|
[469ad5d0] | 190 | <variablelist>
|
---|
| 191 | <bridgehead renderas="sect3">Short Descriptions</bridgehead>
|
---|
| 192 | <?dbfo list-presentation="list"?>
|
---|
| 193 | <?dbhtml list-presentation="table"?>
|
---|
[4c3474fe] | 194 |
|
---|
[469ad5d0] | 195 | <varlistentry id="pcregrep">
|
---|
| 196 | <term><command>pcregrep</command></term>
|
---|
| 197 | <listitem>
|
---|
[ea16306] | 198 | <para>
|
---|
| 199 | is a <command>grep</command> that understands
|
---|
[4c24eb0a] | 200 | <application>Perl</application> compatible regular expressions
|
---|
[ea16306] | 201 | </para>
|
---|
[469ad5d0] | 202 | <indexterm zone="pcre pcregrep">
|
---|
| 203 | <primary sortas="b-pcregrep">pcregrep</primary>
|
---|
| 204 | </indexterm>
|
---|
| 205 | </listitem>
|
---|
| 206 | </varlistentry>
|
---|
[4c3474fe] | 207 |
|
---|
[469ad5d0] | 208 | <varlistentry id="pcretest">
|
---|
| 209 | <term><command>pcretest</command></term>
|
---|
| 210 | <listitem>
|
---|
[ea16306] | 211 | <para>
|
---|
| 212 | can test a <application>Perl</application> compatible
|
---|
[4c24eb0a] | 213 | regular expression
|
---|
[ea16306] | 214 | </para>
|
---|
[469ad5d0] | 215 | <indexterm zone="pcre pcretest">
|
---|
| 216 | <primary sortas="b-pcretest">pcretest</primary>
|
---|
| 217 | </indexterm>
|
---|
| 218 | </listitem>
|
---|
| 219 | </varlistentry>
|
---|
[4c3474fe] | 220 |
|
---|
[469ad5d0] | 221 | <varlistentry id="pcre-config">
|
---|
| 222 | <term><command>pcre-config</command></term>
|
---|
| 223 | <listitem>
|
---|
[ea16306] | 224 | <para>
|
---|
| 225 | is used during the compile process of programs linking to
|
---|
[4c24eb0a] | 226 | the <application>PCRE</application> libraries
|
---|
[ea16306] | 227 | </para>
|
---|
[469ad5d0] | 228 | <indexterm zone="pcre pcre-config">
|
---|
| 229 | <primary sortas="b-pcre-config">pcre-config</primary>
|
---|
| 230 | </indexterm>
|
---|
| 231 | </listitem>
|
---|
| 232 | </varlistentry>
|
---|
[ea16306] | 233 |
|
---|
[469ad5d0] | 234 | </variablelist>
|
---|
[ea16306] | 235 |
|
---|
[469ad5d0] | 236 | </sect2>
|
---|
[ea16306] | 237 |
|
---|
[f45b1953] | 238 | </sect1>
|
---|