Summary: | php5 mod_php5 ttf support configure flags missing | ||
---|---|---|---|
Product: | Gentoo Linux | Reporter: | Ingus Rukis <kaklz> |
Component: | [OLD] Development | Assignee: | PHP Bugs <php-bugs> |
Status: | RESOLVED INVALID | ||
Severity: | blocker | ||
Priority: | High | ||
Version: | unspecified | ||
Hardware: | x86 | ||
OS: | Linux | ||
Whiteboard: | |||
Package list: | Runtime testing required: | --- |
Description
Ingus Rukis
2004-11-05 08:38:49 UTC
Quote from http://php.net/imagettftext: If you compiled PHP yourself but get an error: Fatal error: Call to undefined function imagettftext(). You need to compile PHP with more options. --with-gd --enable-gd-native-ttf --with-png --with-zlib-dir=/usr/local/lib/zlib-1.2.1 --with-ttf --with-jpeg-dir=/usr/local/lib/jpeg-6b/ --with-freetype-dir=/usr/local/lib/freetype-2.1.9/ --with-xpm-dir=/usr/X11R6/ The next set deal with setting up GD, and the appropriate options. Just enabling GD, ttf, png & jpeg is NOT enough. You also need Freetype and XPM. The following code from the php5-sapi.eclass is probably responsible for this mess. It also breaks t1lib support. if useq gd-external ; then enable_extension_with "gd" "gd-external" 1 "/usr" enable_extension_enable "gd-jis-conf" "nls" 0 enable_extension_enable "gd-native-ttf" "truetype" 0 else enable_extension_with "freetype-dir" "truetype" 0 "/usr" enable_extension_with "t1lib" "truetype" 0 "/usr" enable_extension_with "ttf" "truetype" 0 "/usr" enable_extension_enable "gd-jis-conf" "nls" 0 enable_extension_enable "gd-native-ttf" "truetype" 0 enable_extension_with "png-dir" "png" 0 "/usr" enable_extension_with "tiff-dir" "tiff" 0 "/usr" enable_extension_with "xpm-dir" "xpm" 0 "/usr/X11R6" # enable gd last, so configure can pick up the previous settings enable_extension_with "gd" "gd" 0 fi One Month and nothing happend and loads of statistical programs use the gd functions for rendering charts. If they also use postscript fonts, they all get broken by this bug. If you USE=gd-external, then the following options would have NO effect on PHP. They are passed thru to the internal copy of GD. enable_extension_with "freetype-dir" "truetype" 0 "/usr" enable_extension_with "t1lib" "truetype" 0 "/usr" enable_extension_with "ttf" "truetype" 0 "/usr" enable_extension_with "png-dir" "png" 0 "/usr" enable_extension_with "tiff-dir" "tiff" 0 "/usr" enable_extension_with "xpm-dir" "xpm" 0 "/usr/X11R6" Either turn off USE=gd-external, or go and ensure that your external GD is compiled with all of the options required. |