Opened 9 years ago

Closed 9 years ago

#7353 closed defect (fixed)

olpc3/F9 builds are bloated.

Reported by: cscott Owned by: dgilmore
Priority: normal Milestone: 8.2.0 (was Update.2)
Component: distro Version: Development build as of this date
Keywords: Cc: cscott, jg, mstone, dgilmore, bernie, dsd, mtd, tomeu
Blocked By: #234, #6188, #7367, #7368 Blocking: #5535, #7383, #7416
Deployments affected: Action Needed: never set
Verified: no


We added about 60M to the build when shifting from F9. This bug will track efforts to identify where the extra bloat is coming from, and efforts to remove it.

Attachments (3) (377 bytes) - added by dsd 9 years ago.
hacky script to calculate package sizes
sizes.txt (1.9 KB) - added by dsd 9 years ago.
sizes of new packages, update1 vs 8.2
sizes.2.txt (1.2 KB) - added by dsd 9 years ago.
updated package sizes

Download all attachments as: .zip

Change History (39)

comment:1 Changed 9 years ago by cscott

Some initial observations:

  • perl snuck back in
  • lots of icons, for a number of different themes, in a number of formats.
  • xine has plugins for display hardware the XO doesn't have.
  • gnome stock icons re-added; i think we managed to remove them previously?
  • some redhat graphics also found their way back into the build.
  • lots of .pat sound files, where did they come from?
  • /usr/share/firstboot/themes
  • /usr/share/rhgb (which we don't use)
  • lots of hal support for hardware we don't have
  • /usr/share/gnome/help (in lots of languages)
  • did we always install all languages?
  • /usr/share/metacity/icons ?
  • /usr/share/kde-settings ?
  • lvm / mdadm stuff, did we have that before?

comment:2 Changed 9 years ago by cscott

  • Blocked By 234 added

comment:3 Changed 9 years ago by cscott

  • Blocked By 6188 added

comment:4 Changed 9 years ago by cscott

  • Action Needed set to never set
  • Blocked By 7367, 7368 added
  • Cc dgilmore bernie added
  • perl is due to mtd-utils, ntp, gstreamer-plugins-base, and libbonobo, trac bug #234
  • lots of theme crap (including /usr/share/rhgb and /usr/share/kde-settings) due to libgnome requiring fedora-gnome-theme, trac #7367
  • xine plugins part of xine-lib, /usr/lib/xine/plugins/1.21/vidix takes up 208k. We should either fork these or delete them post-install in pilgrim.
  • the midi patches (54M worth!) are being pulled in by PersonalCopy-Lite-patches, which is providing timidity++-patches, which is required by SDL_mixer, which provides, which is required by pygame, trac #7368
  • totem requires gnome-desktop, which requires a number of silly things and provides /usr/share/gnome/help and crap. totem also requires gnome-themes, which requires gnome-icon-theme, which we do not need (trac #4259, #4621). Do we need totem?
  • lvm/mdadm is pulled in by mkinitrd, which is pulled in by the kernel, trac #6188.

comment:5 Changed 9 years ago by marco

We need totem for the web browser plugin, we used to build a version of it with dependencies "stripped off".

What do we need xine for?

comment:6 Changed 9 years ago by cscott

Current size comparison:

  • joyride-2057: 455M
  • joyride-2079: 726M

totem-mozplugin seems to be pulling in *both* totem-xine *and* totem-gstreamer, and totem-xine seems to be pulling in xine. Dennis is going to work on hacking this tangled web apart.

comment:7 Changed 9 years ago by cscott

  • Blocking 5535 added

(In #5535) I reformatted the ticket description to clean up the wiki markup.

See also #7353 for *more* things to clean up.

In email I've also suggested the following packages from OLPC_DEVEL_PACKAGES (thanks to Bert for the pointer):

  • dbench (26M!)
  • pciutils (1.3M)
  • xterm (378k)
  • xorg-x11-apps (259k)
  • xorg-x11-twm (100k, maybe not worth it)

comment:8 Changed 9 years ago by cscott

The olpc-logos package in fedora was used in the olpc2 branch to supply redhat-logos and fedora-logos; it probably needs to be re-added & updated:

comment:9 Changed 9 years ago by dsd

  • Blocking 7383 added
  • Cc dsd added

comment:10 Changed 9 years ago by cscott

Also /usr/sbin/dellWirelessCtl, dellBiosUpdate, dellLEDCtl, dellLcdBrightness (!)

Pulled in from smbios-utils, which is required by the hal package. Luckily it's only (!) 300k.

We might consider making a "olpc-kludge" package which reports itself as Providing a number of these crazy things, so we don't have to go through an fork hal, etc.

comment:11 Changed 9 years ago by cscott

  • Blocking 7416 added

comment:12 Changed 9 years ago by cscott

For ntp, the scripts /usr/sbin/ntptrace and /usr/sbin/ntp-wait use perl (the /usr/sbin/ntpd binary matches perl as well but that's a false alarm). I'd suggest splitting the ntp package as other distros do, so we can get ntpdate (which we use) w/o getting the rest of ntpd.

comment:13 Changed 9 years ago by cscott

In joyride-2102 we started pulling in an extra 20M of samba stuff via gvfs which totem-gstreamer Requires. New packages:

+bluez-libs 3.32-1.fc9
+fuse 2.7.3-2.fc9
+fuse-libs 2.7.3-2.fc9
+gphoto2 2.4.0-10.fc9
+gvfs 0.2.3-11.fc9
+gvfs-fuse 0.2.3-11.fc9
+libarchive 2.4.17-1.fc9
+libexif 0.6.16-1.fc9
+libsmbclient 3.2.0-2.17.fc9
+libtalloc 1.2.0-17.fc9
+libtdb 1.1.1-17.fc9
+lockdev 1.0.1-12.fc9.1
+samba-common 3.2.0-2.17.fc9
+samba-winbind 3.2.0-2.17.fc9

We did get rid of these, though:

-gnome-desktop 2.22.2-1.fc9
-libXvMC 1.0.4-4.fc9
-libmng 1.0.9-6.1
-libmodplug 1:0.8.4-3.fc9
-libmpcdec 1.2.6-4.fc9
-mesa-libGLU 7.1-0.35.fc9
-perl-Config-IniFiles 2.39-6.fc9
-redhat-menus 8.9.11-3.fc9
-totem-xine 2.23.2-4.fc9
-xine-lib 1.1.12-2.fc9

so we're making some progress...

comment:14 Changed 9 years ago by mtd

  • Cc mtd added

comment:15 Changed 9 years ago by mstone

Seems to me that we could cheat here by letting our package manager install all the RPMs it wants, then force-remove the ones that we want to get rid of. Comments?

comment:16 Changed 9 years ago by cscott

mstone: that leaves a 'broken' RPM configuration, so it's a last ditch resort. We're still trying to fix most of these the 'right way', and I think the 'olpc-kludge' package is slightly better than force-remove, since it doesn't affect future use of yum/rpm.

comment:17 Changed 9 years ago by dsd

xulrunner grew some deps which I've killed:

also working on killing e-d-s:
totem depends on totem-pl-parser (doesn't seem realistic to remove this dep), and pl-parser now uses a single date parsing function from libcamel which ends up pulling the whole whopping e-d-s package in.

separating libcamel into it's own package doesn't seem to be that good an option because that lib has a crapload of deps of its own: =>  (0xb7f3c000) => /usr/lib/ (0xb7e9e000) => /lib/ (0xb7e6d000) => /lib/ (0xb7e45000) => /lib/ (0xb7d0e000) => /lib/ (0xb7cf5000) => /lib/ (0xb7cf2000) => /lib/ (0xb7cec000) => /lib/ (0xb7cb2000) => /usr/lib/ (0xb7c4f000) => /usr/lib/ (0xb7c18000) => /lib/ (0xb7c13000) => /lib/ (0xb7c09000) => /lib/ (0xb7c04000) => /lib/ (0xb7bc4000) => /lib/ (0xb7ae2000) => /lib/ (0xb7ac9000) => /usr/lib/ (0xb7a29000) => /usr/lib/ (0xb7a04000) => /lib/ (0xb7a00000) => /usr/lib/ (0xb79d2000) => /usr/lib/ (0xb79b9000) => /lib/ (0xb796e000) => /lib/ (0xb7820000) => /lib/ (0xb781b000) => /lib/ (0xb7806000) => /lib/ (0xb769d000) => /usr/lib/ (0xb754e000) => /usr/lib/ (0xb74e9000) => /usr/lib/ (0xb74d3000) => /usr/lib/ (0xb7479000) => /lib/ (0xb7330000) => /usr/lib/ (0xb7312000) => /lib/ (0xb72d1000) => /usr/lib/ (0xb72cd000) => /usr/lib/ (0xb72c1000) => /usr/lib/ (0xb72b0000) => /lib/ (0xb729b000) => /lib/ (0xb727f000) => /lib/ (0xb727b000)
	/lib/ (0xb7f3d000) => /usr/lib/ (0xb7272000) => /lib/ (0xb726e000) => /lib/ (0xb723c000) => /lib/ (0xb7213000) => /usr/lib/ (0xb720e000) => /lib/ (0xb71f3000) => /lib/ (0xb71ef000)

I'm going to mail Bastien (totem upstream) and see if he'll reconsider his date parsing approach.

comment:18 Changed 9 years ago by dsd

I mailed a patch to Dennis to remove totem-pl-parser's dependency on libcamel. In addition to that and xulrunner I have also worked on the following:

  • We forked gnome-python2 in OLPC-2 to remove some dependencies and we should do so again. Basically gnome-python2 includes libgnome bindings which pull in libgnome (and then loads of other crap including window managers and icon themes). We don't actually use the libgnome bindings, we just use the gnomevfs component. I sent a new spec file to Dennis which is hopefully suitable for Fedora upstream too, and will result in the libgnome portions dropping out of the dependency chain.
  • We forked gnome-vfs2 in OLPC-2 to remove the gnome-mount dependency and should do again. The code fails gracefully when it is asked to mount something and cannot find any utilities to do so.

My work on the above 4 packages should result in (at least) the following packages falling out of the build: gnome-mount, PolicyKit-gnome, libsexy, hunspell-en, hunspell, evolution-data-server, gnome-keyring, libgnome, fedora-gnome-theme, nokoko-metacity-theme, metacity, control-center-fs, fedora-icon-theme, gnome-themes, gnome-python2-bonobo. Possibly libbonobo and libbonoboui too.

comment:19 Changed 9 years ago by dsd

I mailed this question to Dennis but should probably ask out in the open as well: How far do we want to go with forking to remove dependencies?

portaudio grew a dependency on jack-audio-connection-kit which pulls in libfreebob. It would be easy to fork portaudio and add the --disable-jack configure option to remove those 2 deps, but they aren't really that big: yum info says jack is 365k and freebob is 434k. Worth it or not?

comment:20 Changed 9 years ago by erikos

Wow jack-audio-connection-kit and libfreebob. What does pull in portaudio, csound?

comment:21 Changed 9 years ago by dsd

espeak pulls in portaudio, we've shipped portaudio in update1 too (it's 226kb)

comment:22 Changed 9 years ago by cscott

  • Cc tomeu added

Let's order our work by size removed. The target is 300Mb for our build, we've got 50M to trim. When we run out of bigger things to trim, we should move to ~1M things like portaudio -- but, basically, every fork has a cost. I'd rather fork "only" 10 packages which shave 5M each to meet our size goal than fork 50 packages shaving only 1M each.

So, the short answer for portaudio is probably "not yet".

In the meantime, the sugar packages have grown a dependency on xorg-x11-server-Xephyr which adds 2M. That's a regression, and to a package for which we are the upstream, so we should certain fix that. cc'ing tomeu, not because he's responsible, but because he might know who is.

comment:23 Changed 9 years ago by cscott

Xephyr addition was in joyride-2134 / sugar 0.81.6 as shown by The packages also dropped their 'olpc3' dist tag, so maybe we're inadvertently not pulling from our olpc3 sugar fork?

comment:24 Changed 9 years ago by erikos

Yup will remove it we just think currently about the best way to keep our specs sane.

comment:25 Changed 9 years ago by cscott

Re perl & ntp, note that the ntp changelog at says,

--- Changes for ntp 4.2.4p4-6.fc9 from 4.2.4p2-3.fc7 ---
 + require perl (#274771)

That upstream bugzilla reference might be a good place to start in trying to tease perl back out of ntp. Splitting a separate 'ntpdate' packages from ntpd would be a good start, since we only use ntpdate.

comment:26 Changed 9 years ago by dsd

Simon released my xulrunner work, and I have pushed public_rpms for gnome-python2, gnome-vfs2 and totem-pl-parser. Hopefully next joyride will be noticably slimmer.

I will work on the ntpdate split now.

Changed 9 years ago by dsd

hacky script to calculate package sizes

Changed 9 years ago by dsd

sizes of new packages, update1 vs 8.2

comment:27 Changed 9 years ago by erikos

I did the sugar package (joyride 2175) - so xephyr is out won 2 MB :)

Changed 9 years ago by dsd

updated package sizes

comment:28 Changed 9 years ago by dsd

I filed some bugs to get my package dieting merged into fedora:

I also filed some bugs for packages where we should try and convince Fedora upstream to make such modifications to the official Fedora packages before we diverge majorly:

Also on this topic I dropped an experimental pam RPM into my public_rpms which should kill cracklib and its dictionaries (#5259)

comment:29 Changed 9 years ago by dsd

As another experiment I have locally created a fork of xorg-x11-utils like we did for OLPC-2, it removes xdriinfo which should kill mesa stuff. We are hopefully at <300mb now.

comment:30 Changed 9 years ago by cscott

The joyride-2203 build is at 298M now. Yay! That's our target for 8.2, although we'll probably have to keep trimming to maintain the builds at this size.

Is there anything left in #4281 / #5535 to fix? There's some unfinished work in #1286, for example.

comment:31 Changed 9 years ago by dsd

A lot of stuff is coming from my public_rpms, I want to get that in fedora before closing tickets. Dennis sponsored me today (thanks), so I will cautiously work on doing that.

comment:32 Changed 9 years ago by dsd

I've pushed all my previous work into Fedora, not sure if anyone wants to push further on #4281 / #5535? I'm planning to raise #1286 in today's meeting, as it will cause more activity breakage...

comment:33 follow-up: Changed 9 years ago by cscott

Joyride-2231 is at 300M exactly. However, the latest sugar-evince added poppler (3M) -- I wonder if we can get that back out to give ourselves a bit of margin?

comment:34 in reply to: ↑ 33 Changed 9 years ago by cjb

Replying to cscott:

Joyride-2231 is at 300M exactly. However, the latest sugar-evince added poppler (3M) -- I wonder if we can get that back out to give ourselves a bit of margin?

<marcopg_> c_scott: poppler is needed

(poppler is evince's backend)

comment:35 Changed 9 years ago by cscott

I think we should probably close this bug, 1286, and 4281 and 5535, and reopen new bugs with any new bloat found. I think I've already addressed most of the reasonable stuff in 4281 and 5535.

We should also re-audit just to make sure we've got all the F9 bloat.

comment:36 Changed 9 years ago by cscott

  • Resolution set to fixed
  • Status changed from new to closed

Closing this bug.

Note: See TracTickets for help on using tickets.