Farkas Levente schreef op zo 31-07-2011 om 21:49 [+0200]:
hi,
anybody has ever debug mingw pacakges? unfortunately it seems our
gstreamer-ffmpeg always segfault, but we don't know why. so we try to
debug. but we always got the same error from gdb:
------------------------------
warning: the debug information found in "c:\Program
Files\Vidux5\gstreamer\lib\gstreamer-0.10\libgstffmpeg.dll.debug" does
not match "c:\Program
Files\Vidux5\gstreamer\lib\gstreamer-0.10\libgstffmpeg.dll" (CRC mismatch).
------------------------------
we rebuild it we sure that we use the right debuginfo packages so what
can be the problem? and how can we debug anything?
thanks.
regards.
Hi Levente,
Are you sure that you've used the .dll and .dll.debug file from the same
set of built RPMs? If you rebuild a RPM (even when nothing is changed in
the .spec file or the code) and only use the files from the freshly
built -debuginfo package while keeping the old main package installed
(or in reverse) then you can get these kind of messages.
I just tried to reproduce these messages with the mingw32-gstreamer and
mingw32-gdb packages which can be found in my mingw-w64 testing repo:
======
C:\Users\Erik van Pienbroek\Desktop\gstreamer>dir
Het volume in station C heeft geen naam.
Het volumenummer is 06D4-9680
Map van C:\Users\Erik van Pienbroek\Desktop\gstreamer
07-08-2011 14:49 <DIR> .
07-08-2011 14:49 <DIR> ..
14-07-2011 06:56 3.246.958 gdb.exe
07-08-2011 16:02 46.292 gst-inspect-0.10.exe
07-08-2011 16:02 145.858 gst-inspect-0.10.exe.debug
11-07-2011 19:24 29.527 iconv.dll
15-07-2011 13:32 156.319 libexpat-1.dll
11-07-2011 20:03 27.539 libffi-6.dll
13-07-2011 00:34 1.088.311 libglib-2.0-0.dll
13-07-2011 00:34 22.981 libgmodule-2.0-0.dll
13-07-2011 00:34 280.543 libgobject-2.0-0.dll
07-08-2011 16:02 798.976 libgstreamer-0.10-0.dll
07-08-2011 16:02 2.642.437 libgstreamer-0.10-0.dll.debug
13-07-2011 00:34 27.556 libgthread-2.0-0.dll
11-07-2011 23:57 94.713 libintl-8.dll
12-07-2011 00:47 1.128.637 libxml2-2.dll
11-07-2011 19:20 82.186 zlib1.dll
15 bestand(en) 9.818.833 bytes
2 map(pen) 1.904.902.144 bytes beschikbaar
C:\Users\Erik van Pienbroek\Desktop\gstreamer>gdb gst-inspect-0.10.exe
GNU gdb (GDB) 7.2
Copyright (C) 2010 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later
<
http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law. Type "show
copying"
and "show warranty" for details.
This GDB was configured as "i686-w64-mingw32".
For bug reporting instructions, please see:
<
http://www.gnu.org/software/gdb/bugs/>...
Reading symbols from C:\Users\Erik van Pienbroek\Desktop
\gstreamer/gst-inspect-0.10.exe...Reading symbols from C:\Users\Erik van
Pienbroek\Desktop\gstreamer/gst-inspect-0.10.exe.debug...
warning: section .gnu_debuglink not found in C:\Users\Erik van Pienbroek
\Desktop\gstreamer/gst-inspect-0.10.exe.debug
done.
done.
(gdb) break gst_init
Function "gst_init" not defined.
Make breakpoint pending on future shared library load? (y or [n]) y
Breakpoint 1 (gst_init) pending.
(gdb) r
Starting program: C:\Users\Erik van Pienbroek\Desktop
\gstreamer/gst-inspect-0.10.exe
[New Thread 1796.0x884]
warning: section .gnu_debuglink not found in C:\Users\Erik van Pienbroek
\Desktop\gstreamer\libgstreamer-0.10-0.dll.debug
staticelements: bin: Generic bin
staticelements: pipeline: Pipeline object
Total count: 1 plugin, 2 features
Program exited normally.
(gdb) break gst_init
Note: breakpoint 1 also set at pc 0x6b6c2690.
Breakpoint 2 at 0x6b6c2690: file ../../gst/gst.c, line 490.
(gdb) r
Starting program: C:\Users\Erik van Pienbroek\Desktop
\gstreamer/gst-inspect-0.10.exe
[New Thread 2864.0x50c]
warning: section .gnu_debuglink not found in C:\Users\Erik van Pienbroek
\Desktop\gstreamer\libgstreamer-0.10-0.dll.debug
staticelements: bin: Generic bin
staticelements: pipeline: Pipeline object
Total count: 1 plugin, 2 features
Program exited normally.
(gdb) q
========
As you can see, the .debug files are detected by gdb and
filenames/line-numbers are shown. However, it spits out a strange
warning about a missing .gnu_debuglink section in the .debug file.
Unfortunately I don't know what this section really does, so perhaps the
mingw-w64 developers can give an explanation to this message?
@mingw-w64 developers: After the compilation has completed of binaries,
we try to split the debug information from the main binary to a
separate .debug file. This is done using these commands:
mingw-objcopy --only-keep-debug $f $f.debug
mingw-objcopy --add-gnu-debuglink=`basename $f.debug` --strip-unneeded
`basename $f`
Is this also the preferred method or can we better use something else?
Kind regards,
Erik van Pienbroek
PS: Levente, could you please add gstreamer-plugin-good-rtsp.patch to
the svn repo? It's currently missing so I can't build
gstreamer-plugins-good at the moment