[lldb-dev] Help RE: help for lldb command like gdb info sources & info source

Yin Ma yin at affinic.com
Sun Sep 15 22:49:03 PDT 2013


Hi Greg,

Thank you for sending sources.py. However, I still
Cannot get it work on my Mac machine. I got this error
After I do
(lldb) command script import ~/sources.py
(lldb) info_sources

Traceback (most recent call last):
  File "/Users/yin/sources.py", line 22, in info_sources
    
  File "/Users/yin/sources.py", line 8, in dump_module_sources
    print >> result, "Module: %s" % (module.file)
  File "/System/Library/PrivateFrameworks/LLDB.framework/Versions/A/Resources/Python/lldb/__init__.py", line 1653, in <lambda>
    __getattr__ = lambda self, name: _swig_getattr(self, SBCommandReturnObject, name)
  File "/System/Library/PrivateFrameworks/LLDB.framework/Versions/A/Resources/Python/lldb/__init__.py", line 78, in _swig_getattr
    raise AttributeError(name)
AttributeError: write

I upgraded my system from snow leopard to the latest mountain lion.
And I also upgraded lldb to 179.5. I got all same error like this.
Could you help me to figure out how to fix it?

Thanks,

Yin


-----Original Message-----
From: Greg Clayton [mailto:gclayton at apple.com] 
Sent: Tuesday, September 03, 2013 6:42 PM
To: Yin Ma
Cc: Jim Ingham; lldb-dev
Subject: Re: [lldb-dev] help for lldb command like gdb info sources & info source

For this old of an LLDB you will need to put back ticks around the $pc:

(lldb) image lookup -va `$pc`

To get the file list, we can turn to python:






More information about the lldb-dev mailing list