Go Back   AppleForum > Software > Application

 
 
thread_tools
2004-04-20, 10:47 AM   #1
나비
Veteran Member
 
나비's Avatar
 
Registered: Dec 2003
My Mac: cube G4 450(cd-rw,gforce2 mx), sound stick
Posts: 557
오프라인
OS X에서 아파치 설치하고 있습니다. 문제가 생겨서 질문합니다

Untar them, and run the configure program on Apache like so.

./configure --exec-prefix=/usr \
해서 여기까지는 잘 되었습니다. 뭔가 줄줄 올라가는데 한참이나 걸리더군요.
근데 이아래부터 에러가 생깁니다
--localstatedir=/var \
를 치면
[Macintosh:~/homepage/httpd-2.0.49] cmyk0% --localstatedir=/var
tcsh: --localstatedir=/var: Command not found.
라고 뜨는 군요. 당췌 무슨 뜻인지...

요 나머지도 걱정입니다..
--mandir=/usr/share/man \
--libexecdir=/System/Library/Apache/Modules \
--iconsdir=/System/Library/Apache/Icons \
--includedir=/System/Library/Frameworks/Apache.framework/Versions/1.3/Headers \
--enable-shared=max \
--enable-module=most \
--target=apache

If you want the compiler to do some optimization., you may also want to add this line:

setenv OPTIM=-O2


Next, go to the PHP 4 source directory and configure it.

./configure --prefix=/usr \
--sysconfdir=/etc \
--localstatedir=/var \
--mandir=/usr/share/man \
--with-xml \
--with-apache=/src/apache_1.3.12
If you have any other additions (MySQL, GD, etc.), be sure to add them here. For the --with-apache string, put in the path to your apache source directory, for example /src/apache_1.3.12.

Type make and make install. This will add a directory to your Apache source directory under src/modules/php4.

Now, reconfigure Apache to build in PHP 4.

./configure --exec-prefix=/usr \
--localstatedir=/var \
--mandir=/usr/share/man \
--libexecdir=/System/Library/Apache/Modules \
--iconsdir=/System/Library/Apache/Icons \
--includedir=/System/Library/Frameworks/Apache.framework/Versions/1.3/Headers \
--enable-shared=max \
--enable-module=most \
--target=apache \
--activate-module=src/modules/php4/libphp4.a
You may get a message telling you that libmodphp4.a is out of date. If so, go to the src/modules/php4 directory inside your apache source directory and run this command: ranlib libmodphp4.a. Then go back to the root of the apache source directory and run the above configure command again. That'll bring the link table up to date. Run make and make install again.

Copy and rename the php.ini-dist file to your bin directory from your PHP 4 source directory: cp php.ini-dist /usr/local/bin/php.ini or (if your don't have a local directory) cp php.ini-dist /usr/bin/php.ini.



Compiling for MacOS X client

Those tips are graciously provided by Marc Liyanage.

The PHP module for the Apache web server included in Mac OS X. This version includes support for the MySQL and PostgreSQL databases.

NOTE: Be careful when you do this, you could screw up your Apache web server!

Do this to install:


Open a terminal window.

Type wget http://www.diax.ch/users/liyanage/so...libphp4.so.gz, wait for the download to finish.

Type gunzip libphp4.so.gz.

Type sudo apxs -i -a -n php4 libphp4.so

Now type sudo open -a TextEdit /etc/httpd/httpd.conf. TextEdit will open with the web server configuration file. Locate these two lines towards the end of the file: (Use the Find command)

#AddType application/x-httpd-php .php
#AddType application/x-httpd-php-source .phps
Remove the two hash marks (#), then save the file and quit TextEdit.

Finally, type sudo apachectl graceful to restart the web server.



PHP should now be up and running. You can test it by dropping a file into your Sites folder which is called test.php. Into that file, write this line: .

Now open up 127.0.0.1/~your_username/test.php in your web browser. You should see a status table with information about the PHP module.
  Reply With Quote
2004-04-20, 11:02 AM   #2
coolguysm
Veteran Member
 
coolguysm's Avatar
 
Registered: May 2003
My Mac: iBookG4 | iMacG4 | touch8g | nano2 | iPod1G | soundstick2
Posts: 695
오프라인
죄송하지만..
제가 이쪽을 잘 몰라서 그런데..

혹시 팬서를 사용하신다면
그 팬서에 있는 아파치 써버나
cmyk0님께서 설치하는 아파치 써버랑 틀린게 되는건가요??
__________________
all about m1n.
84designer

포트폴리오 사이트를 오픈했어요!
http://m1neat.com
놀러오세요!! ^-^
  Reply With Quote
2004-04-20, 11:09 AM   #3
나비
Veteran Member
 
나비's Avatar
 
Registered: Dec 2003
My Mac: cube G4 450(cd-rw,gforce2 mx), sound stick
Posts: 557
오프라인
글쎄요. 저도 이쪽은 잘몰라서.. ^^
제 작업환경은 팬서가 맞습니다.

팬서에 아파치서버가 기본적으로 들어가 있나요?
저같은 경우는 php를 설치하기 위해서인데요.
httpd-2.0.49와 php-4.3.6를 설치 중입니다.
  Reply With Quote
2004-04-20, 11:29 AM   #4
jjagagod
Member
 
jjagagod's Avatar
 
Registered: Jul 2002
My Mac: G4 800 / new ibook
Posts: 85
오프라인
넵 기본적으로 아파치서버가 들어가 있습니다. php역시 들어가 있었던 것으로 기억하고 있습니다. 다만 터미널에서 활성화를 시켜줘야 합니다. http설정 파일을 보면 php에 대한 설정이 모두 꺼져 있음을 볼 수 있으실 겁니다. 그리고 10.3 '서버' 버젼을 까시면 웹 서버에 대한 모든 것을 GUI로 설정해 줄 수 있습니다. 하지만 아파치 서버와 PHP가 조금 구버전 이군요.
__________________
눈을 떴을 땐 세상을 살아간다.
눈을 감았을 땐? 또 다른 세상을 갈구한다.
그것이 인생이다.
  Reply With Quote
2004-04-20, 11:59 AM   #5
나비
Veteran Member
 
나비's Avatar
 
Registered: Dec 2003
My Mac: cube G4 450(cd-rw,gforce2 mx), sound stick
Posts: 557
오프라인
그렇군요..
그런데.. 누구 좀 도와줘요.....
  Reply With Quote
2004-04-20, 12:09 PM   #6
jjagagod
Member
 
jjagagod's Avatar
 
Registered: Jul 2002
My Mac: G4 800 / new ibook
Posts: 85
오프라인
ichat 사용하시면 ichat으로 아는데 까지 도와드리겠습니다 ^^;; 별로 알지는 못하지만서도... 주소 남겨주세융. 제 ichat은 아뒤랑 똑같고, 닷 맥입니다.
__________________
눈을 떴을 땐 세상을 살아간다.
눈을 감았을 땐? 또 다른 세상을 갈구한다.
그것이 인생이다.
  Reply With Quote
2004-04-20, 12:34 PM   #7
susi
Veteran Member
 
Registered: Nov 2002
My Mac: iBook
Posts: 694
오프라인
꼭 컴파일을 해서 설치해야 하는게 아니시라면

http://www.serverlogistics.com/apache2.php
http://www.serverlogistics.com/php4.php

이런 패키지로 만들어 놓은 걸 써보시면 어떨까요?
  Reply With Quote
2004-04-20, 01:35 PM   #8
axia1g
Senior Member
 
axia1g's Avatar
 
Registered: May 2002
My Mac: Macbook Pro, Classic II, MP2000
Posts: 387
오프라인
http://www.phpmac.com/articles.php?view=163

여기에서 2번만 따라하셔도 될듯합니다
__________________
Computers are incredibly fast, accurate, and stupid; humans are incredibly slow, inaccurate and brilliant; together they are powerful beyond imagination.
- Albert Einstein
  Reply With Quote
지금 시각: 03:11 AM | Contact Us | 아카이브 | Top
SEO by vBSEO 3.0.0 RC5 All contents copyright © 2001~2008 by AppleForum and/or their respective owners.