2010年9月30日木曜日

CentOS5.5にffmpeg-phpをインストールする

CentOS 5.5 に ffmpeg-phpをインストールする方法
下記のパッケージをインストール済みと想定しています
  • wget
  • tar
  • make
  • gcc
  • bzip2
  • php
  • php-devel
  • ffmpeg
  • ffmpeg-devel
ffmpeg-phpをダウンロードします
[root@blog.m264.com ~]$ wget http://short.m264.info/ffmpeg-php
解凍しビルドします
[root@blog.m264.com ~]$ tar -xf ./ffmpeg-php-0.6.0.tbz2
[root@blog.m264.com ~]$ cd ./ffmpeg-php-0.6.0
[root@blog.m264.com ~]$ phpize
Configuring for:
PHP Api Version: 20041225
Zend Module Api No: 20050922
Zend Extension Api No: 220051025
[root@blog.m264.com ~]$ ./configure
checking for egrep... grep -E
checking for a sed that does not truncate output... /bin/sed
checking for gcc... gcc
checking for C compiler default output file name... a.out
checking whether the C compiler works... yes
-----

以下略

[root@blog.m264.com ~]$ make
いろいろ出力される

----------------------------------------------------------------------
Libraries have been installed in:
/root/work/wget/ffmpeg-php-0.6.0/modules

If you ever happen to want to link against installed libraries
in a given directory, LIBDIR, you must either use libtool, and
specify the full pathname of the library, or use the `-LLIBDIR'
flag during linking and do at least one of the following:
- add LIBDIR to the `LD_LIBRARY_PATH' environment variable
during execution
- add LIBDIR to the `LD_RUN_PATH' environment variable
during linking
- use the `-Wl,--rpath -Wl,LIBDIR' linker flag
- have your system administrator add LIBDIR to `/etc/ld.so.conf'

See any operating system documentation about shared libraries for
more information, such as the ld(1) and ld.so(8) manual pages.
----------------------------------------------------------------------

Build complete.
(It is safe to ignore warnings about tempnam and tmpnam).
正常にメイクできたのでインストールする
[root@blog.m264.com ~]$ make install
Installing shared extensions: /usr/lib/php/modules/
これでインストール完了です最後にhttpdをリロードします
service httpd reload
httpd を再読み込み中: [ OK ]

0 件のコメント: