public inbox for systemtap@sourceware.org
 help / color / mirror / Atom feed
* Compilation for tracepoint on 2.6.33-rc1
@ 2009-12-22  3:26 Wenji Huang
  2009-12-22 20:24 ` Josh Stone
  0 siblings, 1 reply; 2+ messages in thread
From: Wenji Huang @ 2009-12-22  3:26 UTC (permalink / raw)
  To: SystemTAP

Hi,

There is compilation error for tracepoint on 2.6.33-rc1, see

$ sudo stap -we 'probe kernel.trace("kvm_mmio"),kernel.trace("sys*"){}'
In file included from 
/tmp/stapOWxU0E/stap_978faaf75db7cd5c5160bd681e7d912e_688.c:271:
include/trace/events/syscalls.h:3:1: error: "TRACE_INCLUDE_FILE" redefined
In file included from 
/tmp/stapOWxU0E/stap_978faaf75db7cd5c5160bd681e7d912e_688.c:151:
include/trace/events/kvm.h:8:1: error: this is the location of the 
previous definition
make[1]: *** 
[/tmp/stapOWxU0E/stap_978faaf75db7cd5c5160bd681e7d912e_688.o] Error 1
make: *** [_module_/tmp/stapOWxU0E] Error 2
Pass 4: compilation failed.  Try again with another '--vp 0001' option.

On 2.6.33-rc1, TRACE_INCLUDE_FILE is defined both 
include/trace/events/syscalls.h and include/trace/events/kvm.h without
leading #undef.

How to handle this, to push a patch of adding #undef before
#define TRACE_INCLUDE_FILE to LKML
or
emit "#undef TRACE_INCLUDE_FILE" before "#include <trace/events/*.h>"
to the generated C code?

Regards,
Wenji

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: Compilation for tracepoint on 2.6.33-rc1
  2009-12-22  3:26 Compilation for tracepoint on 2.6.33-rc1 Wenji Huang
@ 2009-12-22 20:24 ` Josh Stone
  0 siblings, 0 replies; 2+ messages in thread
From: Josh Stone @ 2009-12-22 20:24 UTC (permalink / raw)
  To: wenji.huang; +Cc: SystemTAP

On 12/21/2009 07:22 PM, Wenji Huang wrote:
> How to handle this, to push a patch of adding #undef before
> #define TRACE_INCLUDE_FILE to LKML

This is the proper fix.  In the case of kvm, just having TRACE_SYSTEM
should be sufficient, but syscalls.h does use separate names.

> emit "#undef TRACE_INCLUDE_FILE" before "#include <trace/events/*.h>"
> to the generated C code?

It wouldn't really hurt to do this as well, but let's see if LKML will
fix it first.


Josh

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2009-12-22 20:24 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-12-22  3:26 Compilation for tracepoint on 2.6.33-rc1 Wenji Huang
2009-12-22 20:24 ` Josh Stone

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).