in ,

how to install ffmpeg php on centos

Install FFmpeg PHP Extension on Centos

Install FFmpeg PHP Extension on Centos

Hello here we come with a new tutorial on installing ffmpeg php extension on centos. We all know that ffmpeg is very useful to convert and play
audio and video file as well as online convert.
Before  installing FFmpeg PHP extension you must install the FFmpeg  on your server.
Visit Below Link For FFMPEG:
http://www.bloggertale.com/2013/11/23/how-to-install-ffmpeg-latest-version-at-centos/#.UpjpItIW33IAfter installing  FFmpeg  you can proceed to install ffmpeg php on centos:Step 1)

Download the latest version of FFmpeg-php.
Visit the Below site:
http://ffmpeg-php.sourceforge.net

You can download the latest release using  wget command.

wget "http://downloads.sourceforge.net/project/ffmpeg-php/ffmpeg-php/0.6.0/ffmpeg-php-0.6.0.tbz2?use_mirror=garr"

After downloading you can see the downloaded package in your /root directory which is default.

Step 2) Now extract the file using below command:

Code:
tar xjvf ffmpeg-php-0.6.0.tbz2

Step 3) Now enter to the extracted directory using below command:

Code:
cd ffmpeg-php-0.6.0

Step 4) Now  run below command:

Code:
phpize

if you get command not found error than probably you don’t have the php  devel installed.
Run the below command to fix it including the above command:

Code:
yum install php-devel
Then again Use this command
phpize

Step 5) Now run below command to install the FFmpeg-php:

Code:
./configure
make
make install

if you get header not found or some similar error then you can fix it by running the below command with the above one:

Code:
yum install ffmpeg-devel
./configure
make
make install

if you get error similar to shared library not found then run the commands given below:

Code:
./configure --with-ffmpeg=/usr/local/cpffmpeg
./configure
make
make install

Now ffmpeg should be installed correctly without any problem.

Note: if you see an error related with PIX_FMT_RGBA32 then you will need to fix it using this tutorial.

Error PIX_FMT_RGBA32 While Installing FFmpeg PHP Extension

Step 6) Now at the end you will need to edit your php.ini file, paste the below code to load the FFmpeg module in php and save it.

Code:
[code][ffmpeg]
extension=ffmpeg.so

Step 7) Restart the apache and your FFmpeg installation has been completed.

Code:
service httpd restart

Addons: Now you may want to install some addons like Mencoder and mplayer.
Use below command to install them:

Code:
yum install mplayer mencoder
For more tutorial please subscribe us.

What do you think?

0 points
Upvote Downvote

Total votes: 0

Upvotes: 0

Upvotes percentage: 0.000000%

Downvotes: 0

Downvotes percentage: 0.000000%

Leave a Reply

Your email address will not be published. Required fields are marked *