Compiling Apache, MySQL, ModPerl Source
REFERENCE MATERIAL FOR COMPILING APACHE, MYSQL, MODPERL SOURCE CODE
-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
STEP 1:
Download Apache 2.x
http://httpd.apache.org/
shell> ./configure \
--prefix=/usr/local/apache --enable-so \
--enable-rewrite --enable-speling \
--enable-modules=all --enable-mods-shared=all
shell> make && make install
-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
STEP 2:
Download MySQL (4.x + 5.x) - You can safely skip the runtime of mysql if mysqld server is not running on the same machine. . . all you need is the source files.
http://www.mysql.com/
shell> groupadd mysql
shell> useradd -g mysql mysql
shell> gunzip <mysql> cd mysql-VERSION
shell> ./configure --prefix=/usr/local/mysql
shell> make
shell> make install
shell> cp support-files/my-medium.cnf /etc/my.cnf
shell> cd /usr/local/mysql
shell> bin/mysql_install_db --user=mysql
shell> chown -R root .
shell> chown -R mysql var
shell> chgrp -R mysql .
shell> bin/mysqld_safe --user=mysql &
You may have to link the following files to path or edit your environment variables:
ln -s /usr/local/mysql/bin/mysql_config /usr/bin/mysql_config
ln -s /usr/local/mysql/bin/mysql /usr/bin/mysql
Adding a root access account:
Where ‘alan’ is the username and ‘power’ is the password.
GRANT ALL PRIVILEGES ON *.* TO 'username'@'%' IDENTIFIED BY 'password' WITH GRANT OPTION;
-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
Step 3:
Download Any Optional items for PHP
OPTIONAL FUNCTIONS:
ASpell:
http://aspell.sourceforge.net/
Dictionary:
ftp://ftp.gnu.org/gnu/aspell/dict/en/
shell> gzip -d {filename}
shell> tar -xif {filename}
shell> ./configure
shell> make
shell> make install
--OR--
shell> yum install pspell-devel
ZLib:
http://www.zlib.net/
shell> gzip -d {filename}
shell> tar -xif {filename}
shell> ./configure
shell> make
shell> make test
shell> make install
Libjpeg:
http://www.ijg.org/
shell> gzip -d {filename}
shell> tar -xif {filename}
shell> ./configure
shell> make
shell> make check
shell> make install
Libpng:
http://www.libpng.org/pub/png/libpng.html
shell> gzip -d {filename}
shell> tar -xif {filename}
shell> ./configure {doesnt exist, will display a notification}
shell> cp scripts/makefile.system makefile {make sure you use the right one!}
shell> make
shell> make test
shell> make install
Lib XawXpm:
http://www.cactii.net/~bb/XawXpm/
shell> gzip -d {filename}
shell> tar -xif {filename}
{no other installation required for php, just needs the files}
Llib freetype 2.x:
http://www.freetype.org/
shell> gzip -d {filename}
shell> tar -xif {filename}
shell> ./configure
shell> make
shell> make install
Llib mhash
http://mhash.sourceforge.net/
shell> gzip -d {filename}
shell> tar -xif {filename}
shell> ./configure
shell> make
shell> make check
shell> make install
lib gd: (install this after the above)
http://www.boutell.com/gd/
http://www.libgd.org/Downloads
shell> gzip -d {filename}
shell> tar -xif {filename}
shell> ./configure
shell> make
shell> make check
shell> make install
EAccelerator:
http://eaccelerator.net/
cURL:
http://energy.sdsu.edu/testcenter/testhome/phpinstall.html
http://curl.haxx.se/download.html
shell> gzip -d {filename}
shell> tar -xif {filename}
shell> ./configure
shell> make && make install
-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
STEP 4:
Download PHP 5.x - Make sure you change the path and the version numbers assoicated.
http://www.php.net
shell> ./configure \
--with-pspell --with-mysql=/usr/local/mysql \
--with-mysqli=/usr/local/mysql/bin/mysql_config \
--with-mysql-sock=/tmp/mysql.sock \
--with-apxs2=/usr/local/apache/bin/apxs \
--enable-magic-quotes --enable-soap \
--enable-calendar --enable-exif \
--with-zlib --with-zlib-dir=/home/_bin/libs/zlib-1.2.3 \
--with-zip --enable-mbstring=all --with-mhash \
--with-mycrypt --enable-wddx --with-gettext \
--enable-ftp \
--with-cgi --enable-fastcgi \
--with-gd \
--with-jpeg --with-jpeg-dir=/home/_bin/libs/jpeg-6b \
--enable-gd-native-ttf --with-dom \
--with-png --with-png-dir=/home/_bin/libs/libpng-1.2.12 \
--with-xpm --with-xpm-dir=/home/_bin/libs/XawXpm \
--with-freetype --with-freetype-dir=/home/_bin/libs/freetype-2.2.10 \
--enable-memory-limit --with-curl
shell> make && make install
shell> cp php.ini-dist /usr/local/lib/php.ini
shell> vi /usr/local/apache/conf/httpd.conf
add “AddType application/x-httpd-php .php” in httpd.conf if any.
-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
STEP 5:
Download PERL_MOD 2.x:
http://perl.apache.org
shell> perl Makefile.PL MP_APXS=/usr/local/apache/bin/apxs
shell> make && make test && make install
add “LoadModule perl_module modules/mod_perl.so” in httpd.conf if any.
-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
httpd.conf NOTES:
# -- Apache Server Status
ExtendedStatus On
<Location>
SetHandler server-status
Order Deny,Allow
Deny from all
Allow from all
</Location>
# — AWSTATS CONFIGURATION
http://awstats.sourceforge.net/
Alias /awstatsclasses "/home/public_www/LIVE-WEB/_default-web/inc/awstats/classes/"
Alias /awstatscss "/home/public_www/LIVE-WEB/_default-web/inc/awstats/css/"
Alias /awstatsicons "/home/public_www/LIVE-WEB/_default-web/inc/awstats/icon/"
Alias /awstatsjs "/home/public_www/LIVE-WEB/_default-web/inc/awstats/js/"
Alias /awstats/ "/home/public_www/LIVE-WEB/cgi-bin/"
<Directory>
Options All
AllowOverride None
Order allow,deny
Allow from all
</Directory>
About this entry
You’re currently reading “Compiling Apache, MySQL, ModPerl Source,” an entry on Taehoon’s Blog
- Published:
- 03.04.07 / 3am
- Category:
- Transfered
No comments
Jump to comment form | comments rss [?] | trackback uri [?]