Differences
This shows you the differences between two versions of the page.
Next revision | Previous revision | ||
docs:programming:php:php_cgi [2006/10/08 03:53] – (old revision restored) 127.0.0.1 | docs:programming:php:php_cgi [2008/08/03 00:25] (current) – external edit 127.0.0.1 | ||
---|---|---|---|
Line 6: | Line 6: | ||
Rather than open up the unstable branch for all programs, I opted to install everything else from stable binaries and build php from source. | Rather than open up the unstable branch for all programs, I opted to install everything else from stable binaries and build php from source. | ||
+ | |||
+ | ===== Apple' | ||
+ | **It should be noted that the php binary included with Mac OS X is only a cli build (command line interface). | ||
+ | |||
+ | **The frustrating error that may show up if you try to use the wrong binary is an Internal Server Error from apache. | ||
+ | |||
+ | |||
+ | |||
+ | |||
+ | |||
+ | |||
+ | |||
===== Setup ===== | ===== Setup ===== | ||
- Install Fink as usual | - Install Fink as usual | ||
- Install Apache2 binary | - Install Apache2 binary | ||
- | - FIXME finish list of packages | + | - binaries, development files, and shared libraries from the following may need to be installed |
* gd2 | * gd2 | ||
* libjepg | * libjepg | ||
- | * libpng | + | * libpng/libpng3 |
* freetype2 | * freetype2 | ||
- | * mcrypt | + | * libmcrypt |
+ | * openldap (if you want ldap) | ||
+ | * gettext (req'd by phpldapadmin) | ||
- download php source from http:// | - download php source from http:// | ||
- extract the php archive, and build using the following commands:< | - extract the php archive, and build using the following commands:< | ||
- | ./configure --prefix=/ | + | ./configure --prefix=/ |
make | make | ||
Line 27: | Line 41: | ||
Action php4-script / | Action php4-script / | ||
AddHandler php4-script .php | AddHandler php4-script .php | ||
+ | </ | ||
+ | - modify the directory index:< | ||
+ | < | ||
+ | DirectoryIndex index.html index.htm index.php | ||
+ | </ | ||
</ | </ | ||
- restart apache or reboot and test a php script with the .php extension | - restart apache or reboot and test a php script with the .php extension | ||
Line 32: | Line 51: | ||
* NOTE: it is possible that with this php install there are some needed features that were not enabled during the build process; this is the config command that fink was going to use for the unstable branch< | * NOTE: it is possible that with this php install there are some needed features that were not enabled during the build process; this is the config command that fink was going to use for the unstable branch< | ||
configure --prefix=/ | configure --prefix=/ | ||
+ | </ | ||
+ | |||
+ | ===== Setup (using custom MySQL) ===== | ||
+ | * same steps as above, with the following modification to the configure command:< | ||
+ | --with-mysql=/ | ||
+ | |||
+ | full command would then be: | ||
+ | |||
+ | ./configure --prefix=/ | ||
</ | </ |