Build PHP with Freetype on DirectAdmin

Easy way to add freetype support on PHP, on a DirectAdmin hosting environment with Fedora as the OS, is to use the rpm versions of freetype and freetype-devel.

  1. If not installed already:
    # yum install freetype freetype-devel

  2. Edit "/usr/local/directadmin/customapache/configure.php" to include the below lines.
            --with-freetype \
            --with-freetype-dir=/usr/lib \
            --enable-gd-native-ttf \

    Note: /usr/lib is the path to the .
    # rpm -ql freetype-devel | grep

  3. Then run the build:
    # ./build clean
    # ./build php n

  4. If you need to build and update existing packages:
    # ./build clean
    # ./build update
    # ./build all

  5. Check with phpinfo to confirm.

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.

Enabling exif for php

Install exif:

# yum install libexif libexif-devel

Edit configure.php with:

--enable-exif \

Re-compile php with exif enabled.

# ./build clean
# ./buid php n

Check with phpinfo.