Linux2010. 10. 28. 18:21


yum install libmcrypt \
libmcrypt-devel




#cd /usr/local/src/apm
tar zxvf php-5.3.3.tar.gz
cd php-5.5.5
./configure \
--with-apxs2=/usr/local/apache2/bin/apxs \
--with-mysql=/usr/local/mysql \
--disable-debug \
--disable-posix \
--disable-rpath \
--disable-dmalloc \
--with-gd \
--with-jpeg-dir \
--with-png-dir \
--with-freetype-dir  \
--with-zlib \
--with-iconv \
--with-xmlrpc \
--with-config-file-path=/usr/local/apache2/conf \
--with-mcrypt \
--with-curl \
--with-mhash \
--with-openssl \
--with-mcrypt \
--with-kerberos \
--with-gmp \
--enable-bcmath \
--enable-mbstring \
--enable-ftp \
--enable-sockets \
--enable-calendar \
--enable-safe-mode \
--enable-magic-quotes \
--enable-gd-native-ttf \
--enable-sysvsem \
--enable-sysvshm \
--enable-wddx

# make
# make install
# cp php.ini-production /usr/local/apache/conf/php.ini

# vi /usr/local/apache/conf/httpd.conf
// ServerName 변경
ServerName localhost:80

// DirectoryIndex 에 추가 
DirectoryIndex index.html index.htm index.php

// AddType 추가
AddType application/x-httpd-php .php .phtml .php3 .html .htm 
AddType application/x-httpd-php-source .phps 

// 권한 변경
<Directory />
Optionis FollowSymLinks
AllowOverride None
Order deny,allow
Deny from all 을 Allow from all 으로 변경
</Directory>




# vi /usr/local/apache/conf/mime.types
// 끝에 mime type 추가
application/x-httpd-php  php ph inc
application/x-httpd-php-source phps





Posted by requireme