Revision b3a246da02a4114ec55d15793154cf38d7a39be7 authored by Jordan Lund on 19 February 2016, 22:53:34 UTC, committed by Jordan Lund on 19 February 2016, 22:53:34 UTC
MozReview-Commit-ID: 5otLdixBeX --HG-- extra : source : e0a91fd6584f4d06a8fae84e5ae2c3a96c17fdb0 extra : intermediate-source : 941a62368cb7664124838d8797bc34138819db9c
1 parent 4d6a902
linux.m4
dnl This Source Code Form is subject to the terms of the Mozilla Public
dnl License, v. 2.0. If a copy of the MPL was not distributed with this
dnl file, You can obtain one at http://mozilla.org/MPL/2.0/.
AC_DEFUN([MOZ_LINUX_PERF_EVENT],
[
MOZ_ARG_WITH_STRING(linux-headers,
[ --with-linux-headers=DIR
location where the Linux kernel headers can be found],
linux_headers=$withval)
LINUX_HEADERS_INCLUDES=
if test "$linux_headers"; then
LINUX_HEADERS_INCLUDES="-I$linux_headers"
fi
_SAVE_CFLAGS="$CFLAGS"
CFLAGS="$CFLAGS $LINUX_HEADERS_INCLUDES"
dnl Performance measurement headers.
MOZ_CHECK_HEADER(linux/perf_event.h,
[AC_CACHE_CHECK(for perf_event_open system call,ac_cv_perf_event_open,
[AC_TRY_COMPILE([#include <asm/unistd.h>],[return sizeof(__NR_perf_event_open);],
ac_cv_perf_event_open=yes,
ac_cv_perf_event_open=no)])])
if test "$ac_cv_perf_event_open" = "yes"; then
HAVE_LINUX_PERF_EVENT_H=1
else
HAVE_LINUX_PERF_EVENT_H=
LINUX_HEADERS_INCLUDES=
fi
AC_SUBST(HAVE_LINUX_PERF_EVENT_H)
AC_SUBST(LINUX_HEADERS_INCLUDES)
CFLAGS="$_SAVE_CFLAGS"
])
![swh spinner](/static/img/swh-spinner.gif)
Computing file changes ...