<html><body><div style="font-family: arial,helvetica,sans-serif; font-size: 12pt; color: #000000"><div>I finally tracked this down to the sip build varying based on whether the sipgen/parser.y file was newer or older than sipgen/parser.c. If for some reason the .y mtime is newer, gnu make will regenerate the .c file using yacc, based on an <em>implicit</em> make rule(!), and the resultant parser.c file is completely wrong, or at least very different to the shipped parser.c file!</div><div><br></div><div>I saw a similar issue with lexer.l -> lexer.c, though its result seems OK on my system.</div><div><br></div><div><p style="margin: 0px; padding-left: 30px;">gcc -c -pipe -O2 -w -DNDEBUG -I. -o main.o main.c<br>gcc -c -pipe -O2 -w -DNDEBUG -I. -o transform.o transform.c<br>gcc -c -pipe -O2 -w -DNDEBUG -I. -o gencode.o gencode.c<br>gcc -c -pipe -O2 -w -DNDEBUG -I. -o extracts.o extracts.c<br>gcc -c -pipe -O2 -w -DNDEBUG -I. -o export.o export.c<br>gcc -c -pipe -O2 -w -DNDEBUG -I. -o heap.o heap.c<br><strong>yacc parser.y </strong><br><strong>lex -t lexer.l > lexer.c</strong><br><strong>yacc: 2 shift/reduce conflicts.</strong><br><strong>mv -f y.tab.c parser.c</strong><br>gcc -c -pipe -O2 -w -DNDEBUG -I. -o parser.o parser.c<br>gcc -c -pipe -O2 -w -DNDEBUG -I. -o lexer.o lexer.c</p></div><div><br></div><div>Should it not be the case that the .l and .y files successfully regenerate working .c files? I have fixed my system to make sure the timestamps match those in the tarball, but it seems a bit peculiar that an implicit make rule is kicking in and having yacc generate a completely broken .c file.</div><div><br></div><div>In any event, posting this here for reference. I saw a few other people throughout internets history have run into sip 'syntax errors' for no apparent reason...</div><div><br></div><div>Thanks</div><div><br></div><div>Alex</div><div><br></div><hr id="zwchr"><blockquote style="border-left:2px solid #1010FF;margin-left:5px;padding-left:5px;color:#000;font-weight:normal;font-style:normal;text-decoration:none;font-family:Helvetica,Arial,sans-serif;font-size:12pt;" data-mce-style="border-left: 2px solid #1010FF; margin-left: 5px; padding-left: 5px; color: #000; font-weight: normal; font-style: normal; text-decoration: none; font-family: Helvetica,Arial,sans-serif; font-size: 12pt;"><b>From: </b>"Alexander Jones" <aj@dneg.com><br><b>To: </b>pyqt@riverbankcomputing.com<br><b>Sent: </b>Friday, 6 December, 2013 4:00:54 PM<br><b>Subject: </b>Building PyQt4 4.10.3 with SIP 4.15.3 fails<br><div><br></div><div style="font-family: arial,helvetica,sans-serif; font-size: 12pt; color: #000000" data-mce-style="font-family: arial,helvetica,sans-serif; font-size: 12pt; color: #000000;"><div>Last bits of the build log suggest that <span style="font-size: 12pt;" data-mce-style="font-size: 12pt;">sip/QtCore/QtCoremod.sip line 28</span></div><div><p style="margin: 0px;" data-mce-style="margin: 0px;"><strong>%Module(name=PyQt4.QtCore, keyword_arguments="Optional", version=1)</strong></p><p style="margin: 0px;" data-mce-style="margin: 0px;">is not valid sip syntax.</p><p style="margin: 0px;" data-mce-style="margin: 0px;"><br></p><p style="margin: 0px;" data-mce-style="margin: 0px;">$ /builds/33053b6f7201475883aaaf17df751156/bin/sip -V<br>4.15.3</p><p style="margin: 0px;" data-mce-style="margin: 0px;"><br></p><p style="margin: 0px;" data-mce-style="margin: 0px;">...</p><p style="margin: 0px;" data-mce-style="margin: 0px;"><br></p><p style="margin: 0px;" data-mce-style="margin: 0px;">Qt v4.8.5 (Open Source) is being used.<br>The qmake executable is /builds/31fd53e06351418c8c3a628224717e39/bin/qmake.<br>Qt is built as a shared library.<br>SIP 4.15.3 is being used.<br>The sip executable is /builds/33053b6f7201475883aaaf17df751156/bin/sip.<br>These PyQt4 modules will be built: QtCore, QtGui, QtHelp, QtMultimedia,<br>QtNetwork, QtDeclarative, QtScript, QtScriptTools, QtXml, QtOpenGL, QtSql,<br>QtSvg, QtTest, QtWebKit, QtXmlPatterns, phonon, QtDesigner, QtDBus.<br>The PyQt4 Python package will be installed in<br>/builds/b7d39adb1af7447480fbcb90d33a9f95/lib/python.<br>PyQt4 is being built with generated docstrings.<br>PyQt4 is being built with 'protected' redefined as 'public'.<br>The Designer plugin will be installed in<br>/builds/b7d39adb1af7447480fbcb90d33a9f95/lib/qt/plugins.<br>The PyQt4 .sip files will be installed in<br>/builds/b7d39adb1af7447480fbcb90d33a9f95/share/sip.<br>pyuic4, pyrcc4 and pylupdate4 will be installed in<br>/builds/b7d39adb1af7447480fbcb90d33a9f95/bin.<br>The interpreter used by pyuic4 is<br>/builds/efadbeb8de594d03860666e827c593c9/bin/python.<br>Embedding sip flags...<br>Generating the .pro file for the QPy support library for QtCore...<br>Generating the Makefile for the QPy support library for QtCore...<br>/builds/31fd53e06351418c8c3a628224717e39/bin/qmake w_qpycore.pro<br>Generating the C++ source for the QtCore module...<br><strong>/builds/33053b6f7201475883aaaf17df751156/bin/sip -w -x VendorID -t WS_X11 -t Qt_4_8_4 -x PyQt_NoPrintRangeBug -x Py_v3 -o -P -a QtCore.api -g -c /user_data/.tmp/tmpi93lOi.bobbuild/QtCore -I sip -I /user_data/.tmp/tmpi93lOi.bobbuild/sip /user_data/.tmp/tmpi93lOi.bobbuild/sip/QtCore/QtCoremod.sip</strong><br><strong>sip: /user_data/.tmp/tmpi93lOi.bobbuild/sip/QtCore/QtCoremod.sip:28: syntax error</strong><br><strong>Error: Unable to create the C++ code.</strong></p><p style="margin: 0px;" data-mce-style="margin: 0px;"><strong><br></strong></p><p style="margin: 0px;" data-mce-style="margin: 0px;">Any idea what's going on? Pretty sure I was getting this to build before...</p></div><div><p style="margin: 0px;" data-mce-style="margin: 0px;"><br></p><p style="margin: 0px;" data-mce-style="margin: 0px;"><strong><br></strong></p><p style="margin: 0px;" data-mce-style="margin: 0px;"><strong><br></strong></p></div><div><br></div><div><span></span><div><span style="font-family: arial, helvetica, sans-serif;" data-mce-style="font-family: arial, helvetica, sans-serif;">Alexander Jones</span></div><div><span style="font-family: arial, helvetica, sans-serif;" data-mce-style="font-family: arial, helvetica, sans-serif;">Double Negative R&D<br></span><span style="font-family: arial, helvetica, sans-serif;" data-mce-style="font-family: arial, helvetica, sans-serif;">www.dneg.com</span><br></div><span></span><br></div></div></blockquote><div><br></div></div></body></html>