Closed GoogleCodeExporter closed 9 years ago
interesting. One thing I'm noticing is that you've built with
DEFAULT_PLUGIN_PATH="/usr/lib/edb/" yet the runtime error mentions
/usr/lib64/edb/. Is it at all possible that it is loading plugins from another
build?
Original comment by evan.teran
on 3 Oct 2012 at 4:44
Thanks for your answer Evan!
You are right, I mixed the output. It comes from the default build options I
tried out recently. The one relevant to build options I submitted with this bug
report is as follows:
$ edb
Starting EDB Version: 0.9.11
Please Report Bugs & Requests At: http://bugs.codef00.com/
[loadPlugins] Cannot load library /usr/lib/edb/libAnalyzer.so:
(/usr/lib/edb/libAnalyzer.so: undefined symbol: _ZTV9MemRegion)
[loadPlugins] Cannot load library /usr/lib/edb/libBinarySearcher.so:
(/usr/lib/edb/libBinarySearcher.so: undefined symbol: _ZTV9MemRegion)
[loadPlugins] Cannot load library /usr/lib/edb/libBookmarks.so:
(/usr/lib/edb/libBookmarks.so: undefined symbol:
_ZN3edb2v111getVariableERK7QStringRbR15ExpressionErrorPv)
[loadPlugins] Cannot load library /usr/lib/edb/libBreakpointManager.so:
(/usr/lib/edb/libBreakpointManager.so: undefined symbol:
_ZN3edb2v111getVariableERK7QStringRbR15ExpressionErrorPv)
[loadPlugins] Loading Plugin: libCheckVersion.so : 0xfc1df0
[loadPlugins] Cannot load library /usr/lib/edb/libDebuggerCore.so:
(/usr/lib/edb/libDebuggerCore.so: undefined symbol: _ZN3edb2v112debuggerBaseE)
[loadPlugins] Cannot load library /usr/lib/edb/libDumpState.so:
(/usr/lib/edb/libDumpState.so: undefined symbol: _ZN3edb2v112debuggerBaseE)
[loadPlugins] Cannot load library /usr/lib/edb/libELFBinaryInfo.so:
(/usr/lib/edb/libELFBinaryInfo.so: undefined symbol: _ZN3edb2v112debuggerBaseE)
[loadPlugins] Cannot load library /usr/lib/edb/libEnvironment.so:
(/usr/lib/edb/libEnvironment.so: undefined symbol: _ZN3edb2v112debuggerBaseE)
[loadPlugins] Loading Plugin: libFunctionDB.so : 0xfd3520
[loadPlugins] Cannot load library /usr/lib/edb/libFunctionFinder.so:
(/usr/lib/edb/libFunctionFinder.so: undefined symbol: _ZTV9MemRegion)
[loadPlugins] Cannot load library /usr/lib/edb/libHardwareBreakpoints.so:
(/usr/lib/edb/libHardwareBreakpoints.so: undefined symbol:
_ZN3edb2v112debuggerBaseE)
[loadPlugins] Cannot load library /usr/lib/edb/libHeapAnalyzer.so:
(/usr/lib/edb/libHeapAnalyzer.so: undefined symbol: _ZN3edb2v112debuggerBaseE)
[loadPlugins] Cannot load library /usr/lib/edb/libOpcodeSearcher.so:
(/usr/lib/edb/libOpcodeSearcher.so: undefined symbol: _ZN3edb2v112debuggerBaseE)
[loadPlugins] Cannot load library /usr/lib/edb/libOpenFiles.so:
(/usr/lib/edb/libOpenFiles.so: undefined symbol: _ZN3edb2v112debuggerBaseE)
[loadPlugins] Cannot load library /usr/lib/edb/libReferences.so:
(/usr/lib/edb/libReferences.so: undefined symbol: _ZTV9MemRegion)
[loadPlugins] Loading Plugin: libSessionManager.so : 0xf85660
[loadPlugins] Cannot load library /usr/lib/edb/libStringSearcher.so:
(/usr/lib/edb/libStringSearcher.so: undefined symbol: _ZN3edb2v110debuggerUIE)
[loadPlugins] Cannot load library /usr/lib/edb/libSymbolViewer.so:
(/usr/lib/edb/libSymbolViewer.so: undefined symbol: _ZN3edb2v110debuggerUIE)
edb: symbol lookup error: /usr/lib/edb/libFunctionDB.so: undefined symbol:
_ZN3edb2v113setFunctionDBEP10FunctionDB
Moreover, there is no such problem occurring while using previous edb versions,
I verified this in the same build environment.
Original comment by evan.teran
on 3 Oct 2012 at 4:45
OK, it seems that for some reason the plugins can't access the main
application's symbols. Any chance that you could do a fresh make and get all of
the output (including any warnings) into a file. I am curious if certain build
flags are being passed during specific parts of the build process.
If all else fails, I'll set up an arch linux 64-bit VM and try to reproduce the
bug locally. Is there any particular version I should use to recreate the
problem?
Original comment by evan.teran
on 3 Oct 2012 at 4:45
build log
$ LC_ALL=en_US.UTF8 makepkg -f 2>&1 |bzip2 -c > build.log.bz2
Please find attached build.log.bz2 generated by the command above :)
Arch is based on a rolling-release model, just fetch current release and update
the system: http://www.archlinux.org/download/
Thanks for your effort Evan, I would just give you access to my machine in
order to save you the trouble but unfortunately I'm behind a router and have no
access to its configuration.
Best regards!
Original comment by evan.teran
on 3 Oct 2012 at 4:46
Attachments:
OK, i believe I know the problem :-). Basically i "improved" the build system
to make it more versatile with non-linux/gcc builds.
edb **needs** -rdynamic in its flags to work (this makes it so plugins can see
the symbols which are exported by the primary executable), which I tied to
"linux-g++"... But it is nowhere to be found in your linker command.
Can you test something for me:
try changing in (src/src.pro) the following lines:
linux-g++: QMAKE_CXXFLAGS += -fvisibility=hidden
linux-g++: QMAKE_LFLAGS += -rdynamic
to
linux-g++*: QMAKE_CXXFLAGS += -fvisibility=hidden
linux-g++*: QMAKE_LFLAGS += -rdynamic
If this works, I'll do a version bump with a patch.
Original comment by evan.teran
on 3 Oct 2012 at 4:46
build log after patching
unfortunately it did not help
Original comment by evan.teran
on 3 Oct 2012 at 4:48
Attachments:
Evan, looks like I got it working!
Your patch + edb binary not stripped!
Original comment by evan.teran
on 3 Oct 2012 at 4:48
Looks like there is still some problem. I will investigate further tomorrow,
but I can see the light already :)
Thanks for your help, I will get back to you, hopefully with working solution.
Original comment by evan.teran
on 3 Oct 2012 at 4:48
Great to hear that the patch made a difference. and yea, stripping the binaries
can lead to problems (most likely debugging symbols can be stripped just fine
though).
You mentioned that there is still something which is a problem. Is the runtime
error the same or different now?
Considering that previous versions ran just fine I am inclined to assume that
some part of the compile/link flags is at fault. But without knowing the
current errors you are getting I have no way of verifying that.
Original comment by evan.teran
on 3 Oct 2012 at 4:49
The problems I mentioned in the previous post were related to a different
version of edb, sorry, it must have been too late for me yesterday :)
I just verified everything again and it works now! The patch you suggested is
enough and needed indeed.
Many thanks Evan!
I will wait for an updated release of yours if that offer is still valid ;)
Original comment by evan.teran
on 3 Oct 2012 at 4:49
fixed in the newly release 0.9.12. Glad that we could figure this out.
Original comment by evan.teran
on 3 Oct 2012 at 4:49
Original comment by evan.teran
on 3 Oct 2012 at 4:49
Original issue reported on code.google.com by
evan.teran
on 3 Oct 2012 at 3:21