Welcome to the MacNN Forums.

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

You are here: MacNN Forums > Software - Troubleshooting and Discussion > Mac OS X > Problem in apache php installation

Problem in apache php installation
Thread Tools
Fresh-Faced Recruit
Join Date: Aug 2005
Status: Offline
Reply With Quote
Aug 20, 2005, 08:27 AM
 
Hi,

I have installed an apache binary in my Mac machine and it works fine.
Also I have installed a php binary. It automatically generates the libphp4.so file in its directory. I have copied this file to libexec directory in apache folder.

Now my problem is how to load php4_module into my apache binary?
I have added this line in httpd.conf file:

LoadModule php4_module libexec/libphp4.so

but it seems to not work saying that

Syntax error on line 205 of /Apache/Path/apache/conf/httpd.conf:
API module structure `php4_module' in file
/Apache/Path/apache/libexec/libphp4.so is garbled - perhaps this is not an Apache module DSO?

Can any one help me?
     
Professional Poster
Join Date: Apr 2001
Location: Long Beach, CA
Status: Offline
Reply With Quote
Aug 20, 2005, 12:46 PM
 
Unless you are really wanting to do it the hard way, I'd recommend looking into fink:

http://fink.sourceforge.net

ACSA 10.4/10.3, ACTC 10.3, ACHDS 10.3
     
Moderator
Join Date: May 2001
Location: Hilbert space
Status: Offline
Reply With Quote
Aug 20, 2005, 12:48 PM
 
Isn't that already supplied with Tiger? Why did you install it separately?

Anyway, moving to Unix … 
I don't suffer from insanity, I enjoy every minute of it.
     
Mac Elite
Join Date: Sep 2001
Location: Chico, CA and Carlsbad, CA.
Status: Offline
Reply With Quote
Aug 21, 2005, 04:08 PM
 
Originally Posted by srinivasan
Hi,

I have installed an apache binary in my Mac machine and it works fine.
Also I have installed a php binary. It automatically generates the libphp4.so file in its directory. I have copied this file to libexec directory in apache folder.
Take that PHP module out, there's already one installed on your computer (well, there should be). All you have to do to get Apache to use PHP is uncomment two lines in /etc/httpd/httpd.conf. Find these two lines in the config file, and remove the comments:
Code:
#LoadModule php4_module libexec/httpd/libphp4.so #AddModule mod_php4.c
And then restart Apache:
Code:
sudo apachectl graceful
"In Nomine Patris, Et Fili, Et Spiritus Sancti"

     
Professional Poster
Join Date: Apr 2001
Location: Long Beach, CA
Status: Offline
Reply With Quote
Aug 21, 2005, 09:33 PM
 
Originally Posted by OreoCookie
Isn't that already supplied with Tiger? Why did you install it separately?

Anyway, moving to Unix … 
Apple doesn't supply Apache 2 with Tiger, so if you want some of the new features, you have to custom install. I wanted subversion, so I had to install and configure Apache 2 myself--even on OS X server. Even though Apache 2 is installed in /opt, it didn't include the svn plugin, so I still had to install it myself with fink.

ACSA 10.4/10.3, ACTC 10.3, ACHDS 10.3
     
Fresh-Faced Recruit
Join Date: Aug 2005
Status: Offline
Reply With Quote
Aug 21, 2005, 11:32 PM
 
Hi ,
Thanks for ur replies.

Though apache and php are already installed in Tiger, I want separate apache and php to bundle with my product which I am develping. So that they does not affect the existing system's apache and php.

Please help how to link apache and php **BINARIES** ie how to load php4_module in my apache binary.

Thanks in advance.
     
   
Thread Tools
Forum Links
Forum Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On
Top
Privacy Policy
All times are GMT -5. The time now is 12:45 AM.
All contents of these forums © 1995-2011 MacNN. All rights reserved.
Branding + Design: www.gesamtbild.com
vBulletin v.3.8.7 © 2000-2011, Jelsoft Enterprises Ltd., Content Relevant URLs by vBSEO 3.3.2