0

This is a very silly question.

I need to enable GD-suport, the reference says "To enable GD-support configure PHP --with-gd[=DIR] , where DIR is the GD base install directory. To use the recommended bundled version of the GD library (which was first bundled in PHP 4.3.0), use the configure option --with-gd". But where do I put this option?

2 Answers 2

2

Depending on how you installed PHP, it's as easy as installing the package. Modern distros have up-to-date PHP packages generally so you don't need to compile from source unless you have specific needs.

That said, look for php5-gd or php-gd depending on your OS. Your question doesn't specify.

2
  • Thanks for taking time to get back to me. I installed php by yum install php5 or something like that, cannot remember exactly how I did it. Then yum install php-gd or php5-gd. So which file does "--with-gd[=DIR]" go in? Jul 1, 2013 at 19:48
  • After you install the package, restart apache and gd will just work. You only need that if you're compiling from source.
    – Nathan C
    Jul 1, 2013 at 19:49
1

You pass it to ./configure when you're building it from source.

But check if your distribution doesn't have a "php-gd" package or similar first.

2
  • I dont build php from source. I ran yum install to install php and extension. The problem is where "--with-gd[=DIR]" should go? which file exactly? many thx Jul 1, 2013 at 19:50
  • You only use it when building from source. Jul 1, 2013 at 19:53

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .