LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   Tryin to install FFmpeg (https://www.linuxquestions.org/questions/linux-newbie-8/tryin-to-install-ffmpeg-888965/)

awww 06-29-2011 07:41 AM

Tryin to install FFmpeg
 
I have been tryin to install ffmpeg but it doesnt seem to work when i type the whereis command i get this ffmpeg: /usr/bin/ffmpeg /usr/share/ffmpeg /usr/share/man/man1/ffmpeg.1.gz

so ok that means its installed but every time i try to install the extension it doesn't show i recently installed uploadprogress and added the extension to the .php.ini file and its there
http://i51.tinypic.com/2iqi9hl.png
extensions here what am i doing wrong

http://i51.tinypic.com/e1avqh.png

Snark1994 06-29-2011 07:47 AM

Is it under the "Dynamic Extensions" section of your php.ini file? There should be a line saying "extension=ffmpeg.so", like you had in your screenshot (btw, if you're just posting text, it's better to do it AS text rather than in a screenshot :) )

Also, have you restarted your httpd server (or rebooted)?

Cultist 06-29-2011 07:52 AM

What distro are you trying to install it in?

awww 06-29-2011 07:52 AM

yes i rebooted the whole server even to make sure its here

its below every thing in my php.ini file

---------- Post added 06-29-11 at 07:52 AM ----------

OS: CentOS 5 w/ Plesk

Cultist 06-29-2011 07:56 AM

Did you compile FFmpeg from source or did you install it as an RPM package? And if you used a package, was it one specific to another distro?

awww 06-29-2011 07:57 AM

i used yum to install it

Snark1994 06-29-2011 07:58 AM

Wait, sorry, just re-read your original post - you've install ffmpeg, have you installed ffmpeg-php ?

awww 06-29-2011 08:04 AM

i think yes

Code:

[root@~]# yum install ffmpeg ffmpeg-devel php-devel
Loaded plugins: fastestmirror, priorities
Loading mirror speeds from cached hostfile
 * atomic: www4.atomicorp.com
 * epel: mirrors.solfo.com
 * rpmforge: fr2.rpmfind.net
Reducing CentOS-5 Testing to included packages only
Finished
2051 packages excluded due to repository priority protections
Setting up Install Process
Package ffmpeg-0.6.1-1.el5.rf.x86_64 already installed and latest version
Package ffmpeg-devel-0.6.1-1.el5.rf.x86_64 already installed and latest version
Package php-devel-5.3.6-3.el5.art.x86_64 already installed and latest version


Snark1994 06-29-2011 08:05 AM

Reading this article, you need to compile and install ffmpeg-php manually having installed some of the packages you just installed.

awww 06-29-2011 08:10 AM

would this be the issue because thats the same site i followed to install it


Code:

Reducing CentOS-5 Testing to included packages only
Finished
2051 packages excluded due to repository priority protections
Setting up Install Process
Package ffmpeg-0.6.1-1.el5.rf.x86_64 already installed and latest version
Package ffmpeg-devel-0.6.1-1.el5.rf.x86_64 already installed and latest version
Package php-devel-5.3.6-3.el5.art.x86_64 already installed and latest version
Resolving Dependencies
--> Running transaction check
---> Package php-devel.i386 0:5.3.6-3.el5.art set to be updated
--> Finished Dependency Resolution

Dependencies Resolved

================================================================================
 Package          Arch        Version                    Repository      Size
================================================================================
Installing:
 php-devel        i386        5.3.6-3.el5.art            atomic        623 k

Transaction Summary
================================================================================
Install      1 Package(s)
Upgrade      0 Package(s)

Total size: 623 k
Is this ok [y/N]: y
Downloading Packages:
Running rpm_check_debug
Running Transaction Test
Finished Transaction Test


Transaction Check Error:
  file /usr/bin/php-config from install of php-devel-5.3.6-3.el5.art.i386 conflicts with file from package php-devel-5.3.6-3.el5.art.x86_64
  file /usr/include/php/main/build-defs.h from install of php-devel-5.3.6-3.el5.art.i386 conflicts with file from package php-devel-5.3.6-3.el5.art.x86_64
  file /usr/include/php/main/php_config.h from install of php-devel-5.3.6-3.el5.art.i386 conflicts with file from package php-devel-5.3.6-3.el5.art.x86_64

Error Summary
-------------


Snark1994 06-29-2011 08:11 AM

Then what about the section:

Quote:

Installing ffmpeg-php

Now we are ready to install ffmpeg-php. This can be done in six easy steps:

Download the latest ffmpeg-php release
Extract the archive:
Code:

tar -xjf ffmpeg-php-X.x.x.tbz2
    cd ffmpeg-php-X.x.x/
    phpize
    ./configure && make
    sudo make install



awww 06-29-2011 08:16 AM

yes i get these errors

Code:

config.status: creating config.h
/bin/sh /root/ffmpeg-php-0.6.0/libtool --mode=compile cc  -I. -I/root/ffmpeg-php-0.6.0 -DPHP_ATOM_INC -I/root/ffmpeg-php-0.6.0/include -I/root/ffmpeg-php-0.6.0/main -I/root/ffmpeg-php-0.6.0 -I/usr/include/php -I/usr/include/php/main -I/usr/include/php/TSRM -I/usr/include/php/Zend -I/usr/include/php/ext -I/usr/include/php/ext/date/lib -I/usr/include/libavcodec/ -I/usr/include/libavformat/ -I/usr/include/libavutil/ -I/usr/include/libswscale/ -I/usr/include/libavfilter/ -I/usr/include/libavdevice/  -DHAVE_CONFIG_H  -g -O2 -Wall -fno-strict-aliasing  -c /root/ffmpeg-php-0.6.0/ffmpeg-php.c -o ffmpeg-php.lo
mkdir .libs
 cc -I. -I/root/ffmpeg-php-0.6.0 -DPHP_ATOM_INC -I/root/ffmpeg-php-0.6.0/include -I/root/ffmpeg-php-0.6.0/main -I/root/ffmpeg-php-0.6.0 -I/usr/include/php -I/usr/include/php/main -I/usr/include/php/TSRM -I/usr/include/php/Zend -I/usr/include/php/ext -I/usr/include/php/ext/date/lib -I/usr/include/libavcodec/ -I/usr/include/libavformat/ -I/usr/include/libavutil/ -I/usr/include/libswscale/ -I/usr/include/libavfilter/ -I/usr/include/libavdevice/ -DHAVE_CONFIG_H -g -O2 -Wall -fno-strict-aliasing -c /root/ffmpeg-php-0.6.0/ffmpeg-php.c  -fPIC -DPIC -o .libs/ffmpeg-php.o
/bin/sh /root/ffmpeg-php-0.6.0/libtool --mode=compile cc  -I. -I/root/ffmpeg-php-0.6.0 -DPHP_ATOM_INC -I/root/ffmpeg-php-0.6.0/include -I/root/ffmpeg-php-0.6.0/main -I/root/ffmpeg-php-0.6.0 -I/usr/include/php -I/usr/include/php/main -I/usr/include/php/TSRM -I/usr/include/php/Zend -I/usr/include/php/ext -I/usr/include/php/ext/date/lib -I/usr/include/libavcodec/ -I/usr/include/libavformat/ -I/usr/include/libavutil/ -I/usr/include/libswscale/ -I/usr/include/libavfilter/ -I/usr/include/libavdevice/  -DHAVE_CONFIG_H  -g -O2 -Wall -fno-strict-aliasing  -c /root/ffmpeg-php-0.6.0/ffmpeg_movie.c -o ffmpeg_movie.lo
 cc -I. -I/root/ffmpeg-php-0.6.0 -DPHP_ATOM_INC -I/root/ffmpeg-php-0.6.0/include -I/root/ffmpeg-php-0.6.0/main -I/root/ffmpeg-php-0.6.0 -I/usr/include/php -I/usr/include/php/main -I/usr/include/php/TSRM -I/usr/include/php/Zend -I/usr/include/php/ext -I/usr/include/php/ext/date/lib -I/usr/include/libavcodec/ -I/usr/include/libavformat/ -I/usr/include/libavutil/ -I/usr/include/libswscale/ -I/usr/include/libavfilter/ -I/usr/include/libavdevice/ -DHAVE_CONFIG_H -g -O2 -Wall -fno-strict-aliasing -c /root/ffmpeg-php-0.6.0/ffmpeg_movie.c  -fPIC -DPIC -o .libs/ffmpeg_movie.o
/root/ffmpeg-php-0.6.0/ffmpeg_movie.c: In function '_php_read_av_frame':
/root/ffmpeg-php-0.6.0/ffmpeg_movie.c:1215: warning: 'avcodec_decode_video' is deprecated (declared at /usr/include/libavcodec/avcodec.h:3454)
/bin/sh /root/ffmpeg-php-0.6.0/libtool --mode=compile cc  -I. -I/root/ffmpeg-php-0.6.0 -DPHP_ATOM_INC -I/root/ffmpeg-php-0.6.0/include -I/root/ffmpeg-php-0.6.0/main -I/root/ffmpeg-php-0.6.0 -I/usr/include/php -I/usr/include/php/main -I/usr/include/php/TSRM -I/usr/include/php/Zend -I/usr/include/php/ext -I/usr/include/php/ext/date/lib -I/usr/include/libavcodec/ -I/usr/include/libavformat/ -I/usr/include/libavutil/ -I/usr/include/libswscale/ -I/usr/include/libavfilter/ -I/usr/include/libavdevice/  -DHAVE_CONFIG_H  -g -O2 -Wall -fno-strict-aliasing  -c /root/ffmpeg-php-0.6.0/ffmpeg_frame.c -o ffmpeg_frame.lo
 cc -I. -I/root/ffmpeg-php-0.6.0 -DPHP_ATOM_INC -I/root/ffmpeg-php-0.6.0/include -I/root/ffmpeg-php-0.6.0/main -I/root/ffmpeg-php-0.6.0 -I/usr/include/php -I/usr/include/php/main -I/usr/include/php/TSRM -I/usr/include/php/Zend -I/usr/include/php/ext -I/usr/include/php/ext/date/lib -I/usr/include/libavcodec/ -I/usr/include/libavformat/ -I/usr/include/libavutil/ -I/usr/include/libswscale/ -I/usr/include/libavfilter/ -I/usr/include/libavdevice/ -DHAVE_CONFIG_H -g -O2 -Wall -fno-strict-aliasing -c /root/ffmpeg-php-0.6.0/ffmpeg_frame.c  -fPIC -DPIC -o .libs/ffmpeg_frame.o
/root/ffmpeg-php-0.6.0/ffmpeg_frame.c: In function 'zim_ffmpeg_frame_toGDImage':
/root/ffmpeg-php-0.6.0/ffmpeg_frame.c:336: error: 'PIX_FMT_RGBA32' undeclared (first use in this function)
/root/ffmpeg-php-0.6.0/ffmpeg_frame.c:336: error: (Each undeclared identifier is reported only once
/root/ffmpeg-php-0.6.0/ffmpeg_frame.c:336: error: for each function it appears in.)
/root/ffmpeg-php-0.6.0/ffmpeg_frame.c: In function 'zim_ffmpeg_frame_ffmpeg_frame':
/root/ffmpeg-php-0.6.0/ffmpeg_frame.c:421: error: 'PIX_FMT_RGBA32' undeclared (first use in this function)
make: *** [ffmpeg_frame.lo] Error 1
[root@e2180-22530 ffmpeg-php-0.6.0]# make install
/bin/sh /root/ffmpeg-php-0.6.0/libtool --mode=compile cc  -I. -I/root/ffmpeg-php-0.6.0 -DPHP_ATOM_INC -I/root/ffmpeg-php-0.6.0/include -I/root/ffmpeg-php-0.6.0/main -I/root/ffmpeg-php-0.6.0 -I/usr/include/php -I/usr/include/php/main -I/usr/include/php/TSRM -I/usr/include/php/Zend -I/usr/include/php/ext -I/usr/include/php/ext/date/lib -I/usr/include/libavcodec/ -I/usr/include/libavformat/ -I/usr/include/libavutil/ -I/usr/include/libswscale/ -I/usr/include/libavfilter/ -I/usr/include/libavdevice/  -DHAVE_CONFIG_H  -g -O2 -Wall -fno-strict-aliasing  -c /root/ffmpeg-php-0.6.0/ffmpeg_frame.c -o ffmpeg_frame.lo
 cc -I. -I/root/ffmpeg-php-0.6.0 -DPHP_ATOM_INC -I/root/ffmpeg-php-0.6.0/include -I/root/ffmpeg-php-0.6.0/main -I/root/ffmpeg-php-0.6.0 -I/usr/include/php -I/usr/include/php/main -I/usr/include/php/TSRM -I/usr/include/php/Zend -I/usr/include/php/ext -I/usr/include/php/ext/date/lib -I/usr/include/libavcodec/ -I/usr/include/libavformat/ -I/usr/include/libavutil/ -I/usr/include/libswscale/ -I/usr/include/libavfilter/ -I/usr/include/libavdevice/ -DHAVE_CONFIG_H -g -O2 -Wall -fno-strict-aliasing -c /root/ffmpeg-php-0.6.0/ffmpeg_frame.c  -fPIC -DPIC -o .libs/ffmpeg_frame.o
/root/ffmpeg-php-0.6.0/ffmpeg_frame.c: In function 'zim_ffmpeg_frame_toGDImage':
/root/ffmpeg-php-0.6.0/ffmpeg_frame.c:336: error: 'PIX_FMT_RGBA32' undeclared (first use in this function)
/root/ffmpeg-php-0.6.0/ffmpeg_frame.c:336: error: (Each undeclared identifier is reported only once
/root/ffmpeg-php-0.6.0/ffmpeg_frame.c:336: error: for each function it appears in.)
/root/ffmpeg-php-0.6.0/ffmpeg_frame.c: In function 'zim_ffmpeg_frame_ffmpeg_frame':
/root/ffmpeg-php-0.6.0/ffmpeg_frame.c:421: error: 'PIX_FMT_RGBA32' undeclared (first use in this function)
make: *** [ffmpeg_frame.lo] Error 1
[root@ ffmpeg-php-0.6.0]#


Snark1994 06-29-2011 08:21 AM

Okay, run these commands:
Code:

cp /root/ffmpeg-php-0.6.0/ffmpeg_frame.c{,.bak}
sed 's/PIX_FMT_RGBA32/PIX_FMT_RGB32/g' /root/ffmpeg-php-0.6.0/ffmpeg_frame.c.bak > /root/ffmpeg-php-0.6.0/ffmpeg_frame.c

(ie. replace all the PIX_FMT_RGBA32s with PIX_FMT_RGB32s :) )

EDIT: Also, can you replace your [PHP] tags with [CODE] tags please? Currently, it distorts the page :D

awww 06-29-2011 08:28 AM

ok i done that now what

Snark1994 06-29-2011 08:30 AM

Try to compile it again :) ./configure, make, make install.


All times are GMT -5. The time now is 03:59 AM.