PHP 4.3.0 RC3(http://www.php.net/) 이상 버전에서 설치 
(이하 버전에서는 작동안됨;4.0.4pl1 버그)

1. 모듈 복사 및 압축 해제
libmcrypt-2.5.4.tar.gz(http://mcrypt.sourceforge.net/) ==> /tmp/libmcrypt
mcrypt-2.6.3.tar.gz(http://mcrypt.sourceforge.net/)  ==> /tmp/mcrypt
mhash-0.8.17.tar.gz(http://mhash.sourceforge.net/)  ==> /tmp/mhash

2. LIB경로 환경변수 등록(/etc/profile)
LD_LIBRARY_PATH=/usr/local/lib
LD_RUN_PATH=/usr/local/lib

export LD_LIBRARY_PATH LD_RUN_PATH

3. SO경로 등록(/etc/ld.so.conf)
/usr/local/lib

4. libmcrypt 설치(/tmp/libmcrypt/): /usr/local/lib에 설치됨
$ source /etc/profile
$ ./configure --disable-posix-threads
$ make
$ make install

5. mhash 설치(/tmp/mhash/): /usr/local/lib에 설치됨
$ ./configure
$ make
$ make install

6. mcrypt 설치(/tmp/mcrypt/): /usr/local/bin에 설치됨
$ ./configure
$ make
$ make install

7. php 재구성(/usr/local/php/)
$ ./configure --enable-shmop --with-mysql --with-xml --enable-track-vars --with-mcrypt=/usr/local --with-mhash=/usr/local --with-apache=/usr/local/apache --with-zlib --with-gd --with-mod_charset --with-language=korean --with-charset=euc_kr
$ make
$ make install

8. Apache 중지 및 재구성(/usr/local/apache/)
$ ./bin/apachectl stop
$ ./configure --prefix=/usr/local/apache --enable-module=rewrite --activate-module=src/modules/php4/libphp4.a --enable-module=so --enable-rule=SHARED_CORE
$ make
$ make install
$ ./bin/apachectl start

9. php 확인
<? phpinfo(); ?>을 입력하여 웹브라우저에서 mcrypt, mhash, xml 항목이 있는지 확인한다.


'Tech: > Linux·PHP' 카테고리의 다른 글

Linux에 PHP + Apache + MySQL 설치하기2  (0) 2008.06.26
Linux VMWare 설치  (0) 2008.06.26
Linux에 PHP + Apache + MySQL 설치하기  (0) 2008.06.26
기타 유용한 정보들  (0) 2008.06.26
XMLHttp 구현하기  (0) 2008.06.26


Posted by 떼르미
,


자바스크립트를 허용해주세요!
Please Enable JavaScript![ Enable JavaScript ]