From 1392896dcda33324d43392f8e99fed240cf5fb9b Mon Sep 17 00:00:00 2001 From: "Frank Ch. Eigler" Date: Mon, 24 Aug 2009 10:34:45 -0400 Subject: PR4186: cross-architecture probe building * main.cxx (main): Add 'a:' and 'B:' options. * session.h (kbuildflags): New place to store -B args. * testsuite/systemtap.base/cmd_parse.exp: Test them lightly. * buildrun.cxx (run_make_cmd): Use "--no-print-directory" rather than ">/dev/null" in kbuild invocations. Pass '-a' and '-B' flags along. * hash.cxx (find_script_hash): Add them. * NEWS, stap.1.in: Mention this. --- buildrun.cxx | 17 +++++++++++++---- 1 file changed, 13 insertions(+), 4 deletions(-) (limited to 'buildrun.cxx') diff --git a/buildrun.cxx b/buildrun.cxx index 1820002d..69cc5a66 100644 --- a/buildrun.cxx +++ b/buildrun.cxx @@ -59,9 +59,9 @@ run_make_cmd(systemtap_session& s, string& make_cmd) if (s.verbose > 2) make_cmd += " V=1"; else if (s.verbose > 1) - make_cmd += " >/dev/null"; + make_cmd += " --no-print-directory"; else - make_cmd += " -s >/dev/null"; + make_cmd += " -s --no-print-directory"; return stap_system (s.verbose, make_cmd); } @@ -222,8 +222,17 @@ compile_pass (systemtap_session& s) // Run make string make_cmd = string("make") - + string (" -C \"") + module_dir + string("\""); - make_cmd += string(" M=\"") + s.tmpdir + string("\" modules"); + + string (" -C \"") + module_dir + string("\""); // XXX: lex_cast_qstring? + make_cmd += string(" M=\"") + s.tmpdir + string("\""); + + // Add architecture + make_cmd += string(" ARCH=") + lex_cast_qstring(s.architecture); + + // Add any custom kbuild flags + for (unsigned k=0; k