hypweb.net
XOOPSマニア  最新情報のRSS(サイト全体)
[ 自宅サーバーWebRing |ID=54 前後5表示乱移動サイト一覧 ]

TOP » UsersWiki » nao-pon » blog » 2010-06-28

RSS of nao-pon/blog
2010 6月 28 (月)
 

ffmpeg-php の configure でハマる [error: ffmpeg headers not found.] anchor.png

動画をPHPで扱いたいと思い、ffmpeg + ffmpeg-php を Web サーバーにインストールしようと思ったところ、ffmpeg-php の configure で、ハマってしまったので、その解決メモ。

Vine 5.1 でパッケージがないか検索したら、"self-build-ffmpeg" があったので、インストール。

ただし、次のように段階的にインストールしないと、依存関係で上手くいかない。

# apt-get install self-build-setup
# apt-get install self-build-xvidcore self-build-faac self-build-lame self-build-x264 self-build-libdca self-build-a52dec self-build-libdvdcss
# apt-get install self-build-ffmpeg self-build-ffmpeg-mh self-build-mplayer self-build-mplayer-codecs

ここまでは、まあググリながらなんとかOK。(ビルドしながらのインストールになるので、めっちゃ時間が掛かった((i:f9d1)))

次に、ffmpeg-php をインストールしようと、

# tar xjf ffmpeg-php-0.6.0.tbz2
# cd ffmpeg-php-0.6.0
# phpize
# ./configure

としたところで問題発生!

checking for ffmpeg support... yes, shared
checking whether to force gd support in ffmpeg-php... no
checking for ffmpeg headers...
configure: error: ffmpeg headers not found. Make sure ffmpeg is compiled as shared libraries using the --enable-shared option

とエラーで止まってしまう。
"checking for ffmpeg support... yes, shared" とある通り shared が有効になっているにも関わらず、"Make sure ffmpeg is compiled as shared libraries using the --enable-shared option" って。

いろいろ、ググッた結果、どうやら header ファイルを見つけられない模様。いろいろ試した結果、ffmpeg の configure の --incdir で指定したディレクトリ直下に *.h ファイルがないとエラーになるようだったので以下を実行。(自分の環境では "--incdir=/usr/include/ffmpeg")

# cp /usr/include/ffmpeg/libavcodec/*.h /usr/include/ffmpeg
# cp /usr/include/ffmpeg/libavdevice/*.h /usr/include/ffmpeg
# cp /usr/include/ffmpeg/libavfilter/*.h /usr/include/ffmpeg
# cp /usr/include/ffmpeg/libavformat/*.h /usr/include/ffmpeg
# cp /usr/include/ffmpeg/libavutil/*.h /usr/include/ffmpeg
# cp /usr/include/ffmpeg/libpostproc/*.h /usr/include/ffmpeg
# cp /usr/include/ffmpeg/libswscale/*.h /usr/include/ffmpeg

これで、無事に configure が通り、

# make
# make-install

で無事にインストール完了。 :ok:

ふうっ。疲れた。



トップ   凍結 差分 バックアップ 複製 名前変更 リロード印刷に適した表示   ページ新規作成 全ページ一覧 単語検索 最新ページの一覧   ヘルプ   最新ページのRSS 1.0 最新ページのRSS 2.0 最新ページのRSS Atom Powered by xpWiki
Counter: 855, today: 1, yesterday: 0
初版日時: 2010-06-28 (月) 22:21:50
最終更新: 2010-06-28 (月) 22:21:50 (JST) (5012d) by nao-pon
このページのTopへ
メインメニュー
ログイン

ユーザー名:


パスワード:





パスワード紛失  |新規登録
最近の更新
オンライン状況
214 人のユーザが現在オンラインです。 (9 人のユーザが UsersWiki を参照しています。)

登録ユーザ: 0
ゲスト: 214

もっと...
サイト情報