Symbol av_destruct_packet, version LIBAVFORMAT_52 not defined in file libavformat.so.52 with link time reference

Bug #573805 reported by Vincenzo Mazzotta
12
This bug affects 2 people
Affects Status Importance Assigned to Milestone
ffmpeg (Ubuntu)
Fix Released
Undecided
Unassigned

Bug Description

Binary package hint: ffmpeg

I want to merge CD1.avi and CD2.avi and remux output by ffmpeg.
The command that I execute:

> cat CD1.avi CD2.avi | ffmpeg -i -acodec copy -vcodec copy Agora.2009.DVDRip.2.avi
> ffmpeg: relocation error: ffmpeg: symbol av_destruct_packet, version LIBAVFORMAT_52 not defined in file libavformat.so.52 with link time reference

I suppose that the problem is av_destruct_packet variable that not exists or is trunked.

Somebody can solve it?

Kind regards
Vincenzo

Revision history for this message
Reinhard Tartler (siretart) wrote : Re: [Bug 573805] [NEW] Symbol av_destruct_packet, version LIBAVFORMAT_52 not defined in file libavformat.so.52 with link time reference

On Sun, May 02, 2010 at 18:38:23 (CEST), Vincenzo Mazzotta wrote:

> Public bug reported:
>
> Binary package hint: ffmpeg
>
> I want to merge CD1.avi and CD2.avi and remux output by ffmpeg.
> The command that I execute:
>
>> cat CD1.avi CD2.avi | ffmpeg -i -acodec copy -vcodec copy Agora.2009.DVDRip.2.avi
>> ffmpeg: relocation error: ffmpeg: symbol av_destruct_packet, version LIBAVFORMAT_52 not defined in file libavformat.so.52 with link time reference
>
>
> I suppose that the problem is av_destruct_packet variable that not exists or is trunked.

yes, it is not found because you have replaced your system libavformat
library with a broken copy.

> Somebody can solve it?

yes, reinstall the ubuntu libavformat copy.

--
Gruesse/greetings,
Reinhard Tartler, KeyID 945348A4

Revision history for this message
Vincenzo Mazzotta (vincenzo-mazzotta-it) wrote :

I reinstalled libavformat52 version 4:0.5.1-1ubuntu1 and problem is not resolved.

Same output .

Some advice to solve this error?

Thks

Revision history for this message
Reinhard Tartler (siretart) wrote : Re: [Bug 573805] Re: Symbol av_destruct_packet, version LIBAVFORMAT_52 not defined in file libavformat.so.52 with link time reference

On Sun, May 02, 2010 at 20:06:55 (CEST), Vincenzo Mazzotta wrote:

> I reinstalled libavformat52 version 4:0.5.1-1ubuntu1 and problem is not
> resolved.
>
> Same output .
>
> Some advice to solve this error?

please ensure this for all packages built from the ffmpeg source
package. I.e. please post every version from the following packages:

ffmpeg
libavcodec*
libavformat*
libavutil*

--
Gruesse/greetings,
Reinhard Tartler, KeyID 945348A4

Revision history for this message
Vincenzo Mazzotta (vincenzo-mazzotta-it) wrote :

I have ubuntu 10.4 updated

By synaptic the packet version is:

ffmpeg 4:0.5.1.-1ubuntu1
libavcodec52 4:0.5.1-1ubuntu1
libavformat52 4:0.5.1-1ubuntu1
libavutil49 4:0.5.1-1ubuntu1

Revision history for this message
Vincenzo Mazzotta (vincenzo-mazzotta-it) wrote :

Reply to previous comment:

When I reinstalled libavformat52 version 4:0.5.1-1ubuntu1 no error in synaptic

Revision history for this message
Vincenzo Mazzotta (vincenzo-mazzotta-it) wrote :

Nobody have a solution to this problem?

Kind Regards
Vincenzo

Revision history for this message
Reinhard Tartler (siretart) wrote :

On Mon, May 03, 2010 at 22:48:42 (CEST), Vincenzo Mazzotta wrote:

> Nobody have a solution to this problem?

the solution is to replace your broken libavformat52 package with the
ubuntu one.

--
Gruesse/greetings,
Reinhard Tartler, KeyID 945348A4

Revision history for this message
Vincenzo Mazzotta (vincenzo-mazzotta-it) wrote :

I reinstalled more times this packet without solve the problem.

From Terminal go out always same error.

I found by google an old message sent from you to another user about same problem that you can find at these link
http://lists.mplayerhq.hu/pipermail/ffmpeg-devel/2009-December/079241.html
http://archives.free.net.ph/message/20091202.221119.bd1100c6.pl.html
http://article.gmane.org/gmane.comp.video.ffmpeg.devel/100328.

For this reason I suppose that in ubuntu distribution the ffmpeg version is old respect libraries as libavformat52.

Please somebody can tell me why have nobody tested ffmpeg application version in ubuntu 9.10, 10.04 and 10.4 canonical source packet?

This error appear as a Microsoft solution that not solve anything and they told to users that this isn't an error.

Please somebody explain to ubuntu users that the bug exist and define a procedure to install ffmpeg and all libraries correctly. For example using svn with last version of ffmpeg and not by canonical source packets.

Kind Regards
Vincenzo

Revision history for this message
Vincenzo Mazzotta (vincenzo-mazzotta-it) wrote :

My system is Ubuntu Lucid 10.4 64bit and all work fine. The only application that have errors is ffmpeg with this library error.

If somebody have a solution please add to this bug.

Please don't close bug because ubuntu community can't solve this problem.

Add this to explain my previous comment that can be interpreta as an attack:

The work of community in the development of ubuntu and all debian packages was considered that many of us feel mistreated by society who want to close the technology behind an idea of intellectual property.

The birth of open source and just that talk openly know that if there are errors in the packages all of us who are helping to identify them, label them in a bug list, seek solutions, and discuss the best way to apply the fix bugs in a shared idea.

Thanks to all and continue to speak clearly failing in the face without feeling each of us made its way because the goal of community is identical.

Kind Regards
Vincenzo

Revision history for this message
Lionel Le Folgoc (mrpouit) wrote :

> Please somebody can tell me why have nobody tested ffmpeg application
> version in ubuntu 9.10, 10.04 and 10.4 canonical source packet?

It works, with the packages from the archive (not random ppas), as already written above...

You should check that all your ffmpeg packages are the official ones (you can find a list e.g. on http://packages.ubuntu.com/source/lucid/ffmpeg).

Revision history for this message
Vincenzo Mazzotta (vincenzo-mazzotta-it) wrote :

I installed all packets by ubuntu synaptic and I before execute update manager.

Strange that somebody tell me that work fine.

Is it possible that when I installed ffmpeg not all sorce packet was updated?

Very strange.

I will remove completly and reinstall all ffmpeg, all libraries, and winff by synaptic. If it will not work, it will exist a solution?

Ok next message I will write what's happened when remove definitly all and reinstall all.

Kind Regards
Vincenzo

Revision history for this message
Reinhard Tartler (siretart) wrote :

On Thu, May 06, 2010 at 11:06:35 (CEST), Vincenzo Mazzotta wrote:

> Is it possible that when I installed ffmpeg not all sorce packet was
> updated?

of course. apt will always install the package with the highest
version. It will not prefer packages from ubuntu just because they are
from ubuntu. 3rd party packages always have an higher version number
than in ubuntu in order to be installable at all!

--
Gruesse/greetings,
Reinhard Tartler, KeyID 945348A4

Revision history for this message
Lionel Le Folgoc (mrpouit) wrote :

You should also check that you haven't built a version of the libs (from svn or another source) and installed them in /usr/local/lib/.

Revision history for this message
Vincenzo Mazzotta (vincenzo-mazzotta-it) wrote :

Now I'm sure.

In my laptop where the problem go out error isn't resolved.

Yesterday I upgrade my deskytop to Lucid 10.04.

After update manager I installed by synaptic ffmpeg and winff with the same command go out same error.

It's clearly that the error depends by the ubuntu packet.

Now I'm sure that this packed was not tested before to add ubuntu lucid distribution. Test this command after add by synaptic ffmpeg and winff.

So If somebody have a solution, please he talk about it.

If somebody must tell stupid thing about, Are you sure that you didn't use a cvs to make the installation, please go away because I explained it yet.

Kind Regards
Vincenzo

Revision history for this message
llogan (loul) wrote :

Vincenzo,

You're command is not valid. You forgot a "-" after the "-i". It should look like:
cat CD1.avi CD2.avi | ffmpeg -i - -acodec copy -vcodec copy Agora.2009.DVDRip.2.avi

Without the "-" you probably should have received this message:
-acodec: No such file or directory

If you simply copied your command incorrectly and your original command did include the "-" then please show your correct ffmpeg command and the complete ffmpeg output.

Revision history for this message
Vincenzo Mazzotta (vincenzo-mazzotta-it) wrote :

Is not that the error because error go out if you add - or not:

> cat CD1.avi CD2.avi | ffmpeg -i -acodec copy -vcodec copy Agora.2009.DVDRip.2.avi
ffmpeg: relocation error: ffmpeg: symbol av_destruct_packet, version LIBAVFORMAT_52 not defined in file libavformat.so.52 with link time reference

> cat CD1.avi CD2.avi | ffmpeg -i - -acodec copy -vcodec copy Agora.2009.DVDRip.2.avi
ffmpeg: relocation error: ffmpeg: symbol av_destruct_packet, version LIBAVFORMAT_52 not defined in file libavformat.so.52 with link time reference

Revision history for this message
Vincenzo Mazzotta (vincenzo-mazzotta-it) wrote :

But some developer of ffmpeg not exist in launchpad comunity to solve this problem or to talk about it?

Revision history for this message
llogan (loul) wrote :

Is this the full, complete, and uncut output that FFmpeg gives you?

Revision history for this message
Vincenzo Mazzotta (vincenzo-mazzotta-it) wrote :

yes.

Now for example i want convert an amr file to mp3

> ffmpeg -i REC_0001.AMR -ar 22050 REC_0001.mp3
ffmpeg: relocation error: ffmpeg: symbol av_destruct_packet, version LIBAVFORMAT_52 not defined in file libavformat.so.52 with link time reference

Same error

Incredible it isn't work.

A year ago in my company laptop I configured ffmpeg and winff without problem but by svn and makefile.

Because I'm sure that if I download from svn source code and make it work fine as I have done in past, but If I install packets from synaptic in ubuntu then ffmpeg and winff don't work.

So I think that to solve this problem, I will be patient and:

remove by synaptic ffmpeg and winff
download source code
make
Use ffmpeg.

No solution founded to Ubuntu packets: ffmpeg winff

Thank to all for support, but after 8 days it's anormal don't find a person that can help in this problem over a web application finalized to solve bugs.

Kind Regards
Vincenzo

Revision history for this message
Reinhard Tartler (siretart) wrote :

On Sun, May 09, 2010 at 04:43:02 (CEST), Vincenzo Mazzotta wrote:

>> ffmpeg -i REC_0001.AMR -ar 22050 REC_0001.mp3
> ffmpeg: relocation error: ffmpeg: symbol av_destruct_packet, version LIBAVFORMAT_52 not defined in file libavformat.so.52 with link time reference
>
> Same error
>
> Incredible it isn't work.

this doesn't happen if you use the libavformat52 package as provided by
ubuntu. You can check for this symbol with this command:

>> objdump -T /usr/lib/libavformat.so.52 | grep -E 'av_destruct_packet$'
0001a950 g DF .text 00000026 LIBAVFORMAT_52 av_destruct_packet

If you are getting an output that does not include the version tag
LIBAVFORMAT_52, then you are using a broken 3rd party version of the
libavformat package.

--
Gruesse/greetings,
Reinhard Tartler, KeyID 945348A4

Revision history for this message
Reinhard Tartler (siretart) wrote :

On Sun, May 09, 2010 at 04:43:02 (CEST), Vincenzo Mazzotta wrote:

> remove by synaptic ffmpeg and winff

removing ffmpeg is not enough. you also need to remove your copy of the
ffmpeg package.

> download source code
> make
> Use ffmpeg.

which uses a totally different configuration than we use in ubuntu.

--
Gruesse/greetings,
Reinhard Tartler, KeyID 945348A4

Revision history for this message
Reinhard Tartler (siretart) wrote :

On Sun, May 09, 2010 at 09:48:40 (CEST), Reinhard Tartler wrote:

> On Sun, May 09, 2010 at 04:43:02 (CEST), Vincenzo Mazzotta wrote:
>
>> remove by synaptic ffmpeg and winff
>
> removing ffmpeg is not enough. you also need to remove your copy of the
> ffmpeg package.

sorry, that should read:

"removing the ffmpeg package is not enough. you also need to remove your
copy of the *libavformat52* package.

--
Gruesse/greetings,
Reinhard Tartler, KeyID 945348A4

Revision history for this message
Vincenzo Mazzotta (vincenzo-mazzotta-it) wrote :

my output is follow:

objdump -T /usr/lib/libavformat.so.52 | grep -E 'av_destruct_packet$'
0000000000000000 DF *UND* 0000000000000000 LIBAVCODEC_52 av_destruct_packet

Ok I will make ffmpeg by source code by make file.

I know that synaptic and update manager don't work for ffmpeg application but is added to distribution without test it.

Kind Regards
Vincenzo

Revision history for this message
Vincenzo Mazzotta (vincenzo-mazzotta-it) wrote :

If I remove libavformat52 in synaptic go out that I need to remove:

gstreamer0.10-ffmpeg --> it's OK
libavdevice52 --> it's OK

vlc --> It's KO
vlc-nox --> It's KO
vlc-plugin-pulse --> It's KO

So If I remove libavformat52 I need to remove vlc my default multimedia player. It's normal in Ubuntu?

Kind Regards
Vincenzo

Revision history for this message
Lionel Le Folgoc (mrpouit) wrote :

Did you check that you don't have another version installed/built manually in /usr/local, or somewhere else in your PATH? (I already asked, but you didn't reply).

> I know that synaptic and update manager don't work for ffmpeg application but is added to distribution without test it.

Well, it works perfectly fine here on lucid 64bits, so obviously, it has been tested… (and maybe you should stop making such unverified statements).

> So If I remove libavformat52 I need to remove vlc my default multimedia player. It's normal in Ubuntu?

Yes, because vlc depends on it.

Revision history for this message
Vincenzo Mazzotta (vincenzo-mazzotta-it) wrote :

SOLVED ! ! !

The FINAL SOLUTION that work on my laptop and desktop in Ubuntu 10.4 lucid is follow and allow to use vlc and ffmpeg with or without winff is follow execute commands:

Get the Dependencies
1. Uninstall x264, libx264-dev, and ffmpeg if they are already installed. Open a terminal and run the following:

sudo apt-get remove ffmpeg x264 libx264-dev

2. Next, get all of the packages you will need to install FFmpeg and x264 (you may need to enable the universe and multiverse repositories):

sudo apt-get update
sudo apt-get install build-essential subversion git-core checkinstall yasm texi2html libfaac-dev libfaad-dev libmp3lame-dev libopencore-amrnb-dev libopencore-amrwb-dev libsdl1.2-dev libx11-dev libxfixes-dev libxvidcore-dev zlib1g-dev

Install x264
3. Get the most current source files from the official x264 git repository, compile, and install. You can run "./configure --help" to see what features you can enable/disable. Daily source tarballs are also available, and forum member Bachstelze provides x264 Ubuntu packages for anyone who doesn't want to compile.

cd
git clone git://git.videolan.org/x264.git
cd x264
./configure
make
sudo checkinstall --pkgname=x264 --pkgversion "1:0.svn`date +%Y%m%d`+`git rev-list HEAD -n 1 | head -c 7`" --backup=no --default

Install libtheora (optional)
4. This is used to encode to Theora, the video type usually found in OGG/OGV files. The repository libtheora is too old, so it must be compiled. I recommend skipping this step and omitting --enable-libtheora in step 5 if you don't plan on encoding Theora video:

sudo apt-get install libogg-dev
cd
wget http://downloads.xiph.org/releases/theora/libtheora-1.1.1.tar.gz
tar xzvf libtheora-1.1.1.tar.gz
cd libtheora-1.1.1
./configure --disable-shared
make
sudo checkinstall --pkgname=libtheora --pkgversion "1.1.1" --backup=no --default

Install FFmpeg
5. Get the most current source files from the official FFmpeg SVN, compile, and install. Run "./configure --help" to see what features you can enable/disable. Nightly FFmpeg snapshots are also available.
cd
svn checkout svn://svn.ffmpeg.org/ffmpeg/trunk ffmpeg
cd ffmpeg
./configure --enable-gpl --enable-version3 --enable-nonfree --enable-postproc --enable-pthreads --enable-libfaac --enable-libfaad --enable-libmp3lame --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libtheora --enable-libx264 --enable-libxvid --enable-x11grab
make
sudo checkinstall --pkgname=ffmpeg --pkgversion "4:0.5+svn`date +%Y%m%d`" --backup=no --default
hash x264 ffmpeg

That's it for installation. You can keep the ~/x264 and ~/ffmpeg directories if you later want to update the source files to a new revision. See "Updating Your Installation" on the first page of this guide for more details.

Now head back to the FFmpeg guide (http://ubuntuforums.org/showthread.php?t=786095) for usage instructions and more.

Reverting Changes Made at now
To remove FFmpeg/x264 and other packages added at now:

sudo apt-get remove x264 ffmpeg build-essential subversion git-core checkinstall yasm texi2html libfaac-dev libfaad-dev libmp3lame-dev libsdl1.2-dev libtheora libx11-dev libxfixes-dev libxvidcore-dev zlib1g-dev

Revision history for this message
Reinhard Tartler (siretart) wrote :

closed on submitters request.

Changed in ffmpeg (Ubuntu):
status: New → Fix Released
Revision history for this message
smerz (daniel-genis) wrote :

Having followed the solution from Vincenzo Mazzotta it worked for me.

But the issue just comes back. How do i prevent it from returning?

I am not sure why it came back, I think it's because the package manager automatically installs the repository ffmpeg.
How do I prevent that from happening?

Kind regards,

Daniel

Revision history for this message
Reinhard Tartler (siretart) wrote :

On Fri, Jun 11, 2010 at 03:10:40 (CEST), smerz wrote:

> Having followed the solution from Vincenzo Mazzotta it worked for me.
>
> But the issue just comes back. How do i prevent it from returning?

That is not a solution for the distro package, but for a single
installation, because it replaces the system ffmpeg with a newer copy
and recompiles the now broken applications.

> I am not sure why it came back, I think it's because the package
> manager automatically installs the repository ffmpeg. How do I
> prevent that from happening?

The symptom now really appears with the system ffmpeg package in
maverick, because it was updated to a pre 0.6 snapshot. I've noticed it
myself and raised it upstream here:

http://comments.gmane.org/gmane.comp.video.ffmpeg.devel/110943

--
Gruesse/greetings,
Reinhard Tartler, KeyID 945348A4

Revision history for this message
Apteryx (maxco) wrote :

I had similar problems on my Ubuntu 10.04 box. I could not get MPlayer (or gnome-mplayer & gecko-mediaplayer) to play any movie.

I found the error when trying to start mplayer in a terminal. I'd get: mplayer: relocation error: mplayer: symbol codec_wav_tags, version LIBAVFORMAT_52 not defined in file libavformat.so.52 with link time reference or mplayer: relocation error: mplayer: symbol rgb24toyv12, version LIBSWSCALE_0 not defined in file libswscale.so.0 with link time reference.

Clearing all foreign packages installed by ppas or other sources (guilty packages were libavformat52 and libswscale0) then reinstalling mplayer solved the problem. A good way to spot these is to open Synaptic and select "Origin" as filter. There you can see all the packages installed from remote sources.

(Hoping this will help others too!)

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.