No PHP 5.4 ou superior, é retornado o seguinte erro na compilação:
/usr/local/install/ffmpeg-php-0.6.0/ffmpeg_tools.c: In function ‘ffmpeg_img_convert’: /usr/local/install/ffmpeg-php-0.6.0/ffmpeg_tools.c:79: warning: passing argument 2 of ‘sws_scale’ from incompatible pointer type /usr/include/libswscale/swscale.h:195: note: expected ‘const uint8_t * const*’ but argument is of type ‘uint8_t **’ /usr/local/install/ffmpeg-php-0.6.0/ffmpeg_movie.c: In function ‘zim_ffmpeg_movie___construct’: /usr/local/install/ffmpeg-php-0.6.0/ffmpeg_movie.c:311: error: ‘list_entry’ undeclared (first use in this function) /usr/local/install/ffmpeg-php-0.6.0/ffmpeg_movie.c:311: error: (Each undeclared identifier is reported only once /usr/local/install/ffmpeg-php-0.6.0/ffmpeg_movie.c:311: error: for each function it appears in.) /usr/local/install/ffmpeg-php-0.6.0/ffmpeg_movie.c:311: error: ‘le’ undeclared (first use in this function) /usr/local/install/ffmpeg-php-0.6.0/ffmpeg_movie.c:346: error: expected ‘;’ before ‘new_le’ /usr/local/install/ffmpeg-php-0.6.0/ffmpeg_movie.c:356: error: ‘new_le’ undeclared (first use in this function) /usr/local/install/ffmpeg-php-0.6.0/ffmpeg_movie.c: In function ‘_php_read_av_frame’: /usr/local/install/ffmpeg-php-0.6.0/ffmpeg_movie.c:1215: warning: ‘avcodec_decode_video’ is deprecated (declared at /usr/include/libavcodec/avcodec.h:3452) make: *** [ffmpeg_movie.lo] Error 1 make: *** Waiting for unfinished jobs....
Para contornar, devem ser realizadas as alterações abaixo nos seguintes arquivos:
ffmpeg_frame.c
Substituir as linhas que contém PIX_FMT_RGBA32 por PIX_FMT_RGB32.
ffmpeg_movie.c
linha 311: SUBSTITUIR list_entry *le; POR zend_rsrc_list_entry *le; linha 346: SUBSTITUIR list_entry new_le; POR zend_rsrc_list_entry new_le; linha 360: SUBSTITUIR hashkey_length+1, (void *)&new_le, sizeof(list_entry), POR hashkey_length+1, (void *)&new_le,sizeof(zend_rsrc_list_entry),
Após, só instalar com os comandos abaixo:
cd ffmpeg-php-0.6.0 ./configure --enable-skip-gd-check make make install