php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #14156 No TTF support in this PHP build
Submitted: 2001-11-21 04:19 UTC Modified: 2001-11-28 06:23 UTC
Votes:1
Avg. Score:5.0 ± 0.0
Reproduced:0 of 0 (0.0%)
From: kuba at 3net dot pl Assigned:
Status: Closed Package: GD related
PHP Version: 4.0.6 OS: RH 7.2
Private report: No CVE-ID: None
Welcome back! If you're the original bug submitter, here's where you can edit the bug or add additional notes.
If this is not your bug, you can add a comment by following this link.
If this is your bug, but you forgot your password, you can retrieve your password here.
Password:
Status:
Package:
Bug Type:
Summary:
From: kuba at 3net dot pl
New email:
PHP Version: OS:

 

 [2001-11-21 04:19 UTC] kuba at 3net dot pl
libgd-1.8.4
freetype-2.0.3-7
freetype-devel-2.0.3-7
freetype-utils-2.0.3-7

Although in big #9569 you've said that
GD extension only works with Freetype 1.x
Guys from gd are saying:
"If you want to use the TrueType font support, you must 
also install the FreeType 2.x library, including the 
header files."

while configuring, I got this:
checking whether to enable truetype string function in 
gd... no
checking for freetype(2)... no



my config line:
./configure --prefix=/usr --with-config-file-path=/etc 
--disable-debug --enable-shared --with-apxs=/usr/sbin/apxs 
--with-gd --with-jpeg-dir=/usr --with-png 
--with-ttf=/usr/lib --with-freetype=/usr/lib --with-zlib 
--enable-safe-mode --enable-track-vars --enable-ftp 
--with-mysql=/usr/local/mysql --with-dbase --with-gettext


script:
<?php
$im = imagecreate (400, 30);
$black = ImageColorAllocate ($im, 0, 0, 0);
$white = ImageColorAllocate ($im, 255, 255, 255);
ImageTTFText ($im, 20, 0, 10, 20, $white, 
"/path/arial.ttf",
              "Testing... Omega: &#937;");
ImagePNG ($im);
?>


error:
Warning: ImageTtfText: No TTF support in this PHP build

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2001-11-21 12:51 UTC] sander@php.net
Use --enable-gd-native-ttf or --enable-gd-native-tt (yes that's a typo) if the first doesn't work.
 [2001-11-28 02:46 UTC] kuba at 3net dot pl
it works fine with
--with-freetype-dir=/usr/lib --enable-gd-native-ttf
and i got support for TTF, 

but then I got "libgd was not built with TrueType" 
so I had to make change in source code that was 
exlained in bug #12065

# if HAVE_LIBGD20 & HAVE_LIBFREETYPE 
=>
# HAVE_LIBFREETYPE


now I can use TTF functions

but, did someone make changes in the source code,
so people won't have to do it by themselves?

JF
 [2001-11-28 06:23 UTC] sander@php.net
Now your problem is that your version of GD was not built with FreeType. You should build it yourself from the source or use a different package.
 [2002-10-06 09:02 UTC] info at alexurus dot de
I can't find 

# if HAVE_LIBGD20 & HAVE_LIBFREETYPE 

in /usr/local/gd/gd.c
what should I do ?
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Fri Apr 19 22:01:28 2024 UTC