OS X jimdb binaries don't work (for me)




Firefox for Android
5 years ago
5 years ago


(Reporter: kats, Assigned: jchen)


Firefox Tracking Flags

(Not tracked)


I'm running Mac OS X 10.7.5. I wanted to update my jimdb to get the latest java debugging stuff, so I tried using the prebuilt binaries linked from https://wiki.mozilla.org/Mobile/Fennec/Android/GDB#Using_pre-built_binaries - I tried both the x86 and x64 Mac binaries but they both crash on startup.

With the x64 binary I get:

kats@kgupta-air jimdb$ bin/gdb
Segmentation fault: 11

and with the x86 binary I get:

kats@kgupta-air jimdb$ bin/gdb
Illegal instruction: 4

If I try to debug (either x86 or x64) jimdb using my host gdb, I get this:

kats@kgupta-air jimdb$ gdb --args bin/gdb
GNU gdb 6.3.50-20050815 (Apple version gdb-1824) (Wed Feb  6 22:51:23 UTC 2013)
Copyright 2004 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you are
welcome to change it and/or distribute copies of it under certain conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB.  Type "show warranty" for details.
This GDB was configured as "x86_64-apple-darwin"...Reading symbols for shared libraries ........ done

(gdb) run
Starting program: /Users/kats/android/jdb/jimdb/bin/gdb 
warning: The target crashed on startup, maybe the shell is crashing.
"Try set start-with-shell 0" to workaround.
Abort trap: 6

Doing the start-with-shell it recommends doesn't change anything.

Then I built jimdb myself using the instructions on the same wiki page, and that worked fine. So it's just something wrong with the prebuilt binaries, but I don't know what.

Comment 1

5 years ago
That's weird. I compiled them on 10.8.2, so maybe there's an incompatibility there. What does 'otool -L jimdb/bin/gdb' say? I wonder if it could be a library incompatibility.

Comment 2

5 years ago
Also, if you don't mind posting the binaries you built, I can update the prebuilt one with yours.
kats@kgupta-air jdb$ otool -L jimdb/bin/gdb
	/usr/lib/libiconv.2.dylib (compatibility version 7.0.0, current version 7.0.0)
	/usr/lib/libncurses.5.4.dylib (compatibility version 5.4.0, current version 5.4.0)
	/usr/lib/libz.1.dylib (compatibility version 1.0.0, current version 1.2.5)
	/usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current version 169.3.0)
	/System/Library/Frameworks/CoreFoundation.framework/Versions/A/CoreFoundation (compatibility version 150.0.0, current version 744.12.0)
	/System/Library/Frameworks/Python.framework/Versions/2.7/Python (compatibility version 2.7.0, current version 2.7.2)
	/usr/lib/libexpat.1.dylib (compatibility version 7.0.0, current version 7.2.0)

I posted my gdb binary to people.mozilla.com/~kgupta/tmp/gdb.gz

Comment 4

5 years ago
Interestingly, I ran into the exact same issues when I ran your binary, gdb segfaulting and host gdb not being able to debug. Not sure what's the issue.

In any case, I think I will post your binary alongside mine, so people can try both.

Comment 5

5 years ago
Assigning to me so I remember to look at this in detail some other time.
Assignee: nobody → nchen

Comment 6

5 years ago
I've built new binaries using the OS X 10.7 SDK, which will hopefully fix the issue. Can you test these when you get a chance? http://people.mozilla.org/~nchen/jimdb/
The bin/gdb binary in the jimdb-mac-x86.tar.bz2 posted there works for me. Thanks!

Comment 8

5 years ago
Looks like switching the OS X SDK did the trick.
Last Resolved: 5 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.