"lldb image list" does not show native FS path

OS X El Captain, Xcode 7.01, Jailbroken iOS 7.1.1

$: lldb
(lldb) platform select remote-ios
Platform: remote-ios
Connected: no
SDK Path: “/Users/papillon/Library/Developer/Xcode/iOS DeviceSupport/8.1 (12B410)”
SDK Roots: [ 0] “/Users/papillon/Library/Developer/Xcode/iOS DeviceSupport/7.1.1 (11D201)”
SDK Roots: [ 1] “/Users/papillon/Library/Developer/Xcode/iOS DeviceSupport/8.1 (12B410)”
SDK Roots: [ 2] “/Users/papillon/Library/Developer/Xcode/iOS DeviceSupport/8.1.2 (12B440)”
(lldb) process connect connect://192.168.1.107:1234
Process 32872 stopped

  • thread #1: tid = 0x45a74c, 0x2be7c028 dyld_dyld_start, stop reason = signal SIGSTOP frame #0: 0x2be7c028 dyld_dyld_start
    dyld`_dyld_start:
    → 0x2be7c028 <+0>: mov r8, sp
    0x2be7c02c <+4>: sub sp, sp, #16
    0x2be7c030 <+8>: bic sp, sp, #7
    0x2be7c034 <+12>: ldr r3, [pc, #0x70] ; <+132>
    (lldb) image list -h -o -f
    [ 0] 0x00012000 0x00011000 /Applications/Preferences.app/Preferences(0x0000000000012000)
    [ 1] 0x2beb3000 0x000b3000 /Users/papillon/Library/Developer/Xcode/iOS DeviceSupport/7.1.1 (11D201)/Symbols/usr/lib/dyld
    [ 2] 0x000be000 0x000be000 /Library/MobileSubstrate/MobileSubstrate.dylib(0x00000000000be000)
    [ 3] 0x32937000 0x018b1000 /Users/papillon/Library/Developer/Xcode/iOS DeviceSupport/7.1.1 (11D201)/Symbols/System/Library/PrivateFrameworks/BulletinBoard.framework/BulletinBoard

The module path here is from OS X, not iOS. The reason may be SDK Roots shown above not including native path?

Seems LLDB works this way though,
What do you need native FS path for?

(lldb) help image list
-f[] ( --fullpath=[] )
Display the fullpath to the image object file.

The modules loaded in the process running on iOS are from iOS native FS, that is, something like /Applications/Preferences.app/Preferences, or /System/Library/Frameworks/Foundation.framework/ (actualy from /System/Library/Caches/com.apple.dyld/dyld_shared_cache_{ARCH}), not from OS X.
Since the -f option say “the fullpath to the image object file”, it should display the actual module path from iOS native FS.
Although we can figure out the “correct” module path, displaying a path from OS X seems to be cheating the users :slight_smile:

Agreed, -f options should reveal the path on iOS, not OSX. Maybe it’s because when LLDB is debugging remotely, the symbols are read from OSX natively?

FYI, there’s a detailed interpretation of this topic