Puppy Linux Discussion Forum Forum Index Puppy Linux Discussion Forum
Puppy HOME page : puppylinux.com
"THE" alternative forum : puppylinux.info
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

The time now is Tue 29 Jul 2014, 18:54
All times are UTC - 4
 Forum index » Advanced Topics » Additional Software (PETs, n' stuff) » Compiling
Compiling QT - need expert's advices
Post new topic   Reply to topic View previous topic :: View next topic
Page 1 of 1 [9 Posts]  
Author Message
simargl8

Joined: 06 Feb 2013
Posts: 65

PostPosted: Thu 07 Feb 2013, 03:55    Post subject:  Compiling QT - need expert's advices  

I'm planning to recompile Qt for ArchPup in attempt to reduce package size
Currently:
qt package from arch = 20.6 MB
converted to spkg (wich uses tar.bz2 compression) = 28 MB

This is what is used for all packages in ArchPup
Code:
CFLAGS="-march=i686 -Os -pipe -fomit-frame-pointer"
CXXFLAGS="$CFLAGS"
LDFLAGS="-Wl,--as-needed"


I'm hoping optimize for size in CFLAGS, would reduce it for couple of MB.
Anyone tried this? What is your experience, is it worth to try?
Back to top
View user's profile Send private message Visit poster's website 
amigo

Joined: 02 Apr 2007
Posts: 2225

PostPosted: Thu 07 Feb 2013, 15:26    Post subject:  

Let's see, it's gonna take about 40 hours for that to compile -just hope that it doesn't go 38 hours and then end in an error... If you think it's worth doing it, tehn go right ahead.

For me, I've found a great way to avoid the problem -I don't use anything that needs QT! Works great, every time!
Back to top
View user's profile Send private message 
Q5sys


Joined: 11 Dec 2008
Posts: 1047

PostPosted: Thu 07 Feb 2013, 19:57    Post subject: Re: Compiling QT - need expert's advices  

simargl8 wrote:
I'm planning to recompile Qt for ArchPup in attempt to reduce package size
Currently:
qt package from arch = 20.6 MB
converted to spkg (wich uses tar.bz2 compression) = 28 MB

This is what is used for all packages in ArchPup
Code:
CFLAGS="-march=i686 -Os -pipe -fomit-frame-pointer"
CXXFLAGS="$CFLAGS"
LDFLAGS="-Wl,--as-needed"


I'm hoping optimize for size in CFLAGS, would reduce it for couple of MB.
Anyone tried this? What is your experience, is it worth to try?


You using 4.8 or are you trying to compile qt5?

_________________



My PC is for sale
Back to top
View user's profile Send private message 
disciple

Joined: 20 May 2006
Posts: 6426
Location: Auckland, New Zealand

PostPosted: Fri 08 Feb 2013, 00:48    Post subject:  

Personally, if I need QT (I do these days) I'm quite happy to put up with a "couple of MB" extra. And isn't the whole point in Arch that it's a rolling release? Are you going to build your QT package on a regular basis to keep it up-to-date?

BTW good on you for creating ArchPup - I would be using it if I hadn't already converted to Arch proper.

_________________
DEATH TO SPREADSHEETS
- - -
Classic Puppy quotes
- - -
Beware the demented serfers!
Back to top
View user's profile Send private message 
simargl8

Joined: 06 Feb 2013
Posts: 65

PostPosted: Fri 08 Feb 2013, 03:15    Post subject: Re: Compiling QT - need expert's advices  

Q5sys wrote:
You using 4.8 or are you trying to compile qt5?

Plan is to use the same qt version as in Arch (4.8.4)
disciple wrote:
isn't the whole point in Arch that it's a rolling release? Are you going to build your QT package on a regular basis to keep it up-to-date?

I would add qt in IgnoreList in pacman.conf, as already done with pango and menu-cache.
To avoid big dependency (on icu) I used older version of pango, without that every gtk2 application
would require icu (7MB) to be present at compile time.
Also openbox dynamic menu is buggy with new menu-cache (0.4), so I used older version (0.3.3)
Later today will try to compile Qt... You'll be informed about the result Wink
Back to top
View user's profile Send private message Visit poster's website 
simargl8

Joined: 06 Feb 2013
Posts: 65

PostPosted: Fri 08 Feb 2013, 10:38    Post subject:  

Here are the results:
compile time 1 hour 50 mins
package size 19.5MB Very Happy
That means reduced iso size for 8.5 MB Shocked
Also I have tested compiling qpdfview against new qt and it worked, nice!
I'm very pleased with this process outcome!
Back to top
View user's profile Send private message Visit poster's website 
disciple

Joined: 20 May 2006
Posts: 6426
Location: Auckland, New Zealand

PostPosted: Fri 08 Feb 2013, 18:14    Post subject:  

Interesting. Have you compared the two packages to see where the saving is?
_________________
DEATH TO SPREADSHEETS
- - -
Classic Puppy quotes
- - -
Beware the demented serfers!
Back to top
View user's profile Send private message 
simargl8

Joined: 06 Feb 2013
Posts: 65

PostPosted: Fri 08 Feb 2013, 18:39    Post subject:  

I also think It's interesting to see what are the differences, so here they are
Arch Package
Code:
[root@archpup sources]# du -sh qt-4.8.4-2-i686.pkg/usr/*
18M   qt-4.8.4-2-i686.pkg/usr/bin
19M   qt-4.8.4-2-i686.pkg/usr/include
45M   qt-4.8.4-2-i686.pkg/usr/lib
11M   qt-4.8.4-2-i686.pkg/usr/share

spkg package
Code:
[root@archpup qt]# du -sh install/usr/*
13M   install/usr/bin
18M   install/usr/include
31M   install/usr/lib
3.7M   install/usr/share

You see that main difference is in /usr/lib, bellow are compared 10 largest libraries:
Arch
Quote:
1012K libQtOpenGL.so.4.8.4
972K libQtCLucene.so.4.8.4
720K libQtScriptTools.so.4.8.4
532K libQtHelp.so.4.8.4
504K libQtDBus.so.4.8.4
336K libQtSvg.so.4.8.4
256K libQtXml.so.4.8.4
248K libQtSql.so.4.8.4
160K libQtMultimedia.so.4.8.4
148K libQtTest.so.4.8.4

spkg
Quote:
876K libQtUiTools.a
872K libQtNetwork.so.4.8.4
832K libQtCLucene.so.4.8.4
780K libQtOpenGL.so.4.8.4
548K libQtScriptTools.so.4.8.4
360K libQtHelp.so.4.8.4
344K libQtDBus.so.4.8.4
240K libQtSvg.so.4.8.4
192K libQtXml.so.4.8.4
184K libQtSql.so.4.8.4
Back to top
View user's profile Send private message Visit poster's website 
scsijon

Joined: 23 May 2007
Posts: 1023
Location: the australian mallee

PostPosted: Fri 08 Feb 2013, 19:49    Post subject:  

Code:
 --as-needed
if I understand correctly, basically means that the compiler will look at your system and only create the bits it needs to work with your system, rather than the full set that works with anything.

I suspect the origonal build was built to deal with every combination and therefore will of course be larger.
Back to top
View user's profile Send private message Visit poster's website 
Display posts from previous:   Sort by:   
Page 1 of 1 [9 Posts]  
Post new topic   Reply to topic View previous topic :: View next topic
 Forum index » Advanced Topics » Additional Software (PETs, n' stuff) » Compiling
Jump to:  

You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Powered by phpBB © 2001, 2005 phpBB Group
[ Time: 0.0867s ][ Queries: 11 (0.0186s) ][ GZIP on ]