This is sources Bugzilla
Bugzilla Version 2.17.5
Bugzilla Bug 9896
  Systemtap source compilation failure on latest Ubuntu Last modified: 2009-02-25 10:34:05
     Query page      Enter new bug
Bug#: 9896   Hardware:   Reporter: Ankita Garg <ankita@in.ibm.com>
Host: Target: Build:
Product:     Add CC:
Component:   Version:   CC:
Status: RESOLVED   Priority:  
Resolution: FIXED   Severity:  
Assigned To: Ananth Mavinakayanahalli <ananth@in.ibm.com>   Target Milestone:  
Summary:
Keywords:

Attachment Description Type Created Actions
Create a New Attachment (proposed patch, testcase, etc.) View All

Bug 9896 depends on: Show dependency tree
Show dependency graph
Bug 9896 blocks:

Additional Comments:


Leave as RESOLVED FIXED
Reopen bug
Mark bug as VERIFIED

View Bug Activity   |   Format For Printing


Description:   Last confirmed: 0000-00-00 00:00 Opened: 2009-02-25 08:00
When compiling the latest systemtap tarball, v 0;9 with 0.140 elfutils package,
gives the following compile time warning:

tapsets.cxx: In member function ‘std::string
dwflpp::express_as_string(std::string, std::string, location*)’:
tapsets.cxx:2299: error: format not a string literal and no format arguments
tapsets.cxx:2301: error: format not a string literal and no format arguments

Since the Makefile passes the -Werror flag, warnings are treated as errors and
the compilation aborts.

This was seen on a x86_64 system on Ubuntu Intrepid (8.10), running 2.6.29-rc4
kernel, with gcc version 4.3.2.

------- Additional Comment #1 From Ananth Mavinakayanahalli 2009-02-25 09:35 -------
The following patch fixes the problem for Ankita. Do we want this fix or is
removing -Werror preferred?

---
 tapsets.cxx |    4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

Index: systemtap-20feb/tapsets.cxx
===================================================================
--- systemtap-20feb.orig/tapsets.cxx
+++ systemtap-20feb/tapsets.cxx
@@ -2296,9 +2296,9 @@ struct dwflpp
     assert(memstream);
 
     fprintf(memstream, "{\n");
-    fprintf(memstream, prelude.c_str());
+    fprintf(memstream, "%s", prelude.c_str());
     bool deref = c_emit_location (memstream, head, 1);
-    fprintf(memstream, postlude.c_str());
+    fprintf(memstream, "%s", postlude.c_str());
     fprintf(memstream, "  goto out;\n");
 
     // dummy use of deref_fault label, to disable warning if deref() not used

------- Additional Comment #2 From Mark Wielaard 2009-02-25 09:50 -------
(In reply to comment #1)
> The following patch fixes the problem for Ankita. Do we want this fix or is
> removing -Werror preferred?

IMHO we want this fix and keep -Werror, it catches important stuff.

------- Additional Comment #3 From Mark Wielaard 2009-02-25 09:52 -------
*** Bug 9898 has been marked as a duplicate of this bug. ***

------- Additional Comment #4 From Ananth Mavinakayanahalli 2009-02-25 10:24 -------
Commit bec508de upstream.

------- Additional Comment #5 From Ankita Garg 2009-02-25 10:33 -------
*** Bug 9900 has been marked as a duplicate of this bug. ***

------- Additional Comment #6 From Ankita Garg 2009-02-25 10:34 -------
*** Bug 9899 has been marked as a duplicate of this bug. ***

     Query page      Enter new bug
Actions: New | Query | bug # | Reports | Requests   New Account | Log In