summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRalf Habacker <ralf.habacker@freenet.de>2011-07-01 22:50:39 (GMT)
committerRalf Habacker <ralf.habacker@freenet.de>2011-07-01 22:53:23 (GMT)
commita7f98d881903beb70b40550c34324210038dabc7 (patch)
treee4958142701072bc325a81d7b8157bf4503d7ff6
parente2f94ea14f6d712edf474ccf6c044a75fe744601 (diff)
downloaddbus-a7f98d881903beb70b40550c34324210038dabc7.tar.gz
dbus-a7f98d881903beb70b40550c34324210038dabc7.tar.xz
Added DBUS_ENABLE_STATS option to cmake buildsystem to keep in sync with autotools.
-rw-r--r--cmake/CMakeLists.txt3
-rw-r--r--cmake/bus/CMakeLists.txt6
-rw-r--r--cmake/config.h.cmake1
3 files changed, 10 insertions, 0 deletions
diff --git a/cmake/CMakeLists.txt b/cmake/CMakeLists.txt
index cbe77c2..2f36303 100644
--- a/cmake/CMakeLists.txt
+++ b/cmake/CMakeLists.txt
@@ -98,6 +98,8 @@ endif(NOT WIN32)
#AC_ARG_ENABLE(asserts, AS_HELP_STRING([--enable-asserts],[include assertion checks]),enable_asserts=$enableval,enable_asserts=$USE_MAINTAINER_MODE)
option (DBUS_DISABLE_ASSERTS "Disable assertion checking" OFF)
+option (DBUS_ENABLE_STATS "enable bus daemon usage statistics" OFF)
+
# do config checks
INCLUDE(ConfigureChecks.cmake)
@@ -557,6 +559,7 @@ message(" Building unit tests: ${DBUS_BUILD_TESTS} "
message(" Building verbose mode: ${DBUS_ENABLE_VERBOSE_MODE} ")
message(" Building w/o assertions: ${DBUS_DISABLE_ASSERTS} ")
message(" Building w/o checks: ${DBUS_DISABLE_CHECKS} ")
+message(" Building bus stats API: ${DBUS_ENABLE_STATS} ")
message(" installing system libs: ${DBUS_INSTALL_SYSTEM_LIBS} ")
#message(" Building SELinux support: ${have_selinux} ")
#message(" Building dnotify support: ${have_dnotify} ")
diff --git a/cmake/bus/CMakeLists.txt b/cmake/bus/CMakeLists.txt
index 876be81..1db519f 100644
--- a/cmake/bus/CMakeLists.txt
+++ b/cmake/bus/CMakeLists.txt
@@ -74,6 +74,12 @@ set (BUS_SOURCES
${XML_SOURCES}
${DIR_WATCH_SOURCE}
)
+if(DBUS_ENABLE_STATS)
+ list(APPEND BUS_SOURCES
+ ${BUS_DIR}/stats.c
+ ${BUS_DIR}/stats.h
+ )
+endif()
include_directories(${XML_INCLUDE_DIR})
diff --git a/cmake/config.h.cmake b/cmake/config.h.cmake
index 5220a8d..b4bfc80 100644
--- a/cmake/config.h.cmake
+++ b/cmake/config.h.cmake
@@ -25,6 +25,7 @@
#cmakedefine DBUS_MICRO_VERSION @DBUS_MICRO_VERSION@
#cmakedefine DBUS_VERSION ((@DBUS_MAJOR_VERSION@ << 16) | (@DBUS_MINOR_VERSION@ << 8) | (@DBUS_MICRO_VERSION@))
#cmakedefine DBUS_VERSION_STRING "@DBUS_VERSION_STRING@"
+#cmakedefine DBUS_ENABLE_STATS
#define VERSION DBUS_VERSION_STRING