aix 4.3.3 ¿¡¼­ apm ¼ÂÆÃÇϱâ (¿À·ùÇØ°á)
ÀÛ¼ºÀÚ °ü¸®ÀÚ ÀÛ¼º½Ã°£ 2004-06-28 00:07:39
 

1. ÃֽŠ¾ÈÁ¤¹öÀü

http://www.php.net  PHP-4.3.2 (10 August 2003)


2. »çÀü¿¡ ¿ä±¸µÇ´Â »çÇ×

Apache´Â ¹Ì¸® DSO(Dynamic Shared Object)¸ðµå·Î ÄÄÆÄÀÏ¹× ÀνºÅçÀÌ µÇ¾î ÀÖ¾î¾ß ÇÑ´Ù. È®ÀÎ ¹æ¹ýÀº ´ÙÀ½°ú °°´Ù. ±×¸®°í PerlÀÌ ÀνºÅçµÇ¾î ÀÖ¾î¾ß ÇÑ´Ù.

# cd /usr/local/apache/bin
# ./httpd -l
  http_core.c
  mod_so.c

À§ 2ÁÙÀÌ Æ÷ÇԵǾî ÀÖÀ¸¸é µÈ´Ù. Apache¸¦ DSO·Î ÄÄÆÄÀÏÇÏ´Â ¹æ¹ýÀº °Ô½ÃÆÇÀ» Âü°íÇϱ⠹ٶõ´Ù.



3. Php ´Ù¿î·Îµå (/usr/local µð·ºÅ丮¿¡)
# cd /usr/local
 


4. ¾ÐÃàÇ®±â ¹× ÄÄÆÄÀÏ
# gzip -dc php-4.3.2.tar.gz | tar xvf -
(Linux¿¡¼­´Â # tar zxvf php-4.3.2.tar.gzÀ¸·Î Çصµ µÈ´Ù.)

# cd /usr/local/php-4.3.2
# ./configure --prefix=/usr/local/php --with-apxs=/usr/local/apache/bin/apxs --with-config-file-path=/usr/local/php

--with-config-file-path Àº php.ini°¡ µé¾î°¥ Àå¼Ò

* checking whether gcc and cc understand -c and -o together... ¿¡¼­ ¸ØÃá°æ¿ì´Â AIX¿¡¼­ # cc ¸¦ Çغ»´Ù. À̶§ IBM C ÄÄÆÄÀÏ·¯°¡ ³ª¿À¸é, /usr/local/bin/gcc¸¦ cc·Î ½Éº¼¸¯¸µÅ©¸¦ ÇÏ´Â Æí¹ýÀ» »ç¿ëÇÑ´Ù. ±×¸®°í ´Ù½Ã configure ¸¦ ¼öÇàÇÑ´Ù.

* ¸¸¾à¿¡ mysql(¹Ì¸® ¼³Ä¡µÇ¾îÀÖ¾î¾ß ÇÔ)À» ¿¬µ¿Çؼ­ ÄÄÆÄÀÏÇÏ°íÀÚ ÇÑ´Ù¸é,
# ./configure --prefix=/usr/local/php --with-apxs=/usr/local/apache/bin/apxs --with-config-file-path=/usr/local/php --with-mysql=/usr/local/mysql


5. ÄÄÆÄÀÏ ¹× ÀνºÅç
# make
# make install


* AIX 4.3.3¿¡¼­ ¿¡·¯¹ß»ý (Linux 7.3¿¡¼­´Â ¿¡·¯¹ß»ýÇÏÁö ¾ÊÀ½)
Making install in .
      /usr/local/apache/bin/apxs -i -a -n php4 libs/libphp4.so
[activating module `php4' in /usr/local/apache/conf/httpd.conf]
cp libs/libphp4.so /usr/local/apache/libexec/libphp4.so
cp: libs/libphp4.so: °æ·Î À̸§¿¡ ÀÖ´Â ÆÄÀÏÀ̳ª µð·ºÅ丮°¡ Á¸ÀçÇÏÁö ¾Ê½À´Ï´Ù.
apxs:Break: Command failed with rc=1
make: 1254-004 ÃÖÁ¾ ¸í·É¿¡¼­ÀÇ ¿À·ù ÄÚµå´Â 1ÀÔ´Ï´Ù.


Stop.
make: 1254-004 ÃÖÁ¾ ¸í·É¿¡¼­ÀÇ ¿À·ù ÄÚµå´Â 1ÀÔ´Ï´Ù

* ÇØ°á¹æ¹ý
# cd libs
# cp ../.libs/libphp4.so.0 .
# make install

or

# cp /usr/local/php-4.3.1/.libs/libphp4.so.0 /usr/local/apache/libexec/libphp4.so


6. php.ini º¹»çÇϱâ
# cp php.ini-dist /usr/local/php/php.ini

¿©±â¿¡¼­ php.ini°¡ cpµÇ´Â °æ·Î´Â ./configure --with-config-file-path=/usr/local/php/conf¸¦ ÅëÇؼ­ Á¤ÇÒ¼ö ÀÖ´Ù.


--> php.ini´Â phpµ¿À۽à ÇÊ¿äÇÑ °¢Á¾ ¼³Á¤µéÀÌ µé¾î ÀÖ´Ù. ÇÊ¿äÇÏ´Ù¸é Á÷Á¢ ÀÌ ¼³Á¤À» º¯°æÇÒ¼ö ÀÖ´Ù.
--> ÀÌ°ÍÀ¸·Î phpÄÄÆÄÀÏÀÌ ³¡³µÀ¸¸ç, php°ü·Ã ¸ðµâÀÌ apache ¼Ò½º µð·ºÅ丮·Î ¿Å°ÜÁ³´Ù. ÀÌÁ¦ ¸¶Áö¸·À¸·Î, apache¸¦ ÄÄÆÄÀÏÇϱ⸸ ÇÏ¸é µÈ´Ù.


7. Apache's httpd.conf ÆÄÀÏ¿¡ PHP Module ¹× PHP 4 mime type Ãß°¡

#
# PHP 4.x Module
#
LoadModule php4_module libexec/libphp4.so

¸¸¾à¿¡ ClearModuleList Áö½Ã¾î°¡ ÀÖ´Ù¸é ´ÙÀ½ ¶óÀεµ Æ÷ÇÔÇÑ´Ù.

AddModule mod_php4.c

#
# PHP 4.x mime type
#
AddType application/x-httpd-php .php

or

AddType application/x-httpd-php .php .html
AddType application/x-httpd-php-source .phps


8. Å×½ºÆ®Çϱâ
´ÙÀ½ ÆÄÀÏÀ» vi·Î ÆíÁýÇؼ­ htdocs/test.php·Î ÀúÀåÇؼ­ Àо´Ù.

<?
phpinfo();
?>


OK


¸ñ·Ï | ÀÔ·Â | ¼öÁ¤ | ´äº¯ | »èÁ¦