ffmpeg latest SVN (shared libs), VLC 0.8.6c: ffmpeg not dete

*nix specific usage questions
bsod_gcc
Blank Cone
Blank Cone
Posts: 11
Joined: 30 Jun 2007 15:31

ffmpeg latest SVN (shared libs), VLC 0.8.6c: ffmpeg not dete

Postby bsod_gcc » 30 Jun 2007 15:58

Hello everyone,
I will be thankful for help with solving my problem. My compiled vlc does not detect the ffmpeg plugin. Please refer to info and screenshots below.

Compiled v0.8.6c (latest release) vlc with wxgtk1 (libwx_gtk-2.6.so.0) and linked against
ffmpeg svn r9451 (20070630).
I have taken note of this warning to disable swscaler in ffmpeg:
viewtopic.php?f=13&t=37684
Even with swscaler disabled, the problem persists.
ffmpeg is not listed as a codec. `vlc --list | grep -i ffmpeg` returns no results:
http://farm2.static.flickr.com/1162/671 ... e5a4_o.gif
There are no abnormal startup messages:
http://farm2.static.flickr.com/1375/672 ... 4296_o.gif
ffmpeg does not appear in VLC preferences:
http://farm2.static.flickr.com/1033/671 ... 09d6_o.gif

ffmpeg svn r9451 (20070630)
(swscaler is disabled by default.)
ffmpeg's configuration:
./configure \
--prefix=/opt/ffmpeg \
--disable-static --enable-shared \
--enable-gpl \
--enable-pp \
--enable-pthreads \
--enable-liba52 \
--enable-libamr-nb --enable-libamr-wb \
--enable-libfaac --enable-libfaad \
--enable-libmp3lame \
--enable-libogg --enable-libtheora --enable-libvorbis \
--enable-libx264 \
--enable-libxvid \
--disable-ipv6 \
--disable-vhook \
--disable-debug
ffmpeg's CFLAGS: -Wl,-rpath,/opt/ffmpeg/lib -Os -ffast-math -fomit-frame-pointer


VLC's configuration:
./configure \
--prefix=/opt/vlc \
--disable-rpath --disable-nls \
--disable-hal \
--enable-optimize-memory \
--disable-optimizations \
--disable-growl --disable-notify \
--enable-live555 \
--disable-gnomevfs \
--enable-faad \
--enable-twolame \
--enable-real \
--enable-realrtsp \
--disable-libmpeg2 \
--enable-theora \
--disable-glx --disable-xinerama --disable-opengl \
--disable-sdl --disable-fribidi --disable-libxml2 \
--disable-alsa --disable-skins2 --disable-visual \
--disable-daap --disable-bonjour --disable-gnutls \
--enable-loader \
--with-x \
--with-mad=/usr \
--with-ffmpeg-mp3lame \
--with-ffmpeg-faac \
--with-ffmpeg-dts \
--with-ffmpeg-vorbis \
--with-ffmpeg-theora \
--with-ffmpeg-ogg \
--with-ffmpeg-zlib \
--with-a52=/usr/local \
VLC's CFLAGS (same as ffmpeg): -Wl,-rpath,/opt/ffmpeg/lib -Os -ffast-math -fomit-frame-pointer
'libffmpeg_plugin.so' seems to be using the rpath, as expected:
(`ls /opt/vlc/lib/vlc/codec` + `ldd libffmpeg_plugin.so`)
http://farm2.static.flickr.com/1265/672 ... 0536_o.gif

So far I cannot find out the source of the problem.
To everybody: Thank you for any help you can give.
Last edited by bsod_gcc on 30 Jun 2007 17:00, edited 10 times in total.

kmf31
Cone that earned his stripes
Cone that earned his stripes
Posts: 308
Joined: 11 Mar 2007 21:47

Re: ffmpeg latest SVN (shared libs), VLC 0.8.6c: ffmpeg not dete

Postby kmf31 » 30 Jun 2007 16:07

You have compiled ffmpeg as dynamic and not static library and you have put it in a non-standard tree: /opt/ffmpeg (with --prefix). Therefore the dynamic ffmpeg libraries are installed in /opt/ffmpeg/lib (which is different from /opt/lib !!). Did you add this folder either in LD_LIBRARY_PATH or in /etc/ld.so.conf ? If not it is obvious that the vlc-plugins don't work because they simply don't find the dynamic ffmpeg-libraries.

bsod_gcc
Blank Cone
Blank Cone
Posts: 11
Joined: 30 Jun 2007 15:31

Re: ffmpeg latest SVN (shared libs), VLC 0.8.6c: ffmpeg not dete

Postby bsod_gcc » 30 Jun 2007 16:11

Very sorry - I am hastily editing the original post in parts. kmf31, could you please refer to the very last screenshot above - the ffmpeg plugin is finding the libraries it needs (thanks to -rpath), but VLC is not detecting it.
Thank you very much for your prompt reply.
Last edited by bsod_gcc on 30 Jun 2007 17:30, edited 1 time in total.

xtophe
Big Cone-huna
Big Cone-huna
Posts: 1209
Joined: 24 Nov 2003 10:12
Location: Bristol, England

Re: ffmpeg latest SVN (shared libs), VLC 0.8.6c: ffmpeg not dete

Postby xtophe » 30 Jun 2007 16:57

Code: Select all

vlc -vvv --color --no-plugins-cache --list |grep ffmpeg
will show you the error (in yellow)
Xtophe

bsod_gcc
Blank Cone
Blank Cone
Posts: 11
Joined: 30 Jun 2007 15:31

Re: ffmpeg latest SVN (shared libs), VLC 0.8.6c: ffmpeg not dete

Postby bsod_gcc » 30 Jun 2007 17:13

Code: Select all

vlc -vvv --color --no-plugins-cache --list |grep ffmpeg
will show you the error (in yellow)
Thank you Xtophe.
I did as you suggested.
ffmpeg does appear in the verbose list. There is a warning about an undefined symbol in 'libquicktime_plugin.so'. I do not know if this is serious enough to prevent other plugins from being detected.
Here is the screenshot:
(`vlc -vvv --color --no-plugins-cache --list |grep ffmpeg`)
http://farm2.static.flickr.com/1070/671 ... 24c3_o.gif
Update: I moved libquicktime_plugin.so away and ran the above command again. The warning disappears, but ffmpeg still does not appear in VLC.
Trying to play an xvid movie results in this:
[00000268] main decoder error: no suitable decoder module for fourcc `XVID'.
VLC probably does not support this sound or video format.


I have 'wmvdmo.dll' in /usr/local/lib/win32.
The 'dmo' codec seems to work. Here is a (small half-size) anime screenshot:
(The video format is wmv9. The audio format is mp3 at 48khz. Both video and audio play fine.)
http://farm2.static.flickr.com/1277/672 ... 6926_o.gif
Last edited by bsod_gcc on 30 Jun 2007 18:11, edited 3 times in total.

kmf31
Cone that earned his stripes
Cone that earned his stripes
Posts: 308
Joined: 11 Mar 2007 21:47

Re: ffmpeg latest SVN (shared libs), VLC 0.8.6c: ffmpeg not dete

Postby kmf31 » 30 Jun 2007 17:46

Despite the rpath try nevertheless to put or add /opt/ffmpeg/lib to LD_LIBRARY_PATH:

export LD_LIBRARY_PATH=/opt/ffmpeg/lib

or:

export LD_LIBRARY_PATH=/opt/ffmpeg/lib:$LD_LIBRARY_PATH

(depending if you already use LD_LIBRARY_PATH).

Unless you have the swscaler problem (which you should not have) I do not see why it does not work.

bsod_gcc
Blank Cone
Blank Cone
Posts: 11
Joined: 30 Jun 2007 15:31

Re: ffmpeg latest SVN (shared libs), VLC 0.8.6c: ffmpeg not dete

Postby bsod_gcc » 30 Jun 2007 18:01

Thank you kmf31.
I have tried as you suggested, but setting LD_LIBRARY_PATH does not solve the problem. I have double-checked this with `echo $LD_LIBRARY_PATH` before running `vlc`.
I still get this:
[00000277] main decoder error: no suitable decoder module for fourcc `XVID'.
Thank you for spending time on my problem.

I think it is likely that linking against a static ffmpeg with '--with-ffmpeg-tree=$srcdir' will work. It seems to me the problem lies somewhere in the dynamic-loading process. Perhaps the ffmpeg libraries or vlc were built with incorrect CFLAGS or LDFLAGS. I do not know exactly what to change.

I have checked the dependencies of VLC's library components recursively:
`find ./ -name "*.so" | while read i ; do ldd "$i" >> /root/report.txt ; done`
It seems all dependencies are satisfied. There is no word 'found' (as in "not found") to be found in 'report.txt'.
Last edited by bsod_gcc on 30 Jun 2007 19:12, edited 2 times in total.

kmf31
Cone that earned his stripes
Cone that earned his stripes
Posts: 308
Joined: 11 Mar 2007 21:47

Re: ffmpeg latest SVN (shared libs), VLC 0.8.6c: ffmpeg not dete

Postby kmf31 » 30 Jun 2007 18:32

In order to test you may try with a static compilation, i.e. you compile ffmpeg in some other source folder (make a copy of the first one or redo a "svn ..." to obtain ffmpeg) but now with static libraries and then you recompile vlc using:
--with-ffmpeg-tree=PATH=/home/toto/other_ffmpeg_source

in that case the ffmpeg-plugins will be linked statically against ffmpeg, which increases their size but this works typically quite well.


Other "speculations":
- may be the latest ffmpeg you took is broken ?? Not very likely but who knows ? There are options in svn to obtain an older version of ffmpeg, says 30 days old ?

- may be some of the ./configure options in ffmpeg you put create the problem (in a similar way as --enable-swscale would). You may try to reduce the codecs for ffmpeg to a minimal set for testing.

But these are only speculations.

bsod_gcc
Blank Cone
Blank Cone
Posts: 11
Joined: 30 Jun 2007 15:31

Re: ffmpeg latest SVN (shared libs), VLC 0.8.6c: ffmpeg not dete

Postby bsod_gcc » 30 Jun 2007 18:42

It is good advice. I will build a minimal testset and post back.

bsod_gcc
Blank Cone
Blank Cone
Posts: 11
Joined: 30 Jun 2007 15:31

Re: ffmpeg latest SVN (shared libs), VLC 0.8.6c: ffmpeg not dete

Postby bsod_gcc » 01 Jul 2007 01:39

Yes, divx/xvid files are able to play now.
ffmpeg now shows up in 'Other Codecs' section of preferences.
ffmpeg is now a builtin rather than a plugin, as this screenshot shows:
(`ls /opt/vlc/lib/vlc/codec`)
http://farm2.static.flickr.com/1053/676 ... bd24_o.gif
This is with a minimum (static) build of ffmpeg and vlc.
I will retest my original build of VLC against shared ffmpeg, only this time I will add '--disable-plugins' to VLC's configuration. Perhaps if VLC loads the ffmpeg libraries directly, it will work.

ffmpeg's configuration:
./configure \
--enable-gpl \
--enable-pp \
--enable-pthreads \
--disable-liba52 \
--disable-libamr-nb --disable-libamr-wb \
--disable-libfaac --disable-libfaad \
--disable-libmp3lame \
--enable-libogg --disable-libtheora --enable-libvorbis \
--disable-libx264 \
--disable-libxvid \
--disable-ipv6 \
--disable-vhook \
--disable-debug \
--disable-encoders \
--disable-muxers
ffmpeg's CFLAGS: -Os -ffast-math -fomit-frame-pointer


vlc's configuration:
./configure \
--prefix=/opt/vlc \
--disable-rpath --disable-nls \
--disable-hal \
--enable-optimize-memory \
--disable-optimizations \
--disable-growl --disable-notify \
--disable-gnomevfs \
--disable-libmpeg2 \
--disable-xvideo \
--disable-glx --disable-xinerama --disable-opengl \
--disable-sdl --disable-fribidi --disable-libxml2 \
--disable-alsa --disable-skins2 --disable-visual \
--disable-daap --disable-bonjour --disable-gnutls \
--disable-loader \
--with-x \
--with-mad=/usr \
--with-ffmpeg-tree=/mnt/hda13/src/static/ffmpeg \
--with-ffmpeg-vorbis \
--with-ffmpeg-zlib
VLC's CFLAGS: -Os -ffast-math -fomit-frame-pointer

bsod_gcc
Blank Cone
Blank Cone
Posts: 11
Joined: 30 Jun 2007 15:31

Re: ffmpeg latest SVN (shared libs), VLC 0.8.6c: ffmpeg not dete

Postby bsod_gcc » 01 Jul 2007 04:48

'--disable-plugins' did not work. It completely broke the build.
However, adding '--enable-static --disable-shared' to VLC's configuration gives me a working build.
VLC now works with (shared) ffmpeg!
Unfortunately, I am new to VLC and do not know exactly what difference '--enable-static --disable-shared' makes. I cannot explain how it worked.


Return to “VLC media player for Linux and friends Troubleshooting”

Who is online

Users browsing this forum: No registered users and 11 guests