php 설치전 애들

카테고리 없음 2008. 6. 19. 19:05 posted by 이한비
(1) zlib 설치 : zlib은 압축과 관련된 라이브러리 입니다.
zlib 공식사이트 : http://www.zlib.net
zlib 파일 폴더로 이동 후 tmp 폴더에 내려받는다.
# cd /etc
# get zlib-1.2.3.tar.bz2 /tmp/zlib-1.2.3.tar.bz2

tmp 폴더로 이동후 압축풀기
# tar xvf zlib-1.2.3.tar.bz2
# cd zlib-1.2.3

# ./configure -s
# make

# ./configure
# make test
# make install

# ls -al libz.so*



# cp libz.so* /usr/local/lib

기존 zlib 삭제

# cd /usr/local/lib
# rm -rf libz.so
# rm -rf libz.so.1

새로운 zlib 생성
# ln -s libz.so.1.2.3 libz.so
# ln -s libz.so.1.2.3 libz.so.1

설정정보 추가
# vi /etc/ld.so.conf

/usr/local/lib (삽입)

# ldconfig

(2) libpng 설치 : png 포맷을 다루기 위한 라이브러리입니다.
[root@localhost local]# wget http://ftp.superuser.co.kr/pub/etc/libpng-1.2.5.tar.gz
[root@localhost local]# tar xvfz libpng-1.2.5.tar.gz
[root@localhost local]# cd libpng-1.2.5
[root@localhost libpng-1.2.5]# cp scripts/makefile.linux makefile
[root@localhost libpng-1.2.5]# make test && make install
[root@localhost libpng-1.2.5]# cd ..
[root@localhost local]# rm -rf libpng-1.2.5*

(3) freetype 2 설치 : 글짜를 그릴 때 쓰는 라이브러리 입니다.
[root@localhost local]# wget http://ftp.superuser.co.kr/pub/etc/freetype-2.1.9.tar.gz
[root@localhost local]# tar xvfz freetype-2.1.9.tar.gz    
[root@localhost local]# cd freetype-2.1.9
[root@localhost freetype-2.1.9]# ./configure && make && make install
[root@localhost freetype-2.1.9]# cd ..
[root@localhost local]# rm -rf freetype-2.1.9*

(4) libjpeg 설치 : jpg 포맷을 다루는 라이브러리 입니다.
[root@localhost local]# wget http://ftp.superuser.co.kr/pub/etc/jpegsrc.v6b.tar.gz
[root@localhost local]# tar xvfz jpegsrc.v6b.tar.gz
[root@localhost local]# cd jpeg-6b
[root@localhost jpeg-6b]# ./configure --enable-shared --enable-static
[root@localhost jpeg-6b]# make && make test
[root@localhost jpeg-6b]# mkdir /usr/local/man/man1
[root@localhost jpeg-6b]# make install
[root@localhost jpeg-6b]# cd ..
[root@localhost local]# rm -rf jpeg*
위 설치법에서 특별한 것은 중간에 /usr/local/man/man1이라는 디렉토리를 생성합니다. 이유는 make install 하면 /usr/local/man/man1 디렉토리가 없다고 멘 페이지가 설치가 되지 않는다는 에러가 납니다.

(5) gd 설치 : 그래픽 라이브러리 입니다.
[root@localhost local]# wget http://ftp.superuser.co.kr/pub/etc/gd-2.0.28.tar.gz
[root@localhost local]# tar xvfz gd-2.0.28.tar.gz
[root@localhost local]# cd gd-2.0.28
[root@localhost gd-2.0.28]# ./configure && make && make install
[root@localhost gd-2.0.28]# cd ..
[root@localhost local]# mv gd-2.0.28 /usr/local/.

0.6 LIBXML2 설치
#tar xvfz libxml2*
#cd libxml2*
#./configure
#make
#make install
#cd ..
-----------------------------------------------
0.7 LIBICONV 설치
#tar xvfz libiconv*
#cd libiconv*
#./configure --prefix=/usr/local
#make
#make install
#ln -s /usr/local/lib/libiconv.so.2 /usr/lib/libiconv.so.2 (php 멍청한게.. /usr/lib 에서 찾는다.. /usr/local/lib 라고 해도 말이다..)
#cd ..