Add an --enable-timers configure option to enable the TIMER_BEGIN/END macros
authorSøren Sandmann Pedersen <sandmann@redhat.com>
Thu, 4 Jun 2009 04:05:06 +0000 (00:05 -0400)
committerSøren Sandmann Pedersen <sandmann@redhat.com>
Thu, 4 Jun 2009 04:05:06 +0000 (00:05 -0400)
configure.ac
pixman/pixman-private.h
pixman/pixman-timer.c

index 74ae807..5409e1d 100644 (file)
@@ -436,6 +436,17 @@ fi
 
 AM_CONDITIONAL(USE_GCC_INLINE_ASM, test $have_gcc_inline_asm = yes)
 
+dnl ==============================================
+dnl Timers
+
+AC_ARG_ENABLE(timers,
+   [AC_HELP_STRING([--enable-timers],
+                  [enable TIMER_BEGIN and TIMER_END macros [default=no]])],
+   [enable_timers=$enableval], [enable_timers=no])
+
+AC_DEFINE(PIXMAN_TIMERS, 1, [enable TIMER_BEGIN/TIMER_END macros])
+AC_SUBST(PIXMAN_TIMERS)
+
 dnl ===================================
 dnl GTK+
 
index d95de2c..94e23c6 100644 (file)
@@ -778,7 +778,7 @@ void pixman_region_internal_set_static_pointers (pixman_box16_t *empty_box,
                                                 pixman_region16_data_t *empty_data,
                                                 pixman_region16_data_t *broken_data);
 
-#ifdef PIXMAN_TIMING
+#ifdef PIXMAN_TIMERS
 
 /* Timing */
 static inline uint64_t
@@ -823,7 +823,7 @@ void pixman_timer_register (PixmanTimer *timer);
         timer##tname.total += OIL_STAMP() - begin##tname;              \
     }
 
-#endif /* PIXMAN_TIMING */
+#endif /* PIXMAN_TIMERS */
 
 typedef struct pixman_implementation_t pixman_implementation_t;
 
index ce54e74..7742527 100644 (file)
@@ -27,7 +27,7 @@
 #include <stdio.h>
 #include "pixman-private.h"
 
-#ifdef PIXMAN_TIMER
+#ifdef PIXMAN_TIMERS
 
 static PixmanTimer *timers;