Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

Gary King

macrumors 6502
Original poster
Jun 14, 2004
495
1
I hear that the Mac has a ton of UNIX tools pre-installed, like Apache, and PHP (I know MySQL isn't, but I can install that. I installed WAMP myself.)

Is this true? Where can I find these? How do I enable them? Also, where do I go for the command prompt in Mac? I'll go to the nearest Apple Store to try these out when I get my hands on one of them over there - or if my own Mac ships here in time :)
 
Gary King said:
I hear that the Mac has a ton of UNIX tools pre-installed, like Apache, and PHP (I know MySQL isn't, but I can install that. I installed WAMP myself.)

Is this true? Where can I find these? How do I enable them? Also, where do I go for the command prompt in Mac? I'll go to the nearest Apple Store to try these out when I get my hands on one of them over there - or if my own Mac ships here in time :)

OS X Server has Apache installed; the regular version doesn't (at least I don't see it). PHP is in /usr/bin, as you'd expect in most any *nix.

Now, I'm sure you can install and build Apache yourself. For that matter there are likely pre-packaged versions out there. If you're used to building apps on x86 there may be a few curves you'll have to master, but OS X has automake/autoconf so it's pretty much the same process you're used to.

To get to the command line you just run Terminal. I prefer iTerm myself, because I like tabs.
 
apache is installed by default, just not on. if you go to sharing, and enable personal web sharing, apache starts.

To enable php, edit /etc/httpd/httpd.conf and uncomment the 2 lines

LoadModule php4_module libexec/httpd/libphp4.so
AddModule mod_php4.c

(on second thought, edit httpd.conf first, then enable apache, to be sure for the changes to take)

mysql is not installed.

Edit: Version Info. Apache/1.3.33 (Darwin) PHP/4.3.10
 
Westside guy said:
OS X Server has Apache installed; the regular version doesn't (at least I don't see it). PHP is in /usr/bin, as you'd expect in most any *nix.

Now, I'm sure you can install and build Apache yourself. For that matter there are likely pre-packaged versions out there. If you're used to building apps on x86 there may be a few curves you'll have to master, but OS X has automake/autoconf so it's pretty much the same process you're used to.

To get to the command line you just run Terminal. I prefer iTerm myself, because I like tabs.

Nope, client has Apache too. WWWroot: /Library/Webserver/Documents/

PHP must be installed manually, along with MySQL.
 
rasp said:
apache is installed by default, just not on. if you go to sharing, and enable personal web sharing, apache starts.

Oh that's weird - I had done "locate httpd" from the command line and got nothing back. But there it is - /usr/sbin/httpd (found it by looking through apachectl).
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.