PHP-GTK
Saturday, November 01, 2014 
download | documentation | applications | faq | changelog | resources 


search for in the  


previousInstallation on Mac OS X
Hello World (basic)next

Last updated: Sun, 12 May 2013
view this page in English

Written by Jonathan Richter

In an attempt to get PHP-GTK2 to work on Mac OS X 10.4, I found very little information and support on that subject. After a lot of failures and errors I got it to work.

Below I'll write every step I took. I am not very comfortable with Terminal and half of the time I have no clue what I am doing. So you can use this information but totally on your own risk. I just worked for me. I hope it will help anybody else too.

Resources I found helpful:

Get the newest Xcode (also called: Developer Tools) from Apple. You really need this. Go to connect.apple.com. Sign in or sign up (for free). Go to Downloads.

On the right in the Downloads Box, click Developer Tools and download the newest Xcode. In my case version 2.4.1, 923 MB big. After downloading, use the installer and follow the instructions.

I started with using Fink, but halfway it failed by not having a package that was needed (GTK 2.6 or higher). I started all over using Macports.

Go to macosforge/InstallingMacPorts.

You already did part of the first step by downloading Xcode. I followed all instructions on that page and it worked fine.

The newest version didn't have a normal Apple installer. So I downloaded this: DarwinPorts-1.3.1-10.4.dmg

Install Macports by double-clicking the installer in the disk image.

I already had a standard OS X PHP 4.4.4 installation and a PHP5 installation from Entropy.ch, but it didn't work out. I deleted my PHP5 installation from Entropy.

If you want to run Apache 1 or 2 with PHP4 or 5, Entropy is absolutely the best place to get it.

In Terminal, type: cd / and sudo port install php5

Take a coffee, this takes a while... about 2 hours on my machine. (Macports installs everything in a folder called /opt. I put the "cd /" to place that folder in the root.)

On the other tutorial, you see a --disable-libglade as a parameter for installing PHP-GTK. I don't know why they wrote that. Be very sure that you really don't want Glade. Read about it here: glade.gnome.org.

Check out the screenshots too. I installed without Glade but after a day I did it all over to get Glade working too. If you want to continue without Glade, skip the next step.

Leave X11 open to be on the safe side. phpize and php-config should be both in /opt/local/bin/. Check that before you run this. In Terminal, type:

sudo cvs -d :pserver:cvsread@cvs.php.net:/repository co php-gtk
cd php-gtk
sudo ./buildconf --with-phpize=/opt/local/bin/phpize
sudo ./configure --with-php-config=/opt/local/bin/php-config
sudo make
sudo make install
    

After it is done, you will see in the output of Terminal a remark about extensions being installed with a path that probably looks like this: /opt/local/lib/php/extensions/no-debug-non-zts-20060613. Apple-c that path or write it down. You will need it later.


User Contributed Notes
tutorials.installation.macosx-stepbystep.php
add a note about notes
There are no user contributed notes for this page.


previousInstallation on Mac OS X
Hello World (basic)next

Last updated: Sun, 12 May 2013
view this page in English


credits 

PHP  Copyright © 2001-2014 The PHP Group
 All rights reserved.
Last updated: Sun May 12 20:51:01 2013 CEST