[gnome-builder] clang: add debugging for tracing cflags



commit bfa98f7997f2526a127c77d9099b18378a08c58b
Author: Christian Hergert <christian hergert me>
Date:   Tue Mar 24 02:44:59 2015 -0700

    clang: add debugging for tracing cflags

 libide/clang/ide-clang-service.c |   13 +++++++++++++
 1 files changed, 13 insertions(+), 0 deletions(-)
---
diff --git a/libide/clang/ide-clang-service.c b/libide/clang/ide-clang-service.c
index e291d86..f840169 100644
--- a/libide/clang/ide-clang-service.c
+++ b/libide/clang/ide-clang-service.c
@@ -16,6 +16,8 @@
  * along with this program.  If not, see <http://www.gnu.org/licenses/>.
  */
 
+#define G_LOG_DOMAIN "gb-clang-service"
+
 #include <clang-c/Index.h>
 #include <glib/gi18n.h>
 
@@ -23,6 +25,7 @@
 #include "ide-clang-private.h"
 #include "ide-clang-service.h"
 #include "ide-context.h"
+#include "ide-debug.h"
 #include "ide-file.h"
 #include "ide-unsaved-file.h"
 #include "ide-unsaved-files.h"
@@ -194,6 +197,16 @@ ide_clang_service__get_build_flags_cb (GObject      *object,
 
   request->command_line_args = argv;
 
+#ifndef IDE_DISABLE_TRACE
+  {
+    gchar *cflags;
+
+    cflags = g_strjoinv (" ", argv);
+    IDE_TRACE_MSG ("CFLAGS = %s", cflags);
+    g_free (cflags);
+  }
+#endif
+
   g_task_run_in_thread (task, ide_clang_service_parse_worker);
 }
 


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]