LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Non-*NIX Forums > Programming
User Name
Password
Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.

Notices


Reply
  Search this Thread
Old 08-22-2005, 04:13 PM   #1
stefanlasiewski
Member
 
Registered: Aug 2003
Location: Berkeley, California, USA
Distribution: Red Hat Enterprise Linux, Debian & Ubuntu
Posts: 92

Rep: Reputation: 16
PHP: What is required for GD & ImageTTFBBox


Hello Gang,

I have some PHP pages that require GD.

I compiled PHP 5.0.4 to use GD, and GD's native TTF support, like this:

Code:
% tar zxf php-5.0.4.tar.gz
% cd php5.0.4
% ./configure \
--with-gd   \
--enable-gd-native-ttf
However, most of these pages fail with the following error:

"Fatal error: Call to undefined function ImageTTFBBox() in /usr/local/httpd/weather/graph.php on line 1273"

What do I need to do to get ImageTTFBBox to work? I know ImageTTFBBox is a native class. GD has native TTF support, correct?

Do I still need to install TrueType, FreeType or some other package?

Last edited by stefanlasiewski; 08-22-2005 at 07:05 PM.
 
Old 08-23-2005, 02:33 PM   #2
stefanlasiewski
Member
 
Registered: Aug 2003
Location: Berkeley, California, USA
Distribution: Red Hat Enterprise Linux, Debian & Ubuntu
Posts: 92

Original Poster
Rep: Reputation: 16
I needed the True-Type font libraries & fonts

I finally resolved this--

To use these packages, you must have some True-Type font libraries as well as some True-Type font files installed on your system.

On Debian, I resolved this by installing the following packages:

libttf2 libttf-dev libfreetype6 freetype2 libfreetype6-dev msttcorefonts

And then I compiled PHP 5.0.4 with the following configure settings:

--with-gd --enable-gd-native-ttf --with-ttf --with-freetype-dir=/usr/include --with-zlib


I don't think all of these packages and compile settings are required, but I don't have time to figure out which ones are required and which are optional.
 
  


Reply



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 Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
PHP Call to undefined function imagettfbbox() QtCoder Programming 24 01-18-2012 12:20 PM
what is the best distro for web developers...mysql, php, and apache required sketchydave Linux - Distributions 4 11-24-2005 03:24 PM
php-devel & PHP extensions EHCanadian Mandriva 0 06-23-2005 06:06 PM
php configuration erro libxml2 version 2.5.10 or higher required raninix Linux - Newbie 2 10-28-2004 10:59 AM
Php Help Required carlosruiz Programming 6 08-29-2004 06:14 AM

LinuxQuestions.org > Forums > Non-*NIX Forums > Programming

All times are GMT -5. The time now is 11:56 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration