[lldb-dev] Linking issue missing init_lldb() - linux

Pawel Wodnicki root at hbbrbasic.com
Fri Jun 11 22:30:22 PDT 2010


On 6/11/2010 4:16 PM, Jean-Daniel Dupas wrote:
>
> From a previos discussion at 
> http://lists.cs.uiuc.edu/pipermail/lldb-dev/2010-June/000039.html
SFAL!
> Read this answer too, it may be interesting:
>
> http://lists.cs.uiuc.edu/pipermail/lldb-dev/2010-June/000045.html
>
It is, thx!
>
>
> -- Jean-Daniel
>

After some mocking with the types and lldb namespace in the lldb.swig 
(see below ) I got it to link nicely.
Oh, there is this cute liblld  typo to take care. But the thing SEGVs in 
the strlen, curious.

Pawel


Index: lldb.swig
===================================================================
--- lldb.swig   (revision 105871)
+++ lldb.swig   (working copy)
@@ -65,7 +65,7 @@
  }


-/* The liblld header files to be included. */
+/* The liblldb header files to be included. */

  %{
  #include "lldb/lldb-types.h"
@@ -95,7 +95,6 @@
  #include "lldb/API/SBThread.h"
  #include "lldb/API/SBType.h"
  #include "lldb/API/SBValue.h"
-using namespace lldb;
  using namespace lldb_private;
  %}

@@ -103,21 +102,24 @@

  %{
  typedef unsigned int uint32_t;
-typedef unsigned long long uint64_t;
  typedef int int32_t;
-typedef int32_t pid_t;
  typedef uint32_t tid_t;
  typedef uint64_t addr_t;
+typedef int32_t break_id_t;
+typedef lldb::SBStringList SBStringList;
+typedef lldb::RegisterKind RegisterKind;
+const RegisterKind kNumRegisterKinds = lldb::kNumRegisterKinds ;
  %}

  typedef unsigned int uint32_t;
-typedef unsigned long long uint64_t;
  typedef int int32_t;
-typedef int32_t pid_t;
  typedef uint32_t tid_t;
  typedef uint64_t addr_t;
+typedef int32_t break_id_t;
+typedef lldb::SBStringList SBStringList;
+typedef lldb::RegisterKind RegisterKind;
+const RegisterKind kNumRegisterKinds = lldb::kNumRegisterKinds ;

-
  %include "lldb/API/SBAddress.h"
  %include "lldb/API/SBBlock.h"
  %include "lldb/API/SBBreakpoint.h"




More information about the lldb-dev mailing list