aboutsummaryrefslogtreecommitdiff
path: root/gdb/configure.ac
diff options
context:
space:
mode:
authorMarkus Metzger <markus.t.metzger@intel.com>2013-11-12 16:58:45 +0100
committerMarkus Metzger <markus.t.metzger@intel.com>2015-07-02 12:45:50 +0200
commit58bfce93438e1f936d4547bb9659b7d096e2823f (patch)
tree08d90d15eae88aee807c65af7e39d73663e2e5cd /gdb/configure.ac
parentb0fd6b3037669534962b1ffe860db178ea7e1239 (diff)
downloadgdb-58bfce93438e1f936d4547bb9659b7d096e2823f.zip
gdb-58bfce93438e1f936d4547bb9659b7d096e2823f.tar.gz
gdb-58bfce93438e1f936d4547bb9659b7d096e2823f.tar.bz2
configure: check for libipt
Check for libipt, an Intel(R) Processor Trace decoder library. The sources can be found on github at: https://github.com/01org/processor-trace gdb/ * configure.ac: Check for libipt * configure: Regenerate. * config.in: Regenerate. * Makefile.in (LIBIPT): New. (CLIBS): Add $LIBIPT. * NEWS: document new configure options
Diffstat (limited to 'gdb/configure.ac')
-rw-r--r--gdb/configure.ac20
1 files changed, 20 insertions, 0 deletions
diff --git a/gdb/configure.ac b/gdb/configure.ac
index 2035a37..a40860a 100644
--- a/gdb/configure.ac
+++ b/gdb/configure.ac
@@ -1242,6 +1242,26 @@ if test "$ENABLE_LIBMCHECK" = "yes" \
AC_MSG_WARN(--enable-libmcheck may lead to spurious crashes if threads are used in python)
fi
+AC_ARG_WITH(intel_pt,
+ AS_HELP_STRING([--with-intel-pt], [include Intel(R) Processor Trace support (auto/yes/no)]),
+ [], [with_intel_pt=auto])
+AC_MSG_CHECKING([whether to use intel pt])
+AC_MSG_RESULT([$with_intel_pt])
+
+if test "${with_intel_pt}" = no; then
+ AC_MSG_WARN([Intel(R) Processor Trace support disabled; some features may be unavailable.])
+ HAVE_LIBIPT=no
+else
+ AC_LIB_HAVE_LINKFLAGS([ipt], [], [#include "intel-pt.h"], [pt_insn_alloc_decoder (0);])
+ if test "$HAVE_LIBIPT" != yes; then
+ if test "$with_intel_pt" = yes; then
+ AC_MSG_ERROR([libipt is missing or unusable])
+ else
+ AC_MSG_WARN([libipt is missing or unusable; some features may be unavailable.])
+ fi
+ fi
+fi
+
# ------------------------- #
# Checks for header files. #
# ------------------------- #