This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author dmalcolm
Recipients dmalcolm
Date 2013-03-25.19:33:55
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1364240036.0.0.495843553762.issue17547@psf.upfronthosting.co.za>
In-reply-to
Content
It appears that gcc's -Wformat warning changed from being on by default in gcc 4.7 and earlier to being off by default in gcc 4.8, needing to be enabled with -Wformat (or -Wall), if I'm reading:
http://gcc.gnu.org/viewcvs/gcc?view=revision&revision=193304
correctly

This breaks CPython's configure.ac test:
  "Check whether GCC supports PyArg_ParseTuple format"
in that the warning the test is supposed to emit is guarded by -Wformat, hence with gcc 4.8 this test always emits:
  checking whether gcc supports ParseTuple __format__... yes
despite the fact that gcc doesn't.

This leads to the pyconfig.h defining HAVE_ATTRIBUTE_FORMAT_PARSETUPLE, and thus we get this error when trying later use the python build to build a C extension module where -Wformat (or -Wall) *is* supplied:
In file included from /usr/include/python2.7/Python.h:126:0,
                 from isys.c:20:
/usr/include/python2.7/modsupport.h:28:1: error: 'PyArg_ParseTuple' is an unrecognized format function type [-Werror=format=]
 PyAPI_FUNC(int) PyArg_ParseTuple(PyObject *, const char *, ...) Py_FORMAT_PARSETUPLE(PyArg_ParseTuple, 2, 3);

Am attaching a work-in-progress patch to supply the missing argument at configure time

Note to self: am tracking this downstream as https://bugzilla.redhat.com/show_bug.cgi?id=927358
History
Date User Action Args
2013-03-25 19:33:56dmalcolmsetrecipients: + dmalcolm
2013-03-25 19:33:55dmalcolmsetmessageid: <1364240036.0.0.495843553762.issue17547@psf.upfronthosting.co.za>
2013-03-25 19:33:55dmalcolmlinkissue17547 messages
2013-03-25 19:33:55dmalcolmcreate