source: general/prog/php.xml@ 02be53d8

12.2 gimp3 lazarus trunk xry111/for-12.3 xry111/spidermonkey128
Last change on this file since 02be53d8 was adabb5d, checked in by Douglas R. Reno <renodr@…>, 3 months ago

PHP: fix a rendering error

  • Property mode set to 100644
File size: 27.4 KB
RevLine 
[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" [
[08254fc]4 <!ENTITY % general-entities SYSTEM "../../general.ent">
5 %general-entities;
6
[c6b192c]7 <!ENTITY php-download-http "https://www.php.net/distributions/php-&php-version;.tar.xz">
[0c54cea]8 <!ENTITY php-download-ftp " ">
[f7aa1d4]9 <!ENTITY php-md5sum "3a731ebd24cd36c70148416703ba2f0e">
10 <!ENTITY php-size "11.9 MB">
11 <!ENTITY php-buildsize "533 MB (with documentation and tests)">
[d9c72a3]12 <!ENTITY php-time "1.9 SBU (with parallelism=4; add 1.8 SBU for tests)">
[75cf6e3]13 <!-- Tests were run for 8.0.1 at -j4, had two timeouts as well.
14 Results were otherwise normal though, so I'm unsure of what caused the
[1c7c64d]15 increase in time. -renodr
[5d69f635]16 No timeout for 8.0.2. Tests run at -j4 too. -pierre
[8558044]17 No timeouts on 8.0.3 for me this time. -renodr
18 No timeouts on 8.0.5 -bdubbs
[65d85668]19 No timeouts, one failure on 8.0.9 -bdubbs
[178b967]20 No timeouts on 8.0.10 - thomas
[fe323d3]21 No timeouts on 8.0.11 - thomas
[178b967]22
[95f2d4b]23TEST RESULT SUMMARY 8.1.0
[a6d98c2c]24
[95f2d4b]25Exts skipped : 36
26Exts tested : 36
[a6d98c2c]27
[95f2d4b]28Number of tests : 17060 12551
[d02eab5]29Tests skipped : 4509 ( 26.4%)
[178b967]30Tests warned : 2 ( 0.0%) ( 0.0%)
[95f2d4b]31Tests failed : 4 ( 0.0%) ( 0.0%)
32Expected fail : 28 ( 0.2%) ( 0.2%)
33Tests passed : 12517 ( 73.4%) ( 99.7%)
34
35Time taken : 165 seconds
[a6d98c2c]36
[2bc1450]37Stats for tests changed slightly for 8.1.1, but not significantly.
38Stats for tests changed slightly for 8.1.2, but not significantly.
[d02eab5]39 Tests failed : 1
[eb31c6d3]40For 8.1.4, ran tests at -j4. One test still fails.
41For 8.1.5, ran tests at -j4. One test still fails.
[199a3ced]42
[1fe05eb]43Running tests at -j4 does nothing. The jobs cound is not passed to the
[199a3ced]44actual routine running the tests.
45
46For 8.1.7:
47Number of tests : 17250 12714
[1fe05eb]48Tests skipped : 4536 ( 26.3%)
[199a3ced]49Tests warned : 2 ( 0.0%) ( 0.0%)
50Tests failed : 1 ( 0.0%) ( 0.0%)
51Expected fail : 27 ( 0.2%) ( 0.2%)
52Tests passed : 12684 ( 73.5%) ( 99.8%)
53
54Time taken : 162 seconds
55
56The warnings are really XFAIL. The FAIL is ext/phar/tests/bug69958.phpt.
57It appears to be mission a test file.
58
[79f4a45]59For 8.1.10:
60Number of tests : 17315 12768
[9d9e7a6]61Tests skipped : 4547 ( 26.3%) - - - - - - - -
[79f4a45]62Tests warned : 2 ( 0.0%) ( 0.0%)
63Tests failed : 5 ( 0.0%) ( 0.0%)
64Expected fail : 27 ( 0.2%) ( 0.2%)
65Tests passed : 12734 ( 73.5%) ( 99.7%)
66
67Time taken : 162 seconds
[ec886f9a]68
69For 8.2.0:
70Number of tests : 17768 13167
[3d17248]71Tests skipped : 4601 ( 25.9%) - - - - - - - -
[ec886f9a]72Tests warned : 3 ( 0.0%) ( 0.0%)
73Tests failed : 1 ( 0.0%) ( 0.0%)
74Expected fail : 25 ( 0.1%) ( 0.2%)
75Tests passed : 13138 ( 73.9%) ( 99.8%)
76
77Time taken : 166 seconds
[f30c0dc]78
79For 8.3.0:
80Number of tests : 18682 13904
[0be945f]81Tests skipped : 4778 ( 25.6%) - - - - - - - -
[f30c0dc]82Tests warned : 1 ( 0.0%) ( 0.0%)
83Tests failed : 8 ( 0.0%) ( 0.1%)
84Expected fail : 9 ( 0.0%) ( 0.1%)
85Tests passed : 13886 ( 74.3%) ( 99.9%)
86
87Time taken : 183 seconds
[ef15363]88
89For 8.3.1: [rahul] (Ryzen 7 1700)
90
91Number of tests : 18706 13767
[a007a58]92Tests skipped : 4939 ( 26.4%)
[ef15363]93Tests warned : 0 ( 0.0%) ( 0.0%)
94Tests failed : 1 ( 0.0%) ( 0.0%)
95Expected fail : 9 ( 0.0%) ( 0.1%)
96Tests passed : 13757 ( 73.5%) ( 99.9%)
97
98Time taken : 301 seconds
99
[d9c72a3]100For 8.3.6: [bdubbs] (AMD 3900)
101
102Number of tests : 18777 13968
103Tests skipped : 4809 ( 25.6%)
104Tests warned : 1 ( 0.0%) ( 0.0%)
105Tests failed : 2 ( 0.0%) ( 0.0%)
106Expected fail : 9 ( 0.0%) ( 0.1%)
107Tests passed : 13956 ( 74.3%) ( 99.9%)
108
109Time taken : 189 seconds
110
[264e9bb2]1118.3.7 gave me (thomas) a few more failed tests but
112they are caused by redirected stderr/stdout/stdin
113and not running on a tty. The overall amounts seems
114comparable to 8.3.6
115
[f7aa1d4]116
[adabb5d]117- - - 8.3.8 [renodr] (Xeon E5-2670 v3) - - -
[f7aa1d4]118Number of tests : 18820 14004
[adabb5d]119Tests skipped : 4816 ( 25.6%) - - - - - - - -
[f7aa1d4]120Tests warned : 1 ( 0.0%) ( 0.0%)
121Tests failed : 6 ( 0.0%) ( 0.0%)
122Expected fail : 10 ( 0.1%) ( 0.1%)
123Tests passed : 13987 ( 74.3%) ( 99.9%)
124Time taken : 264 seconds
[fe323d3]125-->
[ef15363]126
[08254fc]127]>
128
[6683a00]129<sect1 id="php" xreflabel="PHP-&php-version;">
[db81e4cb]130 <?dbhtml filename="php.html"?>
131
132
133 <title>PHP-&php-version;</title>
134
135 <indexterm zone="php">
136 <primary sortas="a-PHP">PHP</primary>
137 </indexterm>
138
139 <sect2 role="package">
140 <title>Introduction to PHP</title>
141
[577eb27]142 <para>
143 <application>PHP</application> is the PHP Hypertext Preprocessor.
144 Primarily used in dynamic web sites, it allows for programming code to be
145 directly embedded into the HTML markup. It is also useful as a
146 general purpose scripting language.
147 </para>
[a5db8d2]148
[f722f5b]149 &lfs121_checked;
[db81e4cb]150
151 <bridgehead renderas="sect3">Package Information</bridgehead>
152 <itemizedlist spacing="compact">
153 <listitem>
[577eb27]154 <para>
155 Download (HTTP): <ulink url="&php-download-http;"/>
156 </para>
[db81e4cb]157 </listitem>
158 <listitem>
[577eb27]159 <para>
160 Download (FTP): <ulink url="&php-download-ftp;"/>
161 </para>
[db81e4cb]162 </listitem>
163 <listitem>
[577eb27]164 <para>
165 Download MD5 sum: &php-md5sum;
166 </para>
[db81e4cb]167 </listitem>
168 <listitem>
[577eb27]169 <para>
170 Download size: &php-size;
171 </para>
[db81e4cb]172 </listitem>
173 <listitem>
[577eb27]174 <para>
175 Estimated disk space required: &php-buildsize;
176 </para>
[db81e4cb]177 </listitem>
178 <listitem>
[577eb27]179 <para>
180 Estimated build time: &php-time;
181 </para>
[db81e4cb]182 </listitem>
183 </itemizedlist>
184
185 <bridgehead renderas="sect3">Additional Downloads</bridgehead>
186 <itemizedlist spacing="compact">
[b84326b7]187 <listitem>
[577eb27]188 <para>
[1e5323fd]189 Optional pre-built documentation (single file html): <ulink
190 url="https://www.php.net/distributions/manual/php_manual_en.html.gz"/>
191 </para>
192 </listitem>
193 <listitem>
194 <para>
195 Optional pre-built documentation (chunked html): <ulink
196 url="https://www.php.net/distributions/manual/php_manual_en.tar.gz"/>.
197 Note that the documentation can be found in languages other than
[80106051]198 English at <ulink url="https://www.php.net/download-docs.php"/>
[577eb27]199 </para>
[b84326b7]200 </listitem>
[db81e4cb]201 </itemizedlist>
202
203 <bridgehead renderas="sect3">PHP Dependencies</bridgehead>
204
[2f65edb]205 <bridgehead renderas="sect4">Recommended</bridgehead>
[2e4782e]206 <para role="recommended">
207 <xref linkend="apache"/> and
208 <xref linkend="libxml2"/>
209 </para>
[2f65edb]210
[b84326b7]211 <bridgehead renderas="sect4">Optional System Utilities and Libraries</bridgehead>
[577eb27]212 <para role="optional">
213 <xref linkend="aspell"/>,
214 <xref linkend="enchant"/>,
[604bf744]215 <xref linkend="libxslt"/>,
[577eb27]216 an <xref linkend="server-mail"/> (that provides a
[604bf744]217 <command>sendmail</command> command),
[580ce98]218 <xref linkend="pcre2"/>,
[c93c9bf4]219 <ulink url="https://wiki.ubuntu.com/AppArmor">AppArmor</ulink>,
[80106051]220 <ulink url="https://dmalloc.com/">Dmalloc</ulink>,
[577eb27]221 <ulink url="http://www.net-snmp.org/">Net-SNMP</ulink>,
[1f6b261]222 <ulink url="https://github.com/kkos/oniguruma">oniguruma</ulink>,
[604bf744]223 <ulink url="http://www.ossp.org/pkg/lib/mm/">OSSP mm</ulink>,
[80106051]224 <ulink url="https://re2c.org/">re2c</ulink>, and
[17aa21c]225 <ulink url="https://xmlrpc-epi.sourceforge.net/main.php?t=php_about">XMLRPC-EPI</ulink>
[577eb27]226 </para>
[b84326b7]227
228 <bridgehead renderas="sect4">Optional Graphics Utilities and Libraries</bridgehead>
[577eb27]229 <para role="optional">
[604bf744]230 <xref linkend="freetype2"/>,
231 <xref linkend="libexif"/>,
[577eb27]232 <xref linkend="libjpeg"/>,
233 <xref linkend="libpng"/>,
[604bf744]234 <xref linkend="libtiff"/>,
[75cf6e3]235 <xref linkend="libwebp"/>,
[577eb27]236 <xref linkend="x-window-system"/>,
[b8efb1fb]237 <!--<ulink url="http://www.fastio.com/">ClibPDF</ulink>, - site asks for username/password-->
[1e64cfb1]238 <ulink url="https://opensource.adobe.com/dc-acrobat-sdk-docs/acrobatsdk/">FDF Toolkit</ulink>,
[c93c9bf4]239 <ulink url="https://github.com/libgd/libgd">GD</ulink>, and
[eb19654e]240 <ulink url="https://www.t1lib.org/">t1lib</ulink>
[577eb27]241 </para>
[b84326b7]242
243 <bridgehead renderas="sect4">Optional Web Utilities</bridgehead>
[577eb27]244 <para role="optional">
245 <xref linkend="curl"/>,
[2b65035a]246 <xref linkend="tidy-html5"/>,
[c6b192c]247 <ulink url="https://sourceforge.net/projects/caudium/">Caudium</ulink>,
[bd86aa8]248 <ulink url="https://www.hyperwave.com/en/">Hyperwave</ulink>,
[80106051]249 <ulink url="https://download.roxen.com/6.1/">Roxen WebServer</ulink>, and
[5d69f635]250 <ulink url="https://github.com/Bilal-S/WDDX.net">WDDX</ulink>
[577eb27]251 </para>
[b84326b7]252
253 <bridgehead renderas="sect4">Optional Data Management Utilities and Libraries</bridgehead>
[577eb27]254 <para role="optional">
[c93c9bf4]255 <xref linkend="libiodbc"/>,
256 <xref linkend="lmdb"/>,
[80106051]257 <xref linkend="mariadb"/> or <ulink url="https://www.mysql.com/">MySQL</ulink>,
[604bf744]258 <xref linkend="openldap"/>,
[577eb27]259 <xref linkend="postgresql"/>,
260 <xref linkend="sqlite"/>,
[604bf744]261 <xref linkend="unixodbc"/>,
[dcd5a063]262 &berkeley-db;
[1e64cfb1]263 <ulink url="https://www.softwareag.com/en_corporate/platform/adabas-natural.html">Adabas</ulink>,
[3c8c8b2]264 <ulink url="https://raima.com/product-overview/">Birdstep</ulink>,
[80106051]265 <ulink url="https://cr.yp.to/cdb.html">cdb</ulink>,
266 <ulink url="https://www.dbmaker.com/">DBMaker</ulink>,
[604bf744]267 <ulink url="http://www.empress.com/">Empress</ulink>,
[b8efb1fb]268 <ulink url="http://www.frontbase.com/cgi-bin/WebObjects/FBWebSite">FrontBase</ulink>,
[c93c9bf4]269 <ulink url="https://www.ibm.com/analytics/us/en/db2/">IBM DB2</ulink>,
[80106051]270 <ulink url="https://hughestech.com.au/products/msql/">Mini SQL</ulink>,
271 <ulink url="https://www.monetra.com/">Monetra</ulink>, and
[c6b192c]272 <ulink url="https://sourceforge.net/projects/qdbm">QDBM</ulink>
[577eb27]273 </para>
274
275 <para>
276 <application>PHP</application> also provides support for many
277 commercial database tools such as <application>Oracle</application>,
278 <application>SAP</application> and
279 <application>ODBC Router</application>.
280 </para>
[e797436]281
[b84326b7]282 <bridgehead renderas="sect4">Optional Security/Encryption Utilities and Libraries</bridgehead>
[577eb27]283 <para role="optional">
284 <xref linkend="cyrus-sasl"/>,
285 <xref linkend="mitkrb"/>,
[17aa21c]286 <ulink url="https://mcrypt.sourceforge.net/">libmcrypt</ulink>, and
287 <ulink url="https://mhash.sourceforge.net/">mhash</ulink>
[577eb27]288 </para>
[db81e4cb]289
[577eb27]290 <para condition="html" role="usernotes">
[42ddc30]291 Editor Notes: <ulink url="&blfs-wiki;/php"/>
[577eb27]292 </para>
[1039de3]293
[db81e4cb]294 </sect2>
295
296 <sect2 role="installation">
297 <title>Installation of PHP</title>
298
[577eb27]299 <para>
300 You can use <application>PHP</application> for server-side
301 scripting, command-line scripting or client-side GUI applications. This
302 book provides instructions for setting up <application>PHP</application>
303 for server-side scripting as it is the most common form.
304 </para>
[db81e4cb]305
[b84326b7]306 <note>
[577eb27]307 <para>
308 <application>PHP</application> has many more
309 <command>configure</command> options that will enable support for
310 various things. You can use <command>./configure --help</command> to
311 see a full list of the available options. Also, use of the
[80106051]312 <ulink url="https://www.php.net/">PHP web site</ulink>
[577eb27]313 is highly recommended, as their online docs are very good. An example
314 of a <command>configure</command> command that utilizes many of the
315 most common dependencies can be found at <ulink
[a29486e4]316 url="&sources-anduin-http;/files/php_configure.txt"/>.
[e797436]317 </para>
[3f87e4a]318
[577eb27]319 <para>
320 If, for whatever reason, you don't have <xref linkend="libxml2"/>
321 installed, you need to add <option>--disable-libxml</option> to the
322 <command>configure</command> command in the instructions below. Note
323 that this will prevent the <command>pear</command> command from being
324 built.
325 </para>
[b84326b7]326 </note>
[b8efb1fb]327
[577eb27]328 <para>
329 Install <application>PHP</application> by running the following commands:
330 </para>
[db81e4cb]331
[0098ace6]332<screen revision="sysv"><userinput>./configure --prefix=/usr \
[75033b6]333 --sysconfdir=/etc \
[5178bbf6]334 --localstatedir=/var \
335 --datadir=/usr/share/php \
[81b5be3]336 --mandir=/usr/share/man \
[c0764bc]337 --without-pear \
[5178bbf6]338 --enable-fpm \
339 --with-fpm-user=apache \
340 --with-fpm-group=apache \
[4a93a3c]341 --with-config-file-path=/etc \
[75033b6]342 --with-zlib \
343 --enable-bcmath \
344 --with-bz2 \
345 --enable-calendar \
346 --enable-dba=shared \
347 --with-gdbm \
348 --with-gmp \
349 --enable-ftp \
350 --with-gettext \
351 --enable-mbstring \
[1f6b261]352 --disable-mbregex \
[75033b6]353 --with-readline &amp;&amp;
[db81e4cb]354make</userinput></screen>
355
[0098ace6]356<screen revision="systemd"><userinput>./configure --prefix=/usr \
357 --sysconfdir=/etc \
358 --localstatedir=/var \
359 --datadir=/usr/share/php \
360 --mandir=/usr/share/man \
361 --enable-fpm \
[c0764bc]362 --without-pear \
[0098ace6]363 --with-fpm-user=apache \
364 --with-fpm-group=apache \
365 --with-fpm-systemd \
366 --with-config-file-path=/etc \
367 --with-zlib \
368 --enable-bcmath \
369 --with-bz2 \
370 --enable-calendar \
371 --enable-dba=shared \
372 --with-gdbm \
373 --with-gmp \
374 --enable-ftp \
375 --with-gettext \
376 --enable-mbstring \
[1f6b261]377 --disable-mbregex \
[0098ace6]378 --with-readline &amp;&amp;
379make</userinput></screen>
[577eb27]380 <para>
[1f6b261]381 To test the results, issue: <command>make test</command>. Several
[f30c0dc]382 tests (out of over 18000) may fail, in which case you are asked
[8558044]383 whether you want to send the report to the PHP developers. If you
384 want to automate the test, you may prefix the command with
[1f6b261]385 <command>yes "n" | </command>.
[577eb27]386 </para>
[d6f7e6cb]387
[577eb27]388 <para>
389 Now, as the <systemitem class="username">root</systemitem> user:
390 </para>
[db81e4cb]391
[81b5be3]392<!-- dev note: make INSTALL_ROOT=<DESTDIR> install -->
393
[595e58e]394<screen role="root"><userinput>make install &amp;&amp;
395install -v -m644 php.ini-production /etc/php.ini &amp;&amp;
[d6f7e6cb]396
[ba1a38b]397install -v -m755 -d /usr/share/doc/php-&php-version; &amp;&amp;
[a4fe6a26]398install -v -m644 CODING_STANDARDS* EXTENSIONS NEWS README* UPGRADING* \
399 /usr/share/doc/php-&php-version;</userinput></screen>
[db81e4cb]400
[6ca1b179]401 <para>
402 The default configuration files for the fastCGI process manager are
[0639bb6]403 installed only if they do not already exist on the system. If this is
[6ca1b179]404 the first installation, they should be renamed, as the
405 <systemitem class='username'>root</systemitem> user:
406 </para>
407
408<screen role="root"><userinput>if [ -f /etc/php-fpm.conf.default ]; then
409 mv -v /etc/php-fpm.conf{.default,} &amp;&amp;
410 mv -v /etc/php-fpm.d/www.conf{.default,}
411fi</userinput></screen>
412
[577eb27]413 <para>
414 The pre-built HTML documentation is packaged in two forms: a tarball
415 containing many individual files, useful for quick loading into your
416 browser, and one large individual file, which is useful for using the
417 search utility of your browser. If you downloaded either, or both, of the
418 documentation files, issue the following commands as the
419 <systemitem class='username'>root</systemitem> user to install them (note
420 these instructions assume English docs, modify the tarball names below if
421 necessary).
422 </para>
[db81e4cb]423
[577eb27]424 <para>
425 For the <quote>Single HTML</quote> file:
426 </para>
[b84326b7]427
428<screen role="root"><userinput>install -v -m644 ../php_manual_en.html.gz \
429 /usr/share/doc/php-&php-version; &amp;&amp;
430gunzip -v /usr/share/doc/php-&php-version;/php_manual_en.html.gz</userinput></screen>
431
[577eb27]432 <para>
433 For the <quote>Many HTML files</quote> tarball:
434 </para>
[b84326b7]435
[0fb9d5f]436<screen role="root"><userinput>tar -xvf ../php_manual_en.tar.gz \
[a5db8d2]437 -C /usr/share/doc/php-&php-version; --no-same-owner</userinput></screen>
[db81e4cb]438
[c0764bc]439 <para>
440 The bundled pear is not installed because of a bug which might
441 pollute the filesystem with several hidden files and directories.
[1e5323fd]442 If pear is needed, execute the following commands to install it:
[c0764bc]443 </para>
444
[80106051]445<screen role="nodump"><userinput>wget https://pear.php.net/go-pear.phar
[c0764bc]446php ./go-pear.phar</userinput></screen>
[8558044]447
[db81e4cb]448 </sect2>
[b84326b7]449
[934c9b26]450 <sect2 role="commands">
[577eb27]451 <title>Command Explanations</title>
[cfc1f98]452
[577eb27]453 <para>
[f1d7196]454 <parameter>--datadir=/usr/share/php</parameter>: This works
[577eb27]455 around a bug in the build machinery, which installs some data to a
456 wrong location.
457 </para>
[5178bbf6]458
[577eb27]459 <para>
460 <parameter>--enable-fpm</parameter>: This parameter allows
461 building the fastCGI Process Manager.
462 </para>
[934c9b26]463
[0098ace6]464 <para revision="systemd">
465 <parameter>--with-fpm-systemd</parameter>: This parameter allows
466 the FastCGI Process Manager to integrate with systemd.
467 </para>
468
[c0764bc]469 <para>
470 <parameter>--without-pear</parameter>: This switch disables
471 installation of bundled pear software.
472 </para>
473
[577eb27]474 <para>
475 <parameter>--with-config-file-path=/etc</parameter>: This parameter
476 makes <application>PHP</application> look for the
477 <filename>php.ini</filename> configuration file in
478 <filename class='directory'>/etc</filename>.
479 </para>
[934c9b26]480
[577eb27]481 <para>
482 <parameter>--with-zlib</parameter>: This parameter adds
483 support for <application>Zlib</application> compression.
484 </para>
[934c9b26]485
[577eb27]486 <para>
487 <parameter>--enable-bcmath</parameter>: Enables
488 <command>bc</command> style precision math functions.
489 </para>
[bccbdaea]490
[577eb27]491 <para>
492 <parameter>--with-bz2</parameter>: Adds support for
493 <application>Bzip2</application> compression functions.
494 </para>
[934c9b26]495
[577eb27]496 <para>
497 <parameter>--enable-calendar</parameter>: This parameter
498 provides support for calendar conversion.
499 </para>
[934c9b26]500
[577eb27]501 <para>
502 <parameter>--enable-dba=shared</parameter>: This parameter enables
503 support for database (dbm-style) abstraction layer functions.
504 </para>
[934c9b26]505
[577eb27]506 <para>
507 <parameter>--enable-ftp</parameter>: This parameter
508 enables FTP functions.
509 </para>
[934c9b26]510
[577eb27]511 <para>
512 <parameter>--with-gettext</parameter>: Enables functions
513 that use <application>Gettext</application> text translation.
514 </para>
[934c9b26]515
[577eb27]516 <para>
517 <parameter>--enable-mbstring</parameter>: This parameter
518 enables multibyte string support.
519 </para>
[934c9b26]520
[aa41434]521<!--
[1f6b261]522 <para>
[aa41434]523 <parameter>- -disable-mbstring</parameter>: This parameter
[1f6b261]524 disables multibyte string regular expression support. It
[8558044]525 requires the external
526 <ulink url="https://github.com/kkos/oniguruma">oniguruma</ulink>
[1f6b261]527 library.
528 </para>
[aa41434]529-->
[577eb27]530 <para>
531 <parameter>--with-readline</parameter>: This parameter
532 enables command line <application>Readline</application> support.
533 </para>
[934c9b26]534
[577eb27]535 <para>
536 <option>--disable-libxml</option>: This option
537 allows building PHP without <application>libxml2</application>
538 installed.
539 </para>
[934c9b26]540
[577eb27]541 <para>
542 <option>--with-apxs2</option>: Instead of building the fastCGI process
543 manager, it is possible to build an <application>apache</application>
544 module. This has some performance penalty for heavy loaded servers,
545 but may be easier to set up. This switch is incompatible with the
546 <parameter>--enable-fpm</parameter> and
547 <parameter>--with-fpm-...</parameter> switches.
548 </para>
[5178bbf6]549
[39ffbd0]550 <para>
[b8efb1fb]551 <option>--with-mysqli=shared</option>: This option includes MySQLi
552 support.
[39ffbd0]553 </para>
554
555 <para>
556 <option>--with-mysql-sock=/run/mysqld/mysqld.sock</option>: Location of
557 the MySQL unix socket pointer.
558 </para>
559
560 <para>
[b8efb1fb]561 <option>--with-pdo-mysql=shared</option>: This option includes PDO:
562 MySQL support.
563 </para>
564
565 <para>
566 <option>--with-tidy=shared</option>: This option includes tidy library
[39ffbd0]567 support.
568 </para>
569
[934c9b26]570 </sect2>
[bccbdaea]571
[db81e4cb]572 <sect2 role="configuration">
573 <title>Configuring PHP</title>
574
575 <sect3 id="php-config">
576 <title>Config Files</title>
577
[577eb27]578 <para>
579 <filename>/etc/php.ini</filename>,
[8f64429]580 <filename>/etc/pear.conf</filename>,
581 <filename>/etc/php-fpm.conf</filename>, and
582 <filename>/etc/php-fpm.d/www.conf</filename>
[577eb27]583 </para>
[db81e4cb]584
585 <indexterm zone="php php-config">
586 <primary sortas="e-etc-php.ini">/etc/php.ini</primary>
587 </indexterm>
588
589 <indexterm zone="php php-config">
590 <primary sortas="e-etc-pear.conf">/etc/pear.conf</primary>
591 </indexterm>
592
[8f64429]593 <indexterm zone="php php-config">
594 <primary sortas="e-etc-php-fpm.d-www.conf">
595 /etc/php-fpm.d/www.conf</primary>
596 </indexterm>
597
[5178bbf6]598 <indexterm zone="php php-config">
599 <primary sortas="e-etc-php-fpm.conf">/etc/php-fpm.conf</primary>
600 </indexterm>
601
[db81e4cb]602 </sect3>
603
604 <sect3>
605 <title>Configuration Information</title>
606
[577eb27]607 <para>
608 The file used as the default <filename>/etc/php.ini</filename>
609 configuration file is recommended by the <application>PHP</application>
610 development team. This file modifies the default behavior of
611 <application>PHP</application>. If no <filename>/etc/php.ini</filename>
612 is used, all configuration settings fall to the defaults. You should
613 review the comments in this file and ensure the changes are acceptable
614 in your particular environment.
615 </para>
[e797436]616
[355b8a9]617 <para>
618 The fastCGI process manager uses the configuration file
619 <filename>/etc/php-fpm.conf</filename>. The default file shipped with
620 PHP includes all the <filename>/etc/php-fpm.d/*.conf</filename> in turn.
621 There is a shipped <filename>/etc/php-fpm.d/www.conf</filename> file,
622 that contains the parameters related to the interaction with the Apache
623 Web server.
624 </para>
625
[577eb27]626 <para>
627 You may have noticed the following from the output of the
628 <command>make install</command> command:
629 </para>
[b84326b7]630
[7c1d541]631<screen><computeroutput>You may want to add: /usr/lib/php to your php.ini include_path</computeroutput></screen>
[b84326b7]632
[577eb27]633 <para>
634 If desired, add the entry using the following command as the
635 <systemitem class="username">root</systemitem> user:
636 </para>
[b84326b7]637
[7c1d541]638<screen role="root"><userinput>sed -i 's@php/includes"@&amp;\ninclude_path = ".:/usr/lib/php"@' \
[b84326b7]639 /etc/php.ini</userinput></screen>
640
[577eb27]641 <para>
642 To enable fastCGI support in the <application>Apache</application>
643 web server, two LoadModule directives must be added to the
644 <filename>httpd.conf</filename> file. They are commented out, so just
645 issue the following command as
646 <systemitem class="username">root</systemitem> user:
647 </para>
[db81e4cb]648
[5178bbf6]649<screen role="root"><userinput>sed -i -e '/proxy_module/s/^#//' \
[7f8868f]650 -e '/proxy_fcgi_module/s/^#//' \
[5178bbf6]651 /etc/httpd/httpd.conf</userinput></screen>
[db81e4cb]652
[577eb27]653 <para>
654 Those modules accept various <command>ProxyPass</command>
655 directives. One possibility is (as the
656 <systemitem class="username">root</systemitem> user):
657 </para>
[5178bbf6]658
659<screen role="root"><userinput>echo \
[7f8868f]660'ProxyPassMatch ^/(.*\.php)$ fcgi://127.0.0.1:9000/srv/www/$1' >> \
[5178bbf6]661/etc/httpd/httpd.conf</userinput></screen>
662
[577eb27]663 <para>
664 Additionally, it may be useful to add an entry for
665 <filename>index.php</filename> to the DirectoryIndex directive of the
[b59e5eb3]666 <filename>httpd.conf</filename> file. Lastly, adding a line to set up the
[577eb27]667 <filename class='extension'>.phps</filename> extension to show
668 highlighted <application>PHP</application> source may be
669 desirable:
670 </para>
[e797436]671
672<screen><literal>AddType application/x-httpd-php-source .phps</literal></screen>
[db81e4cb]673
[577eb27]674 <para>
675 You'll need to restart the <application>Apache</application> web server
676 after making any modifications to the <filename>httpd.conf</filename>
677 file.
678 </para>
[db81e4cb]679
680 </sect3>
681
[5178bbf6]682 <sect3 id="php-init">
[0098ace6]683 <title><phrase revision="sysv">Boot Script</phrase>
684 <phrase revision="systemd">Systemd Unit</phrase></title>
[5178bbf6]685
[3c7bd00]686 <para revision="sysv">
[5178bbf6]687 To automatically start the <command>php-fpm</command> daemon when the
688 system is rebooted, install the
689 <filename>/etc/rc.d/init.d/php</filename> bootscript from the
690 <xref linkend="bootscripts"/> package as the
691 <systemitem class="username">root</systemitem> user:
692 </para>
693
[3c7bd00]694 <para revision="systemd">
[0098ace6]695 To start the <command>php-fpm</command> daemon at boot,
696 install the systemd unit from the <xref linkend="systemd-units"/>
697 package by running the following command as the
[3c7bd00]698 <systemitem class="username">root</systemitem> user:
699 </para>
700
701
[5178bbf6]702 <indexterm zone="php php-init">
703 <primary sortas="f-php">php</primary>
704 </indexterm>
705
[3c7bd00]706<screen role="root" revision="sysv"><userinput>make install-php</userinput></screen>
707
708<screen role="root" revision="systemd"><userinput>make install-php-fpm</userinput></screen>
709
[5178bbf6]710 </sect3>
711
[db81e4cb]712 </sect2>
713
714 <sect2 role="content">
715 <title>Contents</title>
716
717 <segmentedlist>
718 <segtitle>Installed Programs</segtitle>
[1c345ed]719 <segtitle>Installed Libraries</segtitle>
[db81e4cb]720 <segtitle>Installed Directories</segtitle>
721
722 <seglistitem>
[cfc1f98]723 <seg><!-- not built anymore pear, peardev, pecl,-->
724 phar (symlink), phar.phar, php,
[8f64429]725 php-cgi, php-config, php-fpm, phpdbg, and phpize</seg>
[17f72f6]726
[1c7c64d]727 <seg>dba.so and opcache.so in
[f7aa1d4]728 /usr/lib/php/extensions/no-debug-non-zts-20230831</seg>
[17f72f6]729
[cfc1f98]730 <seg>/etc/php-fpm.d, /usr/{include,lib,share}/php, and
[ba1a38b]731 /usr/share/doc/php-&php-version;</seg>
[db81e4cb]732 </seglistitem>
733 </segmentedlist>
734
735 <variablelist>
736 <bridgehead renderas="sect3">Short Descriptions</bridgehead>
737 <?dbfo list-presentation="list"?>
738 <?dbhtml list-presentation="table"?>
739
740 <varlistentry id="php-prog">
741 <term><command>php</command></term>
742 <listitem>
[577eb27]743 <para>
744 is a command line interface that enables you to parse and
[4c24eb0a]745 execute PHP code
[577eb27]746 </para>
[db81e4cb]747 <indexterm zone="php php-prog">
748 <primary sortas="b-php">php</primary>
749 </indexterm>
750 </listitem>
751 </varlistentry>
752
753 <varlistentry id="pear">
754 <term><command>pear</command></term>
755 <listitem>
[577eb27]756 <para>
757 is the PHP Extension and Application Repository (PEAR) package
[4c24eb0a]758 manager. This isn't installed by default
[577eb27]759 </para>
[db81e4cb]760 <indexterm zone="php pear">
761 <primary sortas="b-pear">pear</primary>
762 </indexterm>
763 </listitem>
764 </varlistentry>
765
[5178bbf6]766 <varlistentry id="php-fpm">
767 <term><command>php-fpm</command></term>
768 <listitem>
[577eb27]769 <para>
[4c24eb0a]770 is the fastCGI process manager for PHP
[577eb27]771 </para>
[5178bbf6]772 <indexterm zone="php php-fpm">
773 <primary sortas="b-php-fpm">php-fpm</primary>
774 </indexterm>
775 </listitem>
776 </varlistentry>
777
[8f64429]778 <varlistentry id="phpdbg">
779 <term><command>phpdbg</command></term>
780 <listitem>
781 <para>
[4c24eb0a]782 is the interactive PHP debugger
[8f64429]783 </para>
784 <indexterm zone="php phpdbg">
785 <primary sortas="b-phpdbg">phpdbg</primary>
786 </indexterm>
787 </listitem>
788 </varlistentry>
789
[db81e4cb]790 </variablelist>
791
792 </sect2>
[f45b1953]793
794</sect1>
Note: See TracBrowser for help on using the repository browser.