NetBSD-Bugs archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: bin/46978: internal compiler error building qt4-libs

The following reply was made to PR bin/46978; it has been noted by GNATS.

From: Alan Barrett <>
Subject: Re: bin/46978: internal compiler error building qt4-libs
Date: Wed, 19 Sep 2012 22:05:51 +0200

 On Tue, 18 Sep 2012, wrote:
 >painting/qdrawhelper_mmx.cpp: In function 'void qt_blend_color_argb_mmx(int, 
 >const QSpan*, void*)':
 >painting/qdrawhelper_mmx.cpp:115:1: internal compiler error: in insert_save, 
 >at caller-save.c:1306
 The compiler bug is still present in g++ (NetBSD nb1 20120916) 4.5.4
 on NetBSD/i386, although the line number has changed from 1306 to 1300:
 "internal compiler error: in insert_save, at caller-save.c:1300"
 The following patch to x11/qt4-libs/ allowed me to successfully build
 the package, by using -O1 instead of -O2 in CXXFLAGS.  It's conditional
 on the OS, MACHINE_ARCH, and compiler version.
 Index: x11/qt4-libs/
 --- x11/qt4-libs/      3 Aug 2011 16:38:31 -0000       1.1
 +++ x11/qt4-libs/      19 Sep 2012 11:22:11 -0000
 @@ -10,3 +10,20 @@ PKG_HACKS+=         macosx-codegen
   BUILDLINK_TRANSFORM+=        rename:-O[0-9]*:-O1
   .  endif
 +### [Wed Sep 19 09:24:11 UTC 2012 : apb]
 +### g++-4.5.3 and 4.5.4 on NetBSD/i386 fails with an internal compiler error
 +### when building gui/painting/qdrawhelper_mmx.cpp.
 +### Building with -O1 instead of -O2 seems to work around the problem.
 +.if ${OPSYS} == "NetBSD" && ${MACHINE_ARCH} == "i386"
 +.  include "../../mk/"
 +.  if !empty(CC_VERSION:Mgcc-4.5.*)
 +PKG_HACKS+=           pr46978
 +SUBST_CLASSES+=               pr46978
 +SUBST_STAGE.pr46978=  post-configure
 +SUBST_MESSAGE.pr46978=        Working around optimizer bug (NetBSD PR 46978)
 +SUBST_FILES.pr46978=  src/gui/Makefile
 +SUBST_SED.pr46978=    -e '/^CXXFLAGS/s/-O2/-O1/'
 +.  endif

Home | Main Index | Thread Index | Old Index