0

I'm unable to install GD and Freetype for PHP on centos.

I've read many similar questions like this one Install GD library and freetype on Linux But I'm still having no luck..

    [root@media modules]# sudo yum install php-gd
    Loaded plugins: fastestmirror, priorities, replace, security
    Setting up Install Process
    Loading mirror speeds from cached hostfile
     * base: mirror.overthewire.com.au
     * extras: mirror.nsw.coloau.com.au
     * ius: ius.mirror.digitalpacific.com.au
     * remi-php56: mirror.innosol.asia
     * rpmforge: mirror.ventraip.net.au
     * updates: mirror.overthewire.com.au
    Resolving Dependencies
    --> Running transaction check
    ---> Package php-gd.x86_64 0:5.6.20-1.el6.remi will be installed
    --> Processing Dependency: gd-last(x86-64) >= 2.1.1 for package: php-gd-5.6.20-1.el6.remi.x86_64
    --> Processing Dependency: libvpx.so.1()(64bit) for package: php-gd-5.6.20-1.el6.remi.x86_64
    --> Processing Dependency: libgd.so.3()(64bit) for package: php-gd-5.6.20-1.el6.remi.x86_64
    --> Running transaction check
    ---> Package libvpx.x86_64 0:1.3.0-5.el6_5 will be installed
    ---> Package php-gd.x86_64 0:5.6.20-1.el6.remi will be installed
    --> Processing Dependency: gd-last(x86-64) >= 2.1.1 for package: php-gd-5.6.20-1.el6.remi.x86_64
    --> Processing Dependency: libgd.so.3()(64bit) for package: php-gd-5.6.20-1.el6.remi.x86_64
    --> Finished Dependency Resolution
    Error: Package: php-gd-5.6.20-1.el6.remi.x86_64 (remi-php56)
               Requires: gd-last(x86-64) >= 2.1.1
    Error: Package: php-gd-5.6.20-1.el6.remi.x86_64 (remi-php56)
               Requires: libgd.so.3()(64bit)
     You could try using --skip-broken to work around the problem
     You could try running: rpm -Va --nofiles --nodigest
    sudo apt-get install freetype*[root@media modules]# sudo apt-get install freetype*
    sudo: apt-get: command not found

    [root@media modules]# sudo yum install freetype*
    Loaded plugins: fastestmirror, priorities, replace, security
    Setting up Install Process
    Loading mirror speeds from cached hostfile
     * base: mirror.overthewire.com.au
     * extras: mirror.nsw.coloau.com.au
     * ius: ius.mirror.digitalpacific.com.au
     * remi-php56: remi.conetix.com.au
     * rpmforge: repoforge.mirror.digitalpacific.com.au
     * updates: mirror.overthewire.com.au
    Package freetype-2.3.11-15.el6_6.1.x86_64 already installed and latest version
    Package freetype-devel-2.3.11-15.el6_6.1.x86_64 already installed and latest version
    Package freetype-demos-2.3.11-15.el6_6.1.x86_64 already installed and latest version
    Nothing to do

    [root@media modules]# service httpd restart
    Stopping httpd:                                            [  OK  ]
    Starting httpd:                                            [  OK  ]

    [root@media modules]# sudo yum install php56-gd
    Loaded plugins: fastestmirror, priorities, replace, security
    Setting up Install Process
    Loading mirror speeds from cached hostfile
     * base: mirror.overthewire.com.au
     * extras: mirror.nsw.coloau.com.au
     * ius: syd.mirror.rackspace.com
     * remi-php56: remi.conetix.com.au
     * rpmforge: mirror.ventraip.net.au
     * updates: mirror.overthewire.com.au
    No package php56-gd available.
    Error: Nothing to do

[root@media modules]# yum install php-gd --enablerepo=remi,remi-php56
Loaded plugins: fastestmirror, priorities, replace, security
Setting up Install Process
Loading mirror speeds from cached hostfile
 * base: mirror.overthewire.com.au
 * extras: mirror.nsw.coloau.com.au
 * ius: ius.mirror.digitalpacific.com.au
 * remi-php56: remi.conetix.com.au
 * rpmforge: repoforge.mirror.digitalpacific.com.au
 * updates: mirror.overthewire.com.au
Resolving Dependencies
--> Running transaction check
---> Package php-gd.x86_64 0:5.6.20-1.el6.remi will be installed
--> Processing Dependency: gd-last(x86-64) >= 2.1.1 for package: php-gd-5.6.20-1.el6.remi.x86_64
--> Processing Dependency: libvpx.so.1()(64bit) for package: php-gd-5.6.20-1.el6.remi.x86_64
--> Processing Dependency: libgd.so.3()(64bit) for package: php-gd-5.6.20-1.el6.remi.x86_64
--> Running transaction check
---> Package libvpx.x86_64 0:1.3.0-5.el6_5 will be installed
---> Package php-gd.x86_64 0:5.6.20-1.el6.remi will be installed
--> Processing Dependency: gd-last(x86-64) >= 2.1.1 for package: php-gd-5.6.20-1.el6.remi.x86_64
--> Processing Dependency: libgd.so.3()(64bit) for package: php-gd-5.6.20-1.el6.remi.x86_64
--> Finished Dependency Resolution
Error: Package: php-gd-5.6.20-1.el6.remi.x86_64 (remi-php56)
           Requires: gd-last(x86-64) >= 2.1.1
Error: Package: php-gd-5.6.20-1.el6.remi.x86_64 (remi-php56)
           Requires: libgd.so.3()(64bit)
 You could try using --skip-broken to work around the problem
 You could try running: rpm -Va --nofiles --nodigest

My web app still shows

PHP GD Extension:   Not Found
PHP FreeType Support:   Not Found

And I'm pretty confident about this because it work before I uninstalled PHP and installed a different version and lost these extensions :/

Community
  • 1
  • 1
braks
  • 1,505
  • 15
  • 23
  • 2 second google: http://forum.remirepo.net/viewtopic.php?id=2698 – Wrikken Apr 05 '16 at 23:45
  • No, you can see in my question I've tried something like that already. – braks Apr 05 '16 at 23:54
  • 1
    You don't appear to have a `remi` repo. Do you see one if you run `yum repolist`? Is freetype support something that can be dynamically loaded the way gd appears to work? I thought it was a compile-time choice. – Etan Reisner Apr 06 '16 at 02:26

1 Answers1

2

Missing the EPEL and remi-safe repositories which provides common dependencies for the various PHP versions available in remi-php55, remi-php56, remi-php70...

remi-safe repository is enabled by default when you install the remi-release configuration package. epel-release is a dependency of remi-release.

The configuration wizard gives you the correct instructions.

Duplicate of http://forum.remirepo.net/viewtopic.php?id=3402

Remi Collet
  • 6,198
  • 1
  • 20
  • 25
  • I suspected it would be something like that! I just lost track of what came from where after all the advice I found like "disable this conflicting repo, add this repo..." for various things I've done in the last couple days. PS your wizard thing links to a localhost. Unless that was supposed to link to something on my computer? I'm puttying to a server from windows. – braks Apr 06 '16 at 07:01
  • 1
    Link to configuration wizard fixed. – Remi Collet Apr 06 '16 at 07:19
  • I've never seen that configuration wizard before. You rock, Remi! – thelr Jun 04 '21 at 20:20