Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 1571 - QT3 doesn't use make.conf CFLAGS
Summary: QT3 doesn't use make.conf CFLAGS
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Library (show other bugs)
Hardware: x86 Linux
: High enhancement (vote)
Assignee: Dan Armak (RETIRED)
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2002-04-06 05:38 UTC by Michael v.Ostheim
Modified: 2003-02-04 19:42 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Michael v.Ostheim 2002-04-06 05:38:11 UTC
Date: Fri, 05 Apr 2002 17:51:46 +0300 
From: Dan Armak <danarmak@gentoo.org>  (Gentoo Technologies, Inc.) 
To: gentoo-user@gentoo.org 
Reply to: gentoo-user@gentoo.org 
On Thursday 04 April 2002 22:51, Michael v.Ostheim wrote: 
> For example, qt-lib's configuration script does not use my CFLAGS and 
> CXXFLAGS settings from /etc/make.conf. 
> I have to edit  $QTDIR/mkspecs/linux-g++/qmake.conf  manually to compile it 
> with my prefered optimations. This is a little bit difficult with the 
> Gentoo portage system. 
> Does somebody know how to compile it without editing the source package? 
> 
> BTW: I love Gentoo Linux. Thanks to all developers, great work :-). 
> 
QT2 does use the make.conf CFLAGS. The reason QT3 doesn't is that if you  
change qmake.conf, these settings will be inherited by all projects qmake  
later processes which potentially changes the default behaviour of the  
installed qt. 
 
It it possible to use custom CFLAGS just for building QT3 itself though, it  
just requires a little makefile editing. Or we can even change qmake and then  
change it back again. You're basically right, so please file an  
enhancement-class issue on bugs.gentoo.org and we'll do it. At some point :-) 
 
--  
Dan Armak 
Gentoo Linux developer (KDE) 
Matan, Israel
Comment 1 Dan Armak (RETIRED) gentoo-dev 2002-05-17 10:28:02 UTC
Remember this? It's still open :-) 
I tried compiling qt with custom CFLAGS and got a compile error: 
 
make[1]: Entering directory 
`/var/tmp/portage/qt-3.0.4.1/work/qt-copy-3.0.4/src' 
g++ -c -march=i686 -O3 -pipe -fomit-frame-pointer -fno-exceptions 
-I/usr/include/mysql -Wall -W -O2 -D_REENTRANT -fPIC -DQT_SHARED -DQT_NO_DEBUG 
-DQT_THREAD_SUPPORT -DQT_THREAD_SUPPORT -DQT_NO_NIS -DQT_NAS_SUPPORT 
-DQT_NO_REMOTE -DQT_BUILTIN_GIF_READER=1 -DQT_NO_STYLE_AQUA -DQT_NO_STYLE_MAC 
-DQT_NO_STYLE_INTERLACE -DQT_NO_STYLE_COMPACT -I/usr/X11R6/include/freetype2 
-I/var/tmp/portage/qt-3.0.4.1/work/qt-copy-3.0.4/include -I/usr/X11R6/include 
-I/usr/X11R6/include -I.moc/release-mt/ 
-I/var/tmp/portage/qt-3.0.4.1/work/qt-copy-3.0.4/mkspecs/linux-g++ -o 
.obj/release-mt/qsvgdevice.o xml/qsvgdevice.cpp 
xml/qsvgdevice.cpp: In method `bool QSvgDevice::play(QPainter *)': 
xml/qsvgdevice.cpp:271: Unable to generate reloads for: 
(insn 810 808 812 (parallel[ 
            (set (reg:SI 6 %ebp) 
                (fix:SI (fix:DF (reg/v:DF 185)))) 
            (clobber (mem:HI (plus:SI (reg:SI 6 %ebp) 
                        (const_int -38 [0xffffffda])) 0)) 
            (clobber (mem:HI (plus:SI (reg:SI 6 %ebp) 
                        (const_int -40 [0xffffffd8])) 0)) 
            (clobber (mem:SI (plus:SI (reg:SI 6 %ebp) 
                        (const_int -44 [0xffffffd4])) 0)) 
            (clobber (scratch:HI)) 
        ] ) 149 {fix_truncdfsi2+1} (insn_list 784 (nil)) 
    (expr_list:REG_UNUSED (scratch:HI) 
        (nil))) 
cpp0: output pipe has been closed 
make[1]: *** [.obj/release-mt/qsvgdevice.o] Error 1 
make[1]: Leaving directory `/var/tmp/portage/qt-3.0.4.1/work/qt-copy-3.0.4/src' 
make: *** [sub-src] Error 2 
 
... I've checked and other distros do add custom flags to the compile. However 
I don't yet know what these flags are. So this gets delayed. Again. 
 
Oh well... 
Comment 2 Dan Armak (RETIRED) gentoo-dev 2002-07-06 09:24:29 UTC
I'm back on the issue :-)  
I've just committed a new (masked) revision of qt that uses custom CFLAGS,  
CXXFLAGS to compile (and removes them from mkspecs/.../qmake.conf when  
installing). It tests ok here; I have requested people to tes it (on 
gentoo-dev and -core), once some more favourable reports come in it can be 
unmasked.  
Comment 3 Michael v.Ostheim 2002-07-08 13:24:15 UTC
Hi, 
I have a big problem emerging this masked version. The system is slowing down 
with 95% idle CPU and a RAM _and_ Swap usage going continuesly to 100%. I have 
to break it at this point: 
---Snip--- 
 Do you accept the terms of either license? 
Creating qmake. Please wait... 
g++ -c -o project.o -march=i686 -O3 -pipe  -I. -Igenerators -Igenerators/unix 
-Igenerators/win32  -Igenerators/mac -I../incl 
ude 
-I/var/tmp/portage/qt-3.0.4.20020606-r2/work/qt-copy-3.0.4/include 
-I../src/tools -DQT_NO_TEXTCODEC -DQT_NO_COMPONENT -DQT_N 
O_STL 
-I/var/tmp/portage/qt-3.0.4.20020606-r2/work/qt-copy-3.0.4/mkspecs/linux-g++ 
-march=i686 -O3 -pipe  project.cpp 
g++ -c -o main.o -march=i686 -O3 -pipe  -I. -Igenerators -Igenerators/unix 
-Igenerators/win32  -Igenerators/mac -I../include 
 -I/var/tmp/portage/qt-3.0.4.20020606-r2/work/qt-copy-3.0.4/include 
-I../src/tools -DQT_NO_TEXTCODEC -DQT_NO_COMPONENT -DQT_ 
NO_STL 
-I/var/tmp/portage/qt-3.0.4.20020606-r2/work/qt-copy-3.0.4/mkspecs/linux-g++ 
-march=i686 -O3 -pipe  main.cpp 
g++ -c -o makefile.o -march=i686 -O3 -pipe  -I. -Igenerators -Igenerators/unix 
-Igenerators/win32  -Igenerators/mac -I../inc 
lude -I/var/tmp/portage/qt-3.0.4.20020606-r2/work/qt-copy-3.0.4/include 
-I../src/tools -DQT_NO_TEXTCODEC -DQT_NO_COMPONENT - 
DQT_NO_STL 
-I/var/tmp/portage/qt-3.0.4.20020606-r2/work/qt-copy-3.0.4/mkspecs/linux-g++ 
-march=i686 -O3 -pipe  generators/ma 
kefile.cpp 
---Snap--- 
Comment 4 Dan Armak (RETIRED) gentoo-dev 2002-07-10 14:58:08 UTC
I expirienced that too. That file it's trying to compile is apparently very 
very large and heavy. It took it about 7-8 minutes to compile here, on a p3-900 
with 256mb ram + 512 mb swap. What specs does your machine have? I think that 
if you leave it to compile overnight (or even just for a couple of hours) it'll 
work. At worst it'll run out of memory and the compile will die. 
Comment 5 Michael v.Ostheim 2002-07-11 12:53:46 UTC
I use an Athlon 1400 with 256 MB RAM + 512 MB Swap. I tried it overnight, and 
the emerge died with a "virtual memory exhausted" error.  
Then I added a second 512 MB swap partition, quit XFree and tried it again - 
same result after 90 minutes :(. 
Comment 6 Dan Armak (RETIRED) gentoo-dev 2002-07-11 13:26:07 UTC
Several people reported this on ppc too. It seems like I'm the only for whom it compiles properly! I suspect this is beacuse we not only add our custom flags but remove the default qt ones. Maybe there's something important in what we remove. I could add our flags before the default ones, thus the default ones will override the custom ones. We'll be left with -O2 but if someone has some other important optimizations they will at least be taken into effect. The question is, would this be worth the effort? 
Comment 7 Dan Armak (RETIRED) gentoo-dev 2002-07-11 14:38:44 UTC
Gerk (ppc dev) and me decided to close this. It's too much of a bother and not 
enough results. And if we do what I suggested above it's not clear that things 
would get any faster.