Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 108810 - mjpegtools 1.8.0 - jpeg2yuv segfaults always
Summary: mjpegtools 1.8.0 - jpeg2yuv segfaults always
Status: RESOLVED INVALID
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: x86 Linux
: High minor
Assignee: Television related Applications in Gentoo's Portage
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2005-10-10 20:03 UTC by Kenton Groombridge
Modified: 2005-12-25 22:33 UTC (History)
2 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Kenton Groombridge 2005-10-10 20:03:53 UTC
Running:

jpeg2yuv -n 50 -I p -f 29.97 -j background.jpg

causes an immediate segfault.  I am using a jpeg file that use to work fine with
the above command.  I am using mjpegtools 1.8.0.  I thought the newer version
was causing the problem so I backed off to 1.6.2-r4 and have the same problem. 
This was working a couple months ago.  1.8.0 isn't the problem since I regressed
to the stable version and had the exact same problem.

I ran:

emerge -ev mjpegtools thinking a dependent package was causing the problem. 
Rebooted, and tried again.  I tried several other jpeg files that I have
successfully encoded before and I always immediately get a segfault.

I have a feeling it is something on my end, but a day of searching and trial and
error has come up emptly.

A jpeg file that causes a segfault is located here:

http://webpages.charter.net/kgroombr/background.jpg

Reproducible: Always
Steps to Reproduce:
1.  Run:  jpeg2yuv -n 50 -I p -f 29.97 -j background.jpg



Actual Results:  
segfault

Expected Results:  
Output redirected to mpeg2enc to create screen for a dvd

I am converting the jpeg files to png and using the png2yuv and all is working fine.

emerge --info
Portage 2.0.53_rc5 (default-linux/x86/2005.0, gcc-3.4.4, glibc-2.3.5-r2,
2.6.13-ck7 i686)
=================================================================
System uname: 2.6.13-ck7 i686 Unknown CPU Typ
Gentoo Base System version 1.12.0_pre8
dev-lang/python:     2.4.2
sys-apps/sandbox:    1.2.13
sys-devel/autoconf:  2.13, 2.59-r7
sys-devel/automake:  1.4_p6, 1.5, 1.6.3, 1.7.9-r1, 1.8.5-r3, 1.9.6-r1
sys-devel/binutils:  2.16.1
sys-devel/libtool:   1.5.20
virtual/os-headers:  2.6.11-r2
ACCEPT_KEYWORDS="x86 ~x86"
AUTOCLEAN="yes"
CBUILD="i686-pc-linux-gnu"
CFLAGS="-O2 -pipe -march=athlon-xp -fomit-frame-pointer -mmmx -msse -m3dnow
-mfpmath=sse"
CHOST="i686-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/kde/2/share/config /usr/kde/3.4/env
/usr/kde/3.4/share/config /usr/kde/3.4/shutdown /usr/kde/3/share/config
/usr/lib/X11/xkb /usr/share/config /var/qmail/control"
CONFIG_PROTECT_MASK="/etc/gconf /etc/terminfo /etc/env.d"
CXXFLAGS="-O2 -pipe -march=athlon-xp -fomit-frame-pointer -mmmx -msse -m3dnow
-mfpmath=sse"
DISTDIR="/usr/portage/distfiles"
FEATURES="autoconfig distlocks sandbox sfperms strict"
GENTOO_MIRRORS="http://mirror.datapipe.net/gentoo
http://gentoo.chem.wisc.edu/gentoo/ http://gentoo.osuosl.org/
http://mirror.phy.olemiss.edu/mirror/gentoo
http://gentoo.mirrors.easynews.com/linux/gentoo/"
MAKEOPTS="-j2"
PKGDIR="/usr/portage/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY="/usr/local/portage"
SYNC="rsync://rsync.gentoo.org/gentoo-portage"
USE="x86 3dnow 3dnowext S3TC X a52 aac acpi acpi4linux alsa apache2 apm arts avi
berkdb bitmap-fonts bzip2 cddb cdr crypt cups curl dga divx4linux dvd dvdr
dvdread eds emboss emoticon encode faad fam ffmpeg flac foomaticdb fortran
freetype gdbm gif gimp gpm gstreamer gtk2 ieee1394 imagemagick imlib ipv6
joystick jpeg kde libg++ libwww live mad mikmod mjpeg mmx mmxext motif mozsvg
mp3 mpeg mpeg4 mplayer nas ncurses network nls nomalloccheck nptl nptlonly
nvidia ogg oggvorbis openal opengl opens pam pdflib perl png python qt quicktime
readline scanner sdl slang snmp spell sse ssl svg svga tcltk tcpd tiff transcode
truetype truetype-fonts type1 type1-fonts unicode usb v4l2 vorbis win32codecs
wmf xine xml2 xmms xpm xv xvid zlib zvbi userland_GNU kernel_linux elibc_glibc"
Unset:  ASFLAGS, CTARGET, LANG, LC_ALL, LDFLAGS, LINGUAS
Comment 1 José Romildo Malaquias 2005-10-14 02:54:21 UTC
I have tried the command

  jpeg2yuv -n 50 -I p -f 29.97 -j background.jpg > background.yuv4mpeg

on your image and it does work for me. I have mjpegtools-1.8.0 on amd64.
Comment 2 mds32h 2005-10-21 14:34:28 UTC
I have the same problem executing the same command on the same file.

Moreover I am having systematic segfaults with several other commands involving
ffmpeg or mpeg2enc on movies in dv format.

e.g.

transcode -x dv,dv -i fred-001.dv -y ffmpeg -F 8 -o fred-001-video -m
fred-001-audio -N 0x2000 -E 48000 -w 7500 -b 256 --export_prof dvd-pal
--export_asr 2 --encode_fields b

or (generated by qDvdauthor):

jpeg2yuv -n 50 -I p -f 25 -j "+BACKGROUND_FULL_NAME+" | mpeg2enc -n p -f 8 -o
"+TEMP_PATH+/+MENU_NAME+/menu.m2v"

I had these segfaults just after an emerge -u world, four days ago. The same
commands on the same movies were ok before.

# emerge --info

Portage 2.0.53_rc5 (default-linux/x86/2005.0, gcc-3.3.5, glibc-2.3.5-r2,
2.6.13-gentoo-r4 i686)
=================================================================
System uname: 2.6.13-gentoo-r4 i686 Intel(R) Pentium(R) 4 CPU 3.00GHz
Gentoo Base System version 1.12.0_pre9
dev-lang/python:     2.3.5, 2.4.2
sys-apps/sandbox:    1.2.13
sys-devel/autoconf:  2.13, 2.59-r7
sys-devel/automake:  1.4_p6, 1.5, 1.6.3, 1.7.9-r1, 1.8.5-r3, 1.9.6-r1
sys-devel/binutils:  2.16.1
sys-devel/libtool:   1.5.20
virtual/os-headers:  2.6.11-r2
ACCEPT_KEYWORDS="x86 ~x86"
AUTOCLEAN="yes"
CBUILD="i686-pc-linux-gnu"
CFLAGS="-O2 -march=i686 -fomit-frame-pointer -pipe"
CHOST="i686-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/kde/2/share/config /usr/kde/3.4/env
/usr/kde/3.4/share/config /usr/kde/3.4/shutdown /usr/kde/3/share/config
/usr/lib/X11/xkb /usr/share/config /var/qmail/control"
CONFIG_PROTECT_MASK="/etc/gconf /etc/terminfo /etc/env.d"
CXXFLAGS="-O2 -march=i686 -fomit-frame-pointer -pipe"
DISTDIR="/usr/portage/distfiles"
FEATURES="autoconfig distlocks sandbox sfperms strict"
GENTOO_MIRRORS="http://www.die.unipd.it/pub/Linux/distributions/gentoo-sources/
http://ftp.easynet.nl/mirror/gentoo/ http://mirror.switch.ch/mirror/gentoo/"
MAKEOPTS="-j3"
PKGDIR="/usr/portage/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY="/usr/local/portage"
SYNC="rsync://rsync.gentoo.org/gentoo-portage"
USE="x86 X aac alsa apm arts avi bash-completion berkdb bitmap-fonts bonobo cdr
crypt cups curl dv dvd dvdread eds emboss encode esd fam flac foomaticdb fortran
gdbm gif gnome gpm gstreamer gtk gtk2 gtkhtml imagemagick imlib ipv6 java jpeg
kde lame libfame libg++ libwww mad mikmod mmx motif mp3 mpeg ncurses nls ogg
oggvorbis opengl oss pam pdflib perl png python qt quicktime readline samba
scanner sdl spell ssl svga symlink tcpd tiff truetype truetype-fonts type1-fonts
usb vorbis xine xml xml2 xmms xv zlib userland_GNU kernel_linux elibc_glibc"
Unset:  ASFLAGS, CTARGET, LANG, LC_ALL, LDFLAGS, LINGUAS
Comment 3 mds32h 2005-10-21 16:06:40 UTC
Just to give some more detail about my previous comment. When I run the
transcode command into gdb and perform a backtrace I have the following:

Program received signal SIGINT, Interrupt.
[Switching to Thread 16386 (LWP 31808)]
0xb7e329b0 in pthread_handle_sigcancel () from /lib/libpthread.so.0
(gdb) backtrace
#0  0xb7e329b0 in pthread_handle_sigcancel () from /lib/libpthread.so.0
#1  <signal handler called>
#2  0xb7d0310b in sigsuspend () from /lib/libc.so.6
#3  0xb7e33435 in sigwait () from /lib/libpthread.so.0
#4  0x08050c00 in signal_thread ()
#5  0xb7ded580 in __check_rhosts_file () from /lib/libc.so.6
#6  0xb7e38ff4 in ?? () from /lib/libpthread.so.0
#7  0x00000000 in ?? ()
#8  0xb7e38ff4 in ?? () from /lib/libpthread.so.0
#9  0x00000000 in ?? ()
#10 0xb7e3014d in pthread_start_thread () from /lib/libpthread.so.0
#11 0xb7e302f2 in pthread_start_thread_event () from /lib/libpthread.so.0
#12 0xb7d9087a in clone () from /lib/libc.so.6

I'm running an: Intel(R) Pentium(R) 4 CPU 3.00GHz stepping 09.
Comment 4 mike daugird 2005-11-01 14:10:48 UTC
I get 
#jpeg2yuv -v 0 -n 30 -I p -f 29.97 -j sceneselection1.jpg
YUV4MPEG2 W720 H480 F30000:1001 Ip A1:1 C420jpeg
Segmentation fault

the jpg is different from the original posted here but I have tried 8 different 
jpegs and I get the same error that the original poster got.

myth_host burn # emerge info
Portage 2.0.53_rc4 (default-linux/x86/2005.1, gcc-3.4.4, glibc-2.3.5-r2, 2.6.13-
gentoo-r3 i686)
=================================================================
System uname: 2.6.13-gentoo-r3 i686 AMD Athlon(tm) XP
Gentoo Base System version 1.12.0_pre8
dev-lang/python:     2.3.5, 2.4.2
sys-apps/sandbox:    1.2.11
sys-devel/autoconf:  2.13, 2.59-r7
sys-devel/automake:  1.4_p6, 1.5, 1.6.3, 1.7.9-r1, 1.8.5-r3, 1.9.6-r1
sys-devel/binutils:  2.16.1
sys-devel/libtool:   1.5.20
virtual/os-headers:  2.6.11-r2
ACCEPT_KEYWORDS="x86 ~x86"
AUTOCLEAN="yes"
CBUILD="i686-pc-linux-gnu"
CFLAGS="-march=athlon-xp -O2 -pipe"
CHOST="i686-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/kde/2/share/config /usr/kde/3.4/env /usr/kde/3.4/share
/config /usr/kde/3.4/shutdown /usr/kde/3/share/config /usr/lib/X11/xkb /usr/shar
e/config /var/qmail/control"
CONFIG_PROTECT_MASK="/etc/gconf /etc/terminfo /etc/env.d"
CXXFLAGS="-march=athlon-xp -O2 -pipe"
DISTDIR="/usr/portage/distfiles"
FEATURES="autoconfig distlocks sandbox sfperms strict"
GENTOO_MIRRORS="ftp://gentoo.chem.wisc.edu/gentoo/ 
http://gentoo.chem.wisc.edu/gentoo/ http://distfiles.gentoo.org  
http://www.ibiblio.org/pub/Linux/distributions/gentoo"
MAKEOPTS="-j2"
PKGDIR="/usr/portage/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
SYNC="rsync://gentoo.mirrors.tds.net/gentoo-portage"
USE="x86 3dnow 3dnowext X a52 aac acpi alsa apache2 apm arts avi berkdb bitmap-
fonts cdr crypt cups directfb dv dvd dvdr dvdread eds emboss encode fam ffmpeg 
flac flash foomaticdb fortran gd gdbm gif gpm gstreamer imagemagick imlib ipv6 
java joystick jpeg libg++ libwww lirc mad mikmod mjpeg mmx mng motif mp3 mpeg 
mysql mysqli ncurses nls nptl nptlonly offensive ofx ogg oggvorbis openal 
opengl oss pam pdflib perl php pic png python qt quicktime readline sdl spell 
ssl tcpd theora threads tiff truetype truetype-fonts type1-fonts udev v4l vcd 
vorbis win32codecs wmf xine xml2 xmms xosd xpm xv xvid zlib userland_GNU 
kernel_linux elibc_glibc"
Unset:  ASFLAGS, CTARGET, LANG, LC_ALL, LDFLAGS, LINGUAS, PORTDIR_OVERLAY

myth_host burn #
Comment 5 mike daugird 2005-11-03 10:44:57 UTC
is it possible to change the  severity of this bug?
It renders mythburn useless, and I can't find any way to work around it.

Comment 6 Luca Barbato gentoo-dev 2005-11-03 11:17:58 UTC
jpeg version? could you please use genlop to discover what did you emerged that
cause that issue (glibc maybe?!)

I can't reproduce the issue on my x86 system and I don't have it on my ppc
system but I could test once I build it.
Comment 7 mike daugird 2005-11-04 09:31:17 UTC
(In reply to comment #6)
> jpeg version? could you please use genlop to discover what did you emerged 
that
> cause that issue (glibc maybe?!)
> I can't reproduce the issue on my x86 system and I don't have it on my ppc
> system but I could test once I build it.

can you give some more info on what we can do to test. I don't know what you 
mean by jpeg version other then this:
media-libs/jpeg-6b-r6
it never worked for me so genlop won't work
Comment 8 mike daugird 2005-11-04 10:21:54 UTC
Hey, I changed my cflags to be just -pipe 
and I removed all my use flags
I re-emerged jpeg-mmx 
and now it seems to work

can someone try it? I have been doing all sorts of thing to try and fix this 
that it could be a combo of things. But I think this is what triggered the fix.
I also, emerge =media-libs/jpeg-6b-r5  not -r6 which I had before.
HTH
Comment 9 Kenton Groombridge 2005-11-04 13:02:34 UTC
You are on to something.  I just temporarily changed my use flags, emerged
jpeg-mmx, and now it works.

Great job!

Sounds like it is an issue with our processors.  I have an Athlon XP Barton core.

Ken
Comment 10 Doug Goldstein (RETIRED) gentoo-dev 2005-12-25 22:33:37 UTC
Sounds like you guys figured this out. Good job. Technically INVALID since it was hardware.