This is the mail archive of the systemtap@sourceware.org mailing list for the systemtap project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: How to give compiler arguments


On 09/06/2013 01:42 PM, Martin Martin wrote:
> Hi,
> 
> If I put:
> 
> %{
> #include "stdint.h"
> %}
> 
> at the start of my probe script, stap says:
> 
> 
> In file included from
> /tmp/stapR3xMcm/stap_a41ca76a927c0e462ab230035f8677ed_1654_src.c:24:0:
> /usr/lib/gcc/x86_64-linux-gnu/4.7/include/stdint.h:3:26: error: no
> include path in which to search for stdint.h
> make[1]: *** [/tmp/stapR3xMcm/stap_a41ca76a927c0e462ab230035f8677ed_1654_src.o]
> Error 1
> 
> Is there a way to give some extra arguments to the compiler to resolve
> this?  Or am I out of luck because it's a kernel module?

Systemtap modules are real kernel modules, and thus have no access to
glibc (or its headers).

You can change the value of defines on the stap command line, like
'-DFOO=1'.

-- 
David Smith
dsmith@redhat.com
Red Hat
http://www.redhat.com
256.217.0141 (direct)
256.837.0057 (fax)


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]