FORUMS: list search recent posts

FFMPEG segmentation fault in libavcodec and invalid size of /lib/libavcodec.so.52.108.0

COW Forums : FFmpeg

<< PREVIOUS   •   VIEW ALL   •   PRINT   •   NEXT >>
Dmitry Iasd
FFMPEG segmentation fault in libavcodec and invalid size of /lib/libavcodec.so.52.108.0
on Mar 12, 2011 at 10:15:09 am

Hi!

I'm trying to compile ffmpeg from source code on Debian Linux. I have a clean version of Debian Lenny (5.08) (installed from scratch) and a VMWare snapshot with Debian Lenny (5.08) snapshot.

I use the same instructions (provided below) to compile FFMPEG on both Debian instances. Here are these instructions:

wget http://www.debian-multimedia.org/pool/main/d/debian-multimedia-keyring/debi...
dpkg -i debian-multimedia-keyring_2010.12.26_all.deb

apt-get install checkinstall yasm git-core subversion

apt-get build-dep ffmpeg

apt-get remove libx264-dev
wget ftp://ftp.videolan.org/pub/videolan/x264/snapshots/x264-snapshot-20100926-2...
tar xjvf x264-snapshot-20100926-2245.tar.bz2
cd x264-snapshot-20100926-2245
./configure --enable-pic --prefix=/usr
make
checkinstall --pkgname=x264 --pkgversion "snapshot-20100926" --backup=no --default
cd ..

apt-get remove libfaac-dev
apt-get remove libfaac0
wget http://downloads.sourceforge.net/faac/faac-1.28.tar.bz2
tar xjvf faac-1.28.tar.bz2
cd faac-1.28
./configure --prefix=/usr
make
checkinstall --pkgname=faac -pkgversion "1.28.svn`date +%Y%m%d`" --backup=no --default
cd ..

apt-get remove libtheora-dev
apt-get remove libtheora0
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 --prefix=/usr
make
checkinstall --pkgname=libtheora --pkgversion "1.1.1" --backup=no --default
cd ..

apt-get remove libvorbis-dev
apt-get remove libvorbis0a # The system will offer to delete some other packages, agree
wget http://downloads.xiph.org/releases/vorbis/libvorbis-1.3.1.tar.gz
tar zxvf libvorbis-1.3.1.tar.gz
cd libvorbis-1.3.1
./configure --prefix=/usr
make
checkinstall --pkgname=libvorbis --pkgversion "1.3.1" --backup=no --default
cd ..

apt-get remove libmp3lame-dev
apt-get remove libmp3lame0
wget http://downloads.sourceforge.net/project/lame/lame/3.98.4/lame-3.98.4.tar.g...
tar xzvf lame-3.98.4.tar.gz
cd lame-3.98.4
./configure --enable-nasm --enable-shared --prefix=/usr
make
checkinstall --pkgname=lame-ffmpeg --pkgversion="3.98.4" --backup=no --default --deldoc=yes
cd ..

git clone git://review.webmproject.org/libvpx.git
cd libvpx
./configure --enable-pic --enable-vp8 --enable-postproc --enable-runtime-cpu-detect --prefix=/usr
make
checkinstall --pkgname=libvpx --pkgversion="`date +%Y%m%d%H%M`-git" --backup=no --default --deldoc=yes
cd ..

apt-get install libopenjpeg-dev

svn checkout svn://svn.ffmpeg.org/soc/libavfilter -r5946 # THIS IS FFMPEG -r26400
cd libavfilter
./checkout.sh # Checks out the most current version of FFMPEG that works with libavfilter.
cd ffmpeg
./configure --prefix=/usr --libdir=/lib --shlibdir=/lib --bindir=/bin --incdir=/include/ffmpeg --enable-shared --enable-gpl --enable-version3 --enable-nonfree --disable-ffplay --disable-ffprobe --disable-ffserver --enable-postproc --enable-pthreads --disable-network --enable-runtime-cpudetect --enable-hardcoded-tables --enable-memalign-hack --disable-devices --enable-libfaac --enable-libgsm --enable-libmp3lame --enable-libopenjpeg --enable-libx264 --enable-pic --enable-avfilter --enable-libvpx --enable-libvorbis --enable-libtheora
make
checkinstall --pkgname=ffmpeg --pkgversion="`date +%Y%m%d%H%M`" --backup=no --default --deldoc=yes
cd ./tools
gcc qt-faststart.c -o /bin/qt-faststart
cd ../../..

mkdir segmenter
cd segmenter
wget http://svn.assembla.com/svn/legend/segmenter/segmenter.c
apt-get update
apt-get install libbz2-dev
gcc -Wall -I../libavfilter/ffmpeg -g segmenter.c -o segmenter -lavformat -lavcodec -lavutil -lbz2 -lm -lz -lfaac -lmp3lame -lx264
cp segmenter /usr/bin/segmenter
cd ..


After compilation of FFMPEG on my clean Debian, I see that the size of the library /lib/libavcodec.so.52.108.0 is less than the size of the library I get when compiling on the VMWare instance Debian. And this results in the following error:

[ 2707.022186] ffmpeg[7077] general protection ip:b7043028 sp:bf8d8318 error:0 in libavcodec.so.52.108.0[b6aca000+7f8000]


when I try to run this command:

/bin/ffmpeg -i "/var/tmp/scooter-race.flv" -threads 0 -f webm -s 640x360 -vcodec libvpx -vb 1024k -g 120 -qmax 50 -qmin 10 -acodec libvorbis -ab 128k -ac 2 -ar 44100 -psnr -y /var/tmp/xcodeout/tempOutputFile


However, when I copy that library /lib/libavcodec.so.52.108.0 from VMWare Debian machine to my clean Debian, ffmpeg works without segmentation faults.

Can anyone advice, why these libraries can be different when I compile on different machines following the same steps? Can this be caused by some gcc configuration (in its global configuration files if there are any) or smth like this?

Thanks!


Return to posts index

<< PREVIOUS   •   VIEW ALL   •   PRINT   •   NEXT >>
© 2017 CreativeCOW.net All Rights Reserved
[TOP]