From owner-freebsd-ports-bugs@FreeBSD.ORG Sun Oct 17 19:23:04 2004 Return-Path: Delivered-To: freebsd-ports-bugs@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id EF83216A4CE; Sun, 17 Oct 2004 19:23:04 +0000 (GMT) Received: from smtpq1.home.nl (smtpq1.home.nl [213.51.128.196]) by mx1.FreeBSD.org (Postfix) with ESMTP id 0D9A643D6E; Sun, 17 Oct 2004 19:23:03 +0000 (GMT) (envelope-from danny@ricin.com) Received: from [213.51.128.135] (port=58766 helo=smtp4.home.nl) by smtpq1.home.nl with esmtp (Exim 4.30) id 1CJGcQ-0001Zc-KR; Sun, 17 Oct 2004 21:23:02 +0200 Received: from cp464173-a.dbsch1.nb.home.nl ([217.122.43.97]:64831 helo=workstation.homenet) by smtp4.home.nl with esmtp (Exim 4.30) id 1CJGcO-0002xc-Us; Sun, 17 Oct 2004 21:23:00 +0200 From: Danny Pansters To: Mark Linimon Date: Sun, 17 Oct 2004 21:22:10 +0200 User-Agent: KMail/1.7 References: <200410170645.i9H6jSVb028385@freefall.freebsd.org> In-Reply-To: <200410170645.i9H6jSVb028385@freefall.freebsd.org> MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Content-Disposition: inline Message-Id: <200410172122.10881.danny@ricin.com> X-AtHome-MailScanner-Information: Please contact support@home.nl for more information X-AtHome-MailScanner: Found to be clean cc: freebsd-ports-bugs@freebsd.org Subject: Re: ports/72154: [patch] Update x11-toolkits/py-qt to 3.13 and fix unfetchable X-BeenThere: freebsd-ports-bugs@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list Reply-To: danny@ricin.com List-Id: Ports bug reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 17 Oct 2004 19:23:05 -0000 On Sunday 17 October 2004 08:45, you wrote: > This doesn't build for me on 4.x. Any ideas? > > sipqttableQTable.cpp: In method `enum sipQTable::sipEditMode > sipQTable::sipProtect_editMode()': sipqttableQTable.cpp:4413: static_cast > from `QTable::EditMode' to `sipQTable::sipEditMode' > sipqttableQTable.cpp:4414: warning: control reaches end of non-void > function `sipQTable::sipProtect_editMode()' *** Error code 1 Apparently gcc295 isn't always happy with static_cast. Google pointed me to someone having the same problem, only with the commercial pyqt; see http://mats.imk.fraunhofer.de/pipermail/pykde/2004-October/008785.html Here's the relevant part: > > > PyQt 3.13 > > > SIP 4.1.1 > > > Qt 3.3.3 > > > Python 2.3.3 > > > GCC 2.95.4 (Debian) 3.3.4 (Gentoo) > > > > > > Could this be a problem with the GCC version? > > > > I think it probably is - there is an old Irix compiler that has a similar > > problem. To verify, just convert the static_cast on the offending line to > a > > C-style cast. If so, I'll change the code generator to produce a C-style > > cast. > Yes, it compiles now. I got a similar error in sipqtsqlpart0.cpp, but I'm Because this is generated code, a change could be made either in sip or in a post-configure statement. The latter would be my suggestion, as static_cast appears to be used only in this place where your build fails. IIUC I'd have to use something like "(object_type_to_cast_to) the_object" instead. I can't reproduce this on my 5.x box using gcc295 unfortunately (build fails almost instantly) but I'd like to suggest trying the patch below or something equivalent: --- Makefile.orig Sun Oct 17 17:10:17 2004 +++ Makefile Sun Oct 17 20:42:51 2004 @@ -20,6 +20,7 @@ USE_QT_VER= 3 USE_PYTHON= yes +USE_REINPLACE= yes .include @@ -34,6 +35,13 @@ -b ${PREFIX}/bin -d ${PYTHONPREFIX_SITELIBDIR} \ -n ${X11BASE}/include -o ${X11BASE}/lib \ -v ${PREFIX}/share/sip) + +post-configure: +.if ${OSVERSION} < 500000 + @${REINPLACE_CMD} -e \ + 's|static_cast(QTable::editMode())| (sipQTable::sipEditMode) QTable::editMode()|' \ + ${WRKSRC}/qttable/sipqttableQTable.cpp +.endif post-install: @${PYTHON_CMD} -c "import pyqtconfig" I could pester the author, see if he's willing to make the appropriate changes to sip (no biggie I think), but I'm a bit hesitant because using *_cast seems to be good coding practice from what I've gathered and the problem occurs only with our "EOL" gcc in 4.x. What do you think?