66 lines
3.5 KiB
HTML
66 lines
3.5 KiB
HTML
<html><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"><title>Part III - Installing PHP5</title><link rel="stylesheet" type="text/css" href="manual.css"><meta name="generator" content="DocBook XSL Stylesheets V1.76.0"><link rel="home" href="index.html" title="JpGraph Manual"><link rel="up" href="apj.html" title="Appendix J. Setting up PHP5 in parallel with PHP4 in SuSE 10.1"></head><body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><div class="navheader"><table width="100%" summary="Navigation header"><tr><th colspan="3" align="center">Part III - Installing PHP5</th></tr><tr><td width="20%" align="left"> </td><th width="60%" align="center">Appendix J. Setting up PHP5 in parallel with PHP4 in SuSE 10.1</th><td width="20%" align="right"> </td></tr></table><hr></div><div class="section" title="Part III - Installing PHP5"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="id2655055"></a>Part III - Installing PHP5</h2></div></div></div>
|
||
|
||
<p>We are now ready for the last step which means compiling PHP5 as a CGI module for
|
||
Apache. This follows the same principle as the compilation for PHP4 as described above.
|
||
Again, we use a small configuration script "<code class="filename">mkphp5-cgi</code>" which is
|
||
shown below.</p>
|
||
<p>
|
||
</p><div class="hl-main"><table class="hl-table" width="100%"><tr><td class="hl-gutter" align="right" valign="top"><pre>1
|
||
2
|
||
3
|
||
4
|
||
5
|
||
6
|
||
7
|
||
8
|
||
9
|
||
10
|
||
11
|
||
12
|
||
13
|
||
14
|
||
15
|
||
16
|
||
17
|
||
18
|
||
19
|
||
20
|
||
21
|
||
22
|
||
23
|
||
24
|
||
</pre></td><td class="hl-main" valign="top"><pre><span class="hl-code">#! /bin/sh
|
||
./configure --prefix=/usr/share \
|
||
--datadir=/usr/share/php \
|
||
--libdir=/usr/share --includedir=/usr/include \
|
||
--enable-force-cgi-redirect \
|
||
--bindir=/usr/bin \
|
||
--with-config-file-path=/etc/php5/apache2 \
|
||
--enable-mbstring --enable-mbregex \
|
||
--with-mysql \
|
||
--with-gd --enable-gd-imgstrttf --enable-gd-native-ttf \
|
||
--with-zlib-dir=/usr/lib \
|
||
--with-png-dir=/usr/lib --with-jpeg-dir=/usr/lib \
|
||
--with-xpm-dir=/usr/X11R6 \
|
||
--with-tiff-dir=/usr/lib --with-ttf-dir=/usr/lib \
|
||
--with-freetype-dir=/usr/lib \
|
||
--enable-ftp \
|
||
--enable-memory-limit --enable-safe-mode \
|
||
--bindir=/usr/bin \
|
||
--enable-bcmath -enable-calendar \
|
||
--enable-ctype --with-ftp \
|
||
--enable-magic-quotes \
|
||
--enable-inline-optimization \
|
||
--with-bz2 \
|
||
--with-iconv</span></pre></td></tr></table></div><p>
|
||
</p>
|
||
<p>Notice that as we said before we have a different configuration path for PHP5 compared
|
||
with PHP4 as shown above. Also note that in order to build the CGI module we do not
|
||
configure the "apxs2" option. After successful configuration type
|
||
"<span class="command"><strong>make</strong></span>" but do not type "<span class="command"><strong>make install</strong></span>" in order
|
||
to compile PHP5. </p>
|
||
<p>After the compilation have finished copy "<code class="filename">sapi/cgi/php</code>" to
|
||
"<code class="filename">/srv/www/gamma2-cgi-bin/php</code>" since this is the place where our
|
||
virtual host expects to find the PHP5 CGI module. </p>
|
||
</div><div class="navfooter"><hr><table width="100%" summary="Navigation footer"><tr><td width="40%" align="left"> </td><td width="20%" align="center"><a accesskey="u" href="apj.html">Up</a></td><td width="40%" align="right"> </td></tr><tr><td width="40%" align="left" valign="top"> </td><td width="20%" align="center"><a accesskey="h" href="index.html">Home</a></td><td width="40%" align="right" valign="top"> </td></tr></table></div></body></html>
|