From f8bfb48eddd36b2730db8c3b0d2a82ed8438ca87 Mon Sep 17 00:00:00 2001 From: Tony Jones Date: Thu, 10 Jun 2010 09:38:14 -0400 Subject: [PATCH] fix !CONFIG_FRAME_POINTER, !CONFIG_UTRACE case In a kernel without FRAME_POINTERS (using the DWARF UNWINDER) and without UTRACE I see the following in latest git master: [...] In file included from /tmp/stap/share/systemtap/runtime/stack.c:56:0, from /tmp/stapPHqTen/stap_12068.c:52: /tmp/stap/share/systemtap/runtime/stack-i386.c: In function "__stp_stack_print": /tmp/stap/share/systemtap/runtime/stack-i386.c:69:25: error: implicit declaration of function "uprobe_get_pc". AFAICT the autoconf test should result in STAPCONF_UPROBE_GET_PC=0 for the case where CONFIG_UTRACE is unset since UPROBES requires UTRACE. Signed-off-by: Tony Jones --- runtime/autoconf-uprobe-get-pc.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/runtime/autoconf-uprobe-get-pc.c b/runtime/autoconf-uprobe-get-pc.c index 2bd41c8c7..1f5af44e7 100644 --- a/runtime/autoconf-uprobe-get-pc.c +++ b/runtime/autoconf-uprobe-get-pc.c @@ -1,3 +1,4 @@ +#if defined(CONFIG_UTRACE) #if defined(CONFIG_UPROBES) || defined(CONFIG_UPROBES_MODULE) #include #else @@ -8,3 +9,6 @@ unsigned long foo (struct uretprobe_instance *ri, unsigned long pc, unsigned lon { return uprobe_get_pc (ri, pc, sp); } +#else +#error "need CONFIG_UTRACE" /* XXX: at least, uretprobe-capable uprobes */ +#endif -- 2.43.5