First pass at adding logging capabilities for the API functions.  At the moment
it logs the function calls, their arguments and the return values.  This is not
complete or polished, but I am committing it now, at the request of someone who
really wants to use it, even though it's not really done.  It currently does not
attempt to log all the functions, just the most important ones.  I will be 
making further adjustments to the API logging code over the next few days/weeks.
(Suggestions for improvements are welcome).


Update the Python build scripts to re-build the swig C++ file whenever 
the python-extensions.swig file is modified.

Correct the help for 'log enable' command (give it the correct number & type of
arguments).

llvm-svn: 117349
diff --git a/lldb/source/lldb-log.cpp b/lldb/source/lldb-log.cpp
index ce8d213..1428383 100644
--- a/lldb/source/lldb-log.cpp
+++ b/lldb/source/lldb-log.cpp
@@ -136,6 +136,7 @@
             const char *arg = args.GetArgumentAtIndex(i);
 
             if      (strcasecmp(arg, "all")     == 0  ) flag_bits |= LIBLLDB_LOG_ALL;
+            else if (strcasecmp(arg, "api")     == 0)   flag_bits |= LIBLLDB_LOG_API;
             else if (strcasestr(arg, "break")   == arg) flag_bits |= LIBLLDB_LOG_BREAKPOINTS;
             else if (strcasecmp(arg, "default") == 0  ) flag_bits |= LIBLLDB_LOG_DEFAULT;
             else if (strcasestr(arg, "event")   == arg) flag_bits |= LIBLLDB_LOG_EVENTS;
@@ -177,6 +178,7 @@
 {
     strm->Printf("Logging categories for 'lldb':\n"
         "\tall - turn on all available logging categories\n"
+        "\tapi - enable logging of API calls and return values\n"
         "\tdefault - enable the default set of logging categories for liblldb\n"
         "\tbreak - log breakpoints\n"
         "\tevents - log broadcaster, listener and event queue activities\n"