summaryrefslogtreecommitdiff
path: root/qpid/cpp/src
diff options
context:
space:
mode:
authorAndrew Stitcher <astitcher@apache.org>2014-01-27 18:31:34 +0000
committerAndrew Stitcher <astitcher@apache.org>2014-01-27 18:31:34 +0000
commitecf1ea9d93ffc84ee758efdd89fa2749e3ec7aa7 (patch)
treed7a65380c3c10e69003fc5141af962971ecdf805 /qpid/cpp/src
parentfe567d6649801119d83e5f96af69e39569a14eef (diff)
downloadqpid-python-ecf1ea9d93ffc84ee758efdd89fa2749e3ec7aa7.tar.gz
QPID-5516: Only enable Dtrace style probes on Linux
git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk@1561775 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'qpid/cpp/src')
-rw-r--r--qpid/cpp/src/CMakeLists.txt21
1 files changed, 13 insertions, 8 deletions
diff --git a/qpid/cpp/src/CMakeLists.txt b/qpid/cpp/src/CMakeLists.txt
index 7b8ea49251..46b526579f 100644
--- a/qpid/cpp/src/CMakeLists.txt
+++ b/qpid/cpp/src/CMakeLists.txt
@@ -391,14 +391,19 @@ if (NOT CMAKE_SYSTEM_NAME STREQUAL Windows)
set (uuid_LIB "uuid")
# Check for header file for dtrace static probes
- check_include_files(sys/sdt.h HAVE_SYS_SDT_H)
- if (HAVE_SYS_SDT_H)
- set(probes_default ON)
- endif (HAVE_SYS_SDT_H)
- option(BUILD_PROBES "Build with DTrace/systemtap static probes" ${probes_default})
- if (NOT BUILD_PROBES)
- set (HAVE_SYS_SDT_H 0)
- endif (NOT BUILD_PROBES)
+ check_include_files(sys/sdt.h HAVE_SDT)
+ if (HAVE_SDT)
+ # Only enable by default on Linux
+ if (CMAKE_SYSTEM_NAME STREQUAL Linux)
+ set(probes_default ON)
+ endif (CMAKE_SYSTEM_NAME STREQUAL Linux)
+ option(BUILD_PROBES "Build with DTrace/systemtap static probes" "${probes_default}")
+ endif (HAVE_SDT)
+ if (BUILD_PROBES)
+ set (HAVE_SYS_SDT_H 1)
+ else (HAVE_SDT)
+ set (HAVE_SYS_SDT_H 0)
+ endif (BUILD_PROBES)
# Check for poll/epoll header files
check_include_files(sys/poll.h HAVE_POLL)