diff options
-rw-r--r-- | ChangeLog | 7 | ||||
-rw-r--r-- | buildrun.cxx | 10 | ||||
-rw-r--r-- | runtime/ChangeLog | 4 | ||||
-rw-r--r-- | runtime/autoconf-inode-private.c | 6 |
4 files changed, 24 insertions, 3 deletions
@@ -1,3 +1,10 @@ +2007-04-27 Frank Ch. Eigler <fche@elastic.org> + + PR 4432. + * buildrun.cxx (compile_pass): Tweak autoconf CFLAGS handling to + avoid macro recursion but still get the needed -I directives. + Add the inode-private autoconf test. + 2007-04-26 Frank Ch. Eigler <fche@elastic.org> PR 4432. diff --git a/buildrun.cxx b/buildrun.cxx index ec633bab..e8bd5855 100644 --- a/buildrun.cxx +++ b/buildrun.cxx @@ -42,14 +42,18 @@ compile_pass (systemtap_session& s) // Clever hacks copied from vmware modules o << "stap_check_gcc = $(shell if $(CC) $(1) -S -o /dev/null -xc /dev/null > /dev/null 2>&1; then echo \"$(1)\"; else echo \"$(2)\"; fi)" << endl; - o << "stap_check_build = $(shell " /*<< "set -x; "*/ << " if $(CC) $(CPPFLAGS) $(CFLAGS_KERNEL) $(mflags-y) $(EXTRA_CFLAGS) -DKBUILD_BASENAME=\\\"" << s.module_name << "\\\" -Werror -S -o /dev/null -xc $(1) > /dev/null 2>&1; then echo \"$(2)\"; else echo \"$(3)\"; fi)" << endl; + o << "stap_check_build = $(shell " << "set -x; " << " if $(CC) $(CPPFLAGS) $(CFLAGS_KERNEL) $(EXTRA_CFLAGS) $(CFLAGS) -DKBUILD_BASENAME=\\\"" << s.module_name << "\\\" -Werror -S -o /dev/null -xc $(1) > /dev/null ; then echo \"$(2)\"; else echo \"$(3)\"; fi)" << endl; + o << "SYSTEMTAP_RUNTIME = \"" << s.runtime_path << "\"" << endl; // "autoconf" options go here // enum hrtimer_mode renaming near 2.6.21; see tapsets.cxx hrtimer_derived_probe_group::emit_module_decls - o << "CFLAGS += $(call stap_check_build, $(SYSTEMTAP_RUNTIME)/autoconf-hrtimer-rel.c, -DSTAPCONF_HRTIMER_REL,)" << endl; + string module_cflags = "CFLAGS_" + s.module_name + ".o"; + o << module_cflags << " :=" << endl; + o << module_cflags << " += $(call stap_check_build, $(SYSTEMTAP_RUNTIME)/autoconf-hrtimer-rel.c, -DSTAPCONF_HRTIMER_REL,)" << endl; + o << module_cflags << " += $(call stap_check_build, $(SYSTEMTAP_RUNTIME)/autoconf-inode-private.c, -DSTAPCONF_INODE_PRIVATE,)" << endl; for (unsigned i=0; i<s.macros.size(); i++) @@ -94,7 +98,7 @@ compile_pass (systemtap_session& s) string make_cmd = string("make") + string (" -C \"") + module_dir + string("\""); make_cmd += string(" M=\"") + s.tmpdir + string("\" modules"); - + if (s.verbose > 1) make_cmd += " V=1"; else diff --git a/runtime/ChangeLog b/runtime/ChangeLog index 7f9daf76..ca92880b 100644 --- a/runtime/ChangeLog +++ b/runtime/ChangeLog @@ -1,3 +1,7 @@ +2007-04-27 Frank Ch. Eigler <fche@elastic.org> + + * autoconf-inode-private.c: New file from hunt. + 2007-04-04 Sébastien Dugué <sebastien.dugue@bull.net> * runtime/lket/b2a/lket_b2a.c: Fix percpu files parsing diff --git a/runtime/autoconf-inode-private.c b/runtime/autoconf-inode-private.c new file mode 100644 index 00000000..7e7ee7f7 --- /dev/null +++ b/runtime/autoconf-inode-private.c @@ -0,0 +1,6 @@ +#include <linux/fs.h> + +/* check 2.6.18 inode diet patch which changed */ +/* u.generic_ip to i_private */ + +struct inode i __attribute__ ((unused)) = {.i_private=(void *)0}; |