Scheduled Maintenance: We are aware of an issue with Google, AOL, and Yahoo services as email providers which are blocking new registrations. We are trying to fix the issue and we have several internal and external support tickets in process to resolve the issue. Please see: viewtopic.php?t=158230

 

 

 

Compressed executables...

Here you can discuss every aspect of Debian. Note: not for support requests!
Post Reply
Message
Author
debroux
Posts: 7
Joined: 2006-04-14 07:22

Compressed executables...

#1 Post by debroux »

Under both Windows and GNU/Linux, I've been using UPX for a long time to compress many executables exceeding 1 MB uncompressed, saving hundreds of megabytes and seconds of loading time (noticeable on heavyweight OOo, for example) on my rather small laptop HD.
Obviously, updating packages replaces compressed versions by newer non-compressed versions. Therefore, I launch

Code: Select all

upx-ucl-beta `find [some folder] -size +1000k | awk 'BEGIN {ORS="\x20"} {print $1}'`
from time to time, often saving 40+ MB in /usr/bin alone.

I know that UPX cannot work with several kinds of executables, for example the ones that want to read data from themselves, but there are quite few of them. I knew it before experiencing it when I compressed _all_ files in /bin and /usr/bin, which after the next reboot required me to use a LiveCD to decompress everything and make the machine work properly again... Indeed, the boot process ended immediately, and I couldn't even login in the given prompt...

I suspect the Debian package system (or even other ones, be it RPM or Autopackage, for example), along with the packagers and testers obviously, can perform the compression at packaging time or at installing time. Is it true (I guess so), and is it hard to do ?

While I'm at it: on a related note, does someone know the exact technical reason why UPX will pack many Windows DLLs, but not *nix Shared Objects ? It must be something pretty serious and buried deep in the dynamic linking system, since I guess SOs would already be packable otherwise...

Post Reply