Quickly install ffmpeg-php library in CentOS

by jagbir on June 15, 2009

ffmpeg-php is a PHP extension that adds functions for accessing and retrieving information from movies and audio files.

Here’s quick steps which worked for me and you can try to install this library in a RedHat based distro (I’ve checked in a fresh CentOS 5).

Step 1. Install standard ffmpeg and its dependencies using yum:

# yum install ffmpeg ffmpeg-devel php-devel

Step 2. Download and install ffmpeg-php:

# cd /usr/src
# wget http://biznetnetworks.dl.sourceforge.net/sourceforge/ffmpeg-php/ffmpeg-php-0.6.0.tbz2
# tar xjf ffmpeg-php-0.6.0.tbz2
# cd ffmpeg-php-0.6.0
# phpize
# ./configure –enable-shared –prefix=/usr
# make
# make install

Here, we used phpize to create config files. You should check installation docs to enable more libraries through configure command.

  • http://jonathanyoungblood.com jonathan

    it should be noted that this version of ffmpeg has a typo and you’ll need to rename this:

    cp -p ffmpeg-php.loT ffmpeg-php.lo

    do this before the ./configure line and you’ll be golden. (also for this line should be: ./configure –enable-shared –prefix=/usr …pretty obvious, but still worth noting)

  • http://www.omlinux.comwww.linuxwebthink.com linuxdebian

    underprocessing will come back digest programing…:)

  • Sayan Acharjee

    I was trying to install ffmpeg-php on Fedora9, I’ve downloaded the ffpmeg-php-0.6.0 and used phpize and ./configure –enable-shared –prefix=/usr and both of them workrd find but when I tried to run make I got the following error:
    “make: *** No targets specified and no makefile found. Stop.”

    I tried the same procedure with ffmpeg-php-0.5.1 and ffmpeg-0.5.0 but failed.
    Can anyone help with this. :|

    • http://www.jagbir.info jagbir

      this is weird.. are you sure the ./configure command went successful. usually, if configure command is ok then it should produce makefile that can be compiled etc.


  • Paul

    @Sayan Acharjee
    Are you still have this problem Sayan??

  • http://www.balianti.com Shahzad

    I got stuck at FFMPEG configuration. I am getting this error

    Unknown option “–enable-libogg”.
    See ./configure –help for available options.

    Can anyone help me?

  • http://pixdome.com oxsen

    I still don’t see ffmpeg on my php info, Really made my head spinning :-D

Previous post:

Next post: