image
image

Go Back   macosx.com > Mac Help Forums > Mac OS X System & Mac Software

Reply
 
Thread Tools
  #1  
Old June 1st, 2001, 09:31 PM
Registered User
 
Join Date: Jun 2001
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
inuit is on a distinguished road
Unhappy building PHP w/ gd on MacOS X

i want to build php with gd on my macos x.

first i installed all libraries (zlib, pnglib and jpeg) and then installed gd. after this i wanted to compile php for gd.

"./configure" was ok but then with "make" the following error came:

/Users/firewall/Desktop/php-4.0.5/main/.libs
Making all in ext
Making all in gd
/bin/sh /Users/firewall/Desktop/php-4.0.5/libtool --silent --mode=compile cc -I. -I/Users/firewall/Desktop/php-4.0.5/ext/gd -I/Users/firewall/Desktop/php-4.0.5/main -I/Users/firewall/Desktop/php-4.0.5 -I/usr/include/httpd -I/Users/firewall/Desktop/php-4.0.5/Zend -I/usr/local/include -I/Users/firewall/Desktop/php-4.0.5/ext/mysql/libmysql -I/Users/firewall/Desktop/php-4.0.5/ext/xml/expat/xmltok -I/Users/firewall/Desktop/php-4.0.5/ext/xml/expat/xmlparse -I/Users/firewall/Desktop/php-4.0.5/TSRM -traditional-cpp -DDARWIN -DUSE_HSREGEX -DUSE_EXPAT -DHARD_SERVER_LIMIT=1024 -DEAPI -DSUPPORT_UTF8 -DXML_BYTE_ORDER=21 -g -O2 -c gd.c
gd.c:91: conflicting types for `gdIOCtx'
/usr/local/include/gd_io.h:18: previous declaration of `gdIOCtx'
make[3]: *** [gd.lo] Error 1
make[2]: *** [all-recursive] Error 1
make[1]: *** [all-recursive] Error 1
make: *** [all-recursive] Error 1


do you have any idea what the problem is?


thanks
jomo
Reply With Quote
  #2  
Old June 11th, 2001, 01:10 PM
Registered User
 
Join Date: Jun 2001
Posts: 16
Thanks: 0
Thanked 0 Times in 0 Posts
offets is on a distinguished road
gd.c:91: conflicting types for `gdIOCtx'
/usr/local/include/gd_io.h:18: previous declaration of `gdIOCtx'

gdIOtx has been declarated as two different types (int and string for example).
look at the source in /usr/local/include/gd_io.h and try to figure out which type it should be.

Otherwise something is wrong with your gd installation.
Reply With Quote
  #3  
Old June 17th, 2001, 01:25 PM
Registered User
 
Join Date: Jun 2001
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
jtovar is on a distinguished road
I don't know the particlulars of your error but I have finally got gd running doing the following:

First build gd as explained by Scott Anguish at Stepwise:

http://www.stepwise.com/Articles/Wor...-06-12.01.html

Next you need to build PHP, here is what I did

mkdir build-php-4.0.5
cd build-php-4.0.5

wget http://www.php.net/distributions/php-4.0.5.tar.gz
wget http://graphics.stepwise.com/Article...4.0.5-genif.sh
gnutar -xzf php-4.0.5.tar.gz

mv php-4.0.5-genif.sh \
php-4.0.5/build/genif.sh

pushd php-4.0.5

./configure \
--with-xml \
--with-zlib \
--with-jpeg-dir=/usr/local \
--with-gd=/usr/local \
--with-apxs=/usr/sbin/apxs

make
sudo make install
sudo cp php.ini-dist /usr/local/lib/php.ini
popd

This was just Scott's PHP instructions appended to add the gd & jpeg extentions. If you do not add the jpeg extention, you will not be able to use gd to manipulate jpegs. Just as a note, although the jpeg and gd libraries are located at /usr/local/lib PHP for some dumb reason appends /lib to the paths. It took me several hours of frustration trying to figure out way I was getting incorrect path errors during the build.

Now if someone can get NetPBM working I'll be set.
Reply With Quote
Reply

Thread Tools

Posting 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 Off
Pingbacks are Off
Refbacks are Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Enabling PHP in 10.2 Client sixthring Mac OS X System & Mac Software 2 October 28th, 2002 01:48 PM
MacOS X DNS wjaiv Mac OS X System & Mac Software 1 January 13th, 2002 10:32 PM
PHP + MySQL running but not ZLIB lashampoo Mac OS X System & Mac Software 2 October 8th, 2001 05:58 PM
How To Integrate Fink's Apache with MacOS X slur Mac OS X System & Mac Software 1 October 5th, 2001 09:50 PM
MacOS X feels like it's running slower... cockneygeezer Apple News, Rumors & Discussion 3 May 13th, 2001 11:04 AM


All times are GMT -5. The time now is 11:50 AM.


Mac Support® Version 3.7.2
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.1.0
Copyright 2000-2008 DigitalCrowd, Inc.