aboutsummaryrefslogtreecommitdiffstats
path: root/tools/perf/Makefile
diff options
context:
space:
mode:
authorRandy Dunlap <randy.dunlap@oracle.com>2009-10-18 22:20:24 -0400
committerIngo Molnar <mingo@elte.hu>2009-10-19 04:06:37 -0400
commit1abc7f5500fff8422f34826a006648d8741d83d3 (patch)
tree1136d94ed2ac06b359324ed6bebd651ead727010 /tools/perf/Makefile
parentdb9f11e36d0125a5e3e595ea9ef2e4b89f7e8737 (diff)
perf tools: Display better error messages on missing packages
Check for libelf headers and glibc headers separately so that the error message correctly identifies which package installation is missing/needed. Signed-off-by: Randy Dunlap <randy.dunlap@oracle.com> Cc: paulus@samba.org Cc: a.p.zijlstra@chello.nl Cc: efault@gmx.de Cc: fweisbec@gmail.com Cc: Arnaldo Carvalho de Melo <acme@redhat.com> LKML-Reference: <4ADBCCE8.3060300@oracle.com> Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'tools/perf/Makefile')
-rw-r--r--tools/perf/Makefile6
1 files changed, 5 insertions, 1 deletions
diff --git a/tools/perf/Makefile b/tools/perf/Makefile
index 2400e5068a2f..db89a6de9d06 100644
--- a/tools/perf/Makefile
+++ b/tools/perf/Makefile
@@ -431,8 +431,12 @@ ifeq ($(uname_S),Darwin)
431 PTHREAD_LIBS = 431 PTHREAD_LIBS =
432endif 432endif
433 433
434ifneq ($(shell sh -c "(echo '\#include <gnu/libc-version.h>'; echo 'int main(void) { const char * version = gnu_get_libc_version(); return (long)version; }') | $(CC) -x c - $(ALL_CFLAGS) -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64 -o /dev/null $(ALL_LDFLAGS) > /dev/null 2>&1 && echo y"), y)
435 msg := $(error No gnu/libc-version.h found, please install glibc-dev[el]);
436endif
437
434ifneq ($(shell sh -c "(echo '\#include <libelf.h>'; echo 'int main(void) { Elf * elf = elf_begin(0, ELF_C_READ_MMAP, 0); return (long)elf; }') | $(CC) -x c - $(ALL_CFLAGS) -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64 -o /dev/null $(ALL_LDFLAGS) > /dev/null 2>&1 && echo y"), y) 438ifneq ($(shell sh -c "(echo '\#include <libelf.h>'; echo 'int main(void) { Elf * elf = elf_begin(0, ELF_C_READ_MMAP, 0); return (long)elf; }') | $(CC) -x c - $(ALL_CFLAGS) -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64 -o /dev/null $(ALL_LDFLAGS) > /dev/null 2>&1 && echo y"), y)
435 msg := $(error No libelf.h/libelf found, please install libelf-dev/elfutils-libelf-devel and glibc-dev[el]); 439 msg := $(error No libelf.h/libelf found, please install libelf-dev/elfutils-libelf-devel);
436endif 440endif
437 441
438ifdef NO_DEMANGLE 442ifdef NO_DEMANGLE