Click to See Complete Forum and Search --> : compiling php5 with gd on Fedora Core 4
grantdutoit
05-28-2007, 12:24 PM
I have a FC4 server which I setup according to this forum post: http://fedoranews.org/cms/node/411. All went well doing it. It does not configure gd as '--with-gd' but rather '--without-gd'. I run a phpwcms-xt CMS which requires that GD-Lib be available.
I am an absolutely newbie to servers, php and all the rest. Can some body please provide me with a step by step procedure to change this?
bpat1434
05-28-2007, 12:37 PM
Is GD installed?
If you can, from a terminal (SSH or on the server) run
# yum install gd
That will install GD. Then try compiling php --with-gd ;)
grantdutoit
05-28-2007, 01:09 PM
When I do that this is what the terminal gives:
[root@localhost ~]# yum install gd
Setting up Install Process
Setting up repositories
updates-released 100% |=========================| 951 B 00:00
extras 100% |=========================| 1.1 kB 00:00
base 100% |=========================| 1.1 kB 00:00
Reading repository metadata in from local files
Parsing package install arguments
Nothing to do
[root@localhost ~]#
[root@localhost ~]#
I assume that compiling it is next. What command do I use here?
bradgrafelman
05-28-2007, 03:25 PM
Instead, try doing yum install php-gd .
(Taken from this (http://www.boutell.com/gd/faq.html) FAQ page)
grantdutoit
05-28-2007, 05:05 PM
Ran the command and says the same as the previous method.
"Nothing to do"
my php-5.1.2 folder is located in /root/php-5.1.2. Is this normal?
bpat1434
05-28-2007, 05:36 PM
No, typical php installs would go under /usr/local/php-5.1.2 or something similar that all users can access. As far as i know, /root is only accessible as root and as such, Apache would have to run as root which is a BAD idea.
When you compile php, use the --prefix switch to tell it where to install to. A typical configure is like:
$ ./configure --with-apxs=/usr/local/apache/bin/apxs --prefix=/usr/local
That of course is followed by all your --with-gd and other libraries.
grantdutoit
05-29-2007, 05:42 AM
Below is what i ran previously. For some reason i am convinced that my php is installed in the wrong place. Is any one familiar with FC4 that can advise on how and where to install php on FC4?
./configure '--build=i386-redhat-linux' '--host=i386-redhat-linux' '--target=i386-redhat-linux-gnu' '--program-prefix=' '--prefix=/usr' '--exec-prefix=/usr' '--bindir=/usr/bin' '--sbindir=/usr/sbin' '--sysconfdir=/etc' '--datadir=/usr/share' '--includedir=/usr/include' '--libdir=/usr/lib' '--libexecdir=/usr/libexec' '--localstatedir=/var' '--sharedstatedir=/usr/com' '--mandir=/usr/share/man' '--infodir=/usr/share/info' '--cache-file=../config.cache' '--with-libdir=lib' '--with-config-file-path=/etc' '--with-config-file-scan-dir=/etc/php.d' '--disable-debug' '--with-pic' '--disable-rpath' '--with-bz2' '--with-curl' '--with-exec-dir=/usr/bin' '--with-freetype-dir=/usr' '--with-png-dir=/usr' '--enable-gd-native-ttf' '--without-gdbm' '--with-gettext' '--with-gmp' '--with-iconv' '--with-jpeg-dir=/usr' '--with-openssl' '--with-png' '--without-pspell' '--with-expat-dir=/usr' '--with-pcre-regex=/usr' '--with-zlib' '--with-layout=GNU' '--enable-exif' '--enable-ftp' '--enable-magic-quotes' '--enable-sockets' '--enable-sysvsem' '--enable-sysvshm' '--enable-sysvmsg' '--enable-track-vars' '--enable-trans-sid' '--enable-yp' '--enable-wddx' '--with-pear=/usr/share/pear' '--with-kerberos' '--enable-ucd-snmp-hack' '--without-unixODBC' '--enable-memory-limit' '--enable-shmop' '--enable-calendar' '--enable-dbx' '--enable-dio' '--with-mime-magic=/etc/httpd/conf/magic' '--without-sqlite' '--with-libxml-dir=/usr' '--with-xml' '--with-apxs2=/usr/sbin/apxs' '--with-mysql' '--with-gd' '--without-odbc' '--disable-dom' '--disable-dba'
PHP Builder
Copyright WebMediaBrands Inc. All Rights Reserved.